peewee Documentation Release 1.0.0RawQuery Databases Writing a database driver Database and its subclasses BaseAdapter and its subclasses Playhouse, a collection of addons apsw, an advanced sqlite driver Postgresql Extensions (hstore, ltree) insert, otherwise it does an update on the existing value. Since, with our uuid example, the database driver won’t generate a new ID, we need to specify it manually. When we call save() for the first time, called an BaseAdapter, which is backend-specific and encapsulates functionality specific to a given db driver. Since there is some difference in column types across database engines, this information also resides0 码力 | 101 页 | 163.20 KB | 1 年前3
peewee Documentation
Release 1.0.0insert, otherwise it does an update on the existing value. Since, with our uuid example, the database driver won’t generate a new ID, we need to specify it manually. When we call save() for the first time, an BaseAdapter, which is backend-specific and encap- sulates functionality specific to a given db driver. Since there is some difference in column types across database engines, this information also resides resides in the adapter. The adapter is responsible for smoothing out the quirks of each database driver to provide a consistent interface, for example sqlite uses the question-mark ”?” character for parameter0 码力 | 71 页 | 405.29 KB | 1 年前3
peewee Documentation
Release 2.0.2insert, otherwise it does an update on the existing value. Since, with our uuid example, the database driver won’t generate a new ID, we need to specify it manually. When we call save() for the first time, gathering information from the database. The Database encapsulates functionality specific to a given db driver. For example difference in column types across database engines, or support for certain features features like sequences. The database is responsible for smoothing out the quirks of each backend driver to provide a consistent interface. The Database also uses a subclass of QueryCompiler to generate valid0 码力 | 65 页 | 315.33 KB | 1 年前3
peewee Documentation Release 2.10.2Database Errors Automatic Reconnect Logging queries Generating skeleton code Adding a new Database Driver Models and Fields Fields Creating model tables Model options and table metadata Indexes and Constraints extensions to Peewee Sqlite Extensions SqliteQ Sqlite User-Defined Functions apsw, an advanced sqlite driver BerkeleyDB backend Sqlcipher backend Postgresql Extensions DataSet Django Integration Fields Generic accommodate all these parameters, Peewee will pass back unrecognized parameters directly to the database driver. For instance, with Postgresql it is common to need to specify the host, user and password when0 码力 | 275 页 | 276.96 KB | 1 年前3
peewee Documentation
Release 3.5.0Integration Executing Queries Managing Transactions Database Errors Logging queries Adding a new Database Driver Models and Fields Fields Creating model tables Model options and table metadata Indexes and Constraints Playhouse, extensions to Peewee SqliteQ Sqlite User-Defined Functions apsw, an advanced sqlite driver Sqlcipher backend Postgresql Extensions MySQL Extensions DataSet Fields Hybrid Attributes Key/Value extensions, see: Postgresql Extensions SQLite Extensions Sqlcipher backend apsw, an advanced sqlite driver SqliteQ Initializing a Database The Database initialization method expects the name of the database0 码力 | 347 页 | 380.80 KB | 1 年前3
peewee Documentation
Release 2.10.2accommodate all these parameters, Peewee will pass back unrecognized parameters directly to the database driver. For instance, with Postgresql it is common to need to specify the host, user and password when password='secret', # Ditto. host='db.mysite.com', # Ditto. ) As another example, the pymysql driver accepts a charset parameter which is not a standard Peewee Database parameter. To set this value values: db = MySQLDatabase('database_name', user='www-data', charset='utf8mb4') Consult your database driver’s documentation for the available parameters: • Postgres: psycopg2 • MySQL: MySQLdb • MySQL: pymysql0 码力 | 221 页 | 844.06 KB | 1 年前3
peewee Documentation Release 3.4.0Integration Executing Queries Managing Transactions Database Errors Logging queries Adding a new Database Driver Models and Fields Fields Field-naming conflicts Creating model tables Model options and table metadata Playhouse, extensions to Peewee SqliteQ Sqlite User-Defined Functions apsw, an advanced sqlite driver Sqlcipher backend Postgresql Extensions MySQL Extensions DataSet Fields Hybrid Attributes Key/Value database as the first parameter. Subsequent keyword arguments are passed to the underlying database driver when establishing the connection, allowing you to pass vendor-specific parameters easily. For instance0 码力 | 349 页 | 382.34 KB | 1 年前3
peewee Documentation
Release 3.5.0see: • Postgresql Extensions • SQLite Extensions • Sqlcipher backend • apsw, an advanced sqlite driver • SqliteQ 1.5. Database 19 peewee Documentation, Release 3.5.0 1.5.1 Initializing a Database database as the first parameter. Subsequent keyword arguments are passed to the underlying database driver when establishing the connection, allowing you to pass vendor- specific parameters easily. For instance psycopg2. password='secret', # Ditto. host='db.mysite.com') # Ditto. As another example, the pymysql driver accepts a charset parameter which is not a standard Peewee Database parameter. To set this value0 码力 | 282 页 | 1.02 MB | 1 年前3
peewee Documentation Release 3.6.0Integration Executing Queries Managing Transactions Database Errors Logging queries Adding a new Database Driver Models and Fields Fields Creating model tables Model options and table metadata Indexes and Constraints extensions to Peewee Sqlite Extensions SqliteQ Sqlite User-Defined Functions apsw, an advanced sqlite driver Sqlcipher backend Postgresql Extensions MySQL Extensions DataSet Fields Hybrid Attributes Key/Value extensions, see: Postgresql Extensions SQLite Extensions Sqlcipher backend apsw, an advanced sqlite driver SqliteQ Initializing a Database The Database initialization method expects the name of the database0 码力 | 377 页 | 399.12 KB | 1 年前3
peewee Documentation
Release 3.4.0database as the first parameter. Subsequent keyword arguments are passed to the underlying database driver when establishing the connection, allowing you to pass vendor- specific parameters easily. For instance psycopg2. password='secret', # Ditto. host='db.mysite.com') # Ditto. As another example, the pymysql driver accepts a charset parameter which is not a standard Peewee Database parameter. To set this value values: db = MySQLDatabase('database_name', user='www-data', charset='utf8mb4') Consult your database driver’s documentation for the available parameters: • Postgres: psycopg2 • MySQL: MySQLdb • MySQL: pymysql0 码力 | 284 页 | 1.03 MB | 1 年前3
共 16 条
- 1
- 2













