Session pool for a PostgreSQL database. Expects a connection string, for example 'postgresql://localhost/myproject'. If debug is True, a validation is performed on row.save(), to make sure all keys and values are strings. schema is deprecated.
Get a Session for talking to the database. If lazy is True then the connection is estabilished only when the first query needs to be executed.
Retire the session, freeing up its connection, and aborting any non-committed transaction.
SQLite database session pool; same api as PostgresqlDB.
Wrapper for a database connection with methods to access tables and commit/rollback transactions.
Access a DbFile. If id is None, a new file is created; otherwise, the requested blob file is returned by id.
Commit the current transaction.
Roll back the current transaction.
A database table with two columns: id (integer primary key) and data (hstore).
Multiple rows matching search critera.
No row matching search criteria.
Create the backend SQL table.
Drop the backend SQL table.
Returns an iterator over all matching TableRow objects.
Shorthand for calling find() and getting the first result. Raises RowNotFound if no result is found.
Shorthand for calling find() and getting the first result. Raises RowNotFound if no result is found. Raises MultipleRowsFound if more than one result is found.
Fetches the TableRow with the given id.
Create a new TableRow with auto-incremented id. An INSERT SQL query is executed to generate the id.
Database row, represented as a Python dict.
Primary key of this row.
Execute a DELETE query for this row.
Execute an UPDATE query for this row.
Database binary blob. It works like a file, but has a simpler API, with methods to read and write a stream of byte chunks.
Unique ID of the file. It can be used to request the file later via Session.get_db_file().
Read data from database and return it as a Python generator.
Consume data from in_file (a file-like object) and save to database.