Home | History | Annotate | Download | only in dist

Lines Matching full:database

215 ** CAPI3REF: Database Connection Handle
216 ** KEYWORDS: {database connection} {database connections}
218 ** Each open SQLite database is represented by a pointer to an instance of
267 ** CAPI3REF: Closing A Database Connection
276 ** sqlite3_close() is called on a [database connection] that still has
309 ** in the context of the [database connection] passed in as its 1st
346 ** SQL comments, then no SQL statements are evaluated and the database
353 ** is a valid and open [database connection].
354 ** <li> The application must not close [database connection] specified by
361 sqlite3*, /* An open database */
383 #define SQLITE_ERROR 1 /* SQL error or missing database */
387 #define SQLITE_BUSY 5 /* The database file is locked */
388 #define SQLITE_LOCKED 6 /* A table in the database is locked */
390 #define SQLITE_READONLY 8 /* Attempt to write a readonly database */
393 #define SQLITE_CORRUPT 11 /* The database disk image is malformed */
395 #define SQLITE_FULL 13 /* Insertion failed because database is full */
396 #define SQLITE_CANTOPEN 14 /* Unable to open the database file */
397 #define SQLITE_PROTOCOL 15 /* Database lock protocol error */
398 #define SQLITE_EMPTY 16 /* Database is empty */
399 #define SQLITE_SCHEMA 17 /* The database schema changed */
406 #define SQLITE_FORMAT 24 /* Auxiliary database format error */
408 #define SQLITE_NOTADB 26 /* File opened that is not a database file */
425 ** on a per database connection basis using the
623 ** The xCheckReservedLock() method checks whether any database connection,
680 ** database corruption.
723 ** layer a hint of how large the database file will grow to be during the
725 ** is often close. The underlying VFS might choose to preallocate database
726 ** file space based on this hint in order to help writes to the database
731 ** extends and truncates the database file in chunks of a size specified
734 ** for the nominated database. Allocating database file space in large
740 ** to the [sqlite3_file] object associated with a particular database
747 ** when the database connection has [PRAGMA synchronous] set to OFF.)^
764 ** to be adjusted. The values are changed for all database connections
776 ** are automatically deleted when the latest connection to the database
779 ** have write permission on the directory containing the database file want
780 ** to read the database file, as the WAL and shared memory files must exist
781 ** in order for the database to be readable. The fourth parameter to
800 ** reason, the entire database file will be overwritten by the current
818 ** to the database file to which the pragma statement refers. ^The argument
944 ** SQLITE_IOERR. Or the implementation might recognize that a database
1150 ** single thread. All open [database connections] must be closed and all
1238 ** CAPI3REF: Configure database connections
1241 ** changes to a [database connection]. The interface is similar to
1243 ** [database connection] (specified in the first argument).
1247 ** that indicates what aspect of the [database connection] is being configured.
1359 ** mutexing on [database connection] and [prepared statement] objects.
1361 ** [database connections] and [prepared statements]. But other mutexes
1364 ** [database connection] at the same time. ^If SQLite is compiled with
1374 ** mutexes on [database connection] and [prepared statement] objects.
1377 ** to [database connections] and [prepared statements] so that the
1378 ** application is free to use the same [database connection] or the
1430 ** times the database page size. ^If SQLite needs needs additional
1436 ** the database page cache with the default page cache implementation.
1441 ** The sz argument should be the size of the largest database page
1500 ** [database connection]. The first argument is the
1502 ** slots allocated to each database connection.)^ ^(This option sets the
1542 ** of whether or not the [SQLITE_OPEN_URI] flag is set when the database
1545 ** database connection is opened. By default, URI handling is globally
1576 ** CAPI3REF: Database Connection Configuration Options
1591 ** [lookaside memory allocator] configuration for the [database connection].
1603 ** configuration for a database connection can only be changed when that
1658 ** successful [INSERT] into the database from the [database connection]
1662 ** have ever occurred on that database connection, zero is returned.
1688 ** database connection while the [sqlite3_last_insert_rowid()]
1699 ** ^This function returns the number of database rows that were changed
1701 ** on the [database connection] specified by the first parameter.
1744 ** If a separate thread makes changes on the same database connection
1754 ** [UPDATE] or [DELETE] statements since the [database connection] was opened.
1770 ** If a separate thread makes changes on the same database connection
1779 ** ^This function causes any pending database operation to abort and
1786 ** thread that is currently running the database operation. But it
1787 ** is not safe to call this routine with a [database connection] that
1800 ** SQL statements on [database connection] D complete. ^Any new SQL statements
1810 ** If the database connection closes while [sqlite3_interrupt()]
1855 ** an attempt is made to open a database table that another thread
1867 ** access the database and [SQLITE_BUSY] or [SQLITE_IOERR_BLOCKED] is returned.
1869 ** is made to open the database for reading and the cycle repeats.
1891 ** already hold a RESERVED lock on the database file, but it needs
1893 ** pages into the database file without harm to concurrent
1904 ** [database connection]. Setting a new busy handler clears any
1909 ** database connection that invoked the busy handler. Any such actions
1912 ** A busy handler must not close the database connection
1931 ** [database connection] any any given moment. If another busy handler
2010 sqlite3 *db, /* An open database */
2242 ** [database connection], supplied in the first argument.
2284 ** try to execute malicious statements that damage the database. For
2286 ** SQL queries for evaluation by a database. But the application does
2288 ** database. An authorizer could then be put in place while the
2294 ** and limiting database size using the [max_page_count] [PRAGMA]
2297 ** ^(Only a single authorizer can be in place on a database connection
2303 ** the database connection that invoked the authorizer callback.
2305 ** database connections for the meaning of "modify" in this paragraph.
2352 ** authorizer callback is the name of the database ("main", "temp",
2383 #define SQLITE_DETACH 25 /* Database Name NULL */
2384 #define SQLITE_ALTER_TABLE 26 /* Database Name Table Name */
2428 ** database connection D. An example use for this
2437 ** [database connection]; setting a new progress handler cancels the
2447 ** the database connection that invoked the progress handler.
2449 ** database connections for the meaning of "modify" in this paragraph.
2455 ** CAPI3REF: Opening A New Database Connection
2457 ** ^These routines open an SQLite database file as specified by the
2460 ** order for sqlite3_open16(). ^(A [database connection] handle is usually
2464 ** object.)^ ^(If the database is opened (and/or created) successfully, then
2470 ** ^The default encoding for the database will be UTF-8 if
2475 ** associated with the [database connection] handle should be released by
2480 ** over the new database connection. ^(The flags parameter to
2488 ** <dd>The database is opened in read-only mode. If the database does not
2492 ** <dd>The database is opened for reading and writing if possible, or reading
2494 ** case the database must already exist, otherwise an error is returned.</dd>)^
2497 ** <dd>The database is opened for reading and writing, and is created if
2507 ** ^If the [SQLITE_OPEN_NOMUTEX] flag is set, then the database connection
2510 ** [SQLITE_OPEN_FULLMUTEX] flag is set then the database connection opens
2513 ** ^The [SQLITE_OPEN_SHAREDCACHE] flag causes the database connection to be
2516 ** [SQLITE_OPEN_PRIVATECACHE] flag causes the database connection to not
2521 ** the new database connection should use. ^If the fourth parameter is
2524 ** ^If the filename is ":memory:", then a private, temporary in-memory database
2525 ** is created for the connection. ^This in-memory database will vanish when
2526 ** the database connection is closed. Future versions of SQLite might
2528 ** It is recommended that when a database filename actually does begin with
2533 ** on-disk database will be created. ^This private database will be
2534 ** automatically deleted as soon as the database connection is closed.
2556 ** which contains the database. ^If the path begins with a '/' character,
2571 ** be used to access the database file on disk. ^If this option is set to
2579 ** ^If "ro" is specified, then the database is opened for read-only
2582 ** "rw", then the database is opened for read-write (but not create)
2614 ** Open the database file "/home/fred/data.db".
2649 const char *filename, /* Database filename (UTF-8) */
2653 const void *filename, /* Database filename (UTF-16) */
2657 const char *filename, /* Database filename (UTF-8) */
2667 ** to see if a database file was a URI that contained a specific query
2670 ** If F is the database filename pointer passed into the xOpen() method of
2698 ** is not a database file pathname pointer that SQLite passed into the xOpen
2712 ** associated with a [database connection]. If a prior API call failed
2731 ** this, each thread can obtain exclusive use of the [database connection] D
2776 ** [database connection] whose limit is to be set or queried. The
2796 ** both their own internal database and also databases that are controlled
2804 ** interface to further control untrusted SQL. The size of the database
2883 ** The first argument, "db", is a [database connection] obtained from a
2885 ** [sqlite3_open16()]. The database connection must not have been closed.
2929 ** ^If the database schema changes, instead of returning [SQLITE_SCHEMA] as it
2958 sqlite3 *db, /* Database handle */
2965 sqlite3 *db, /* Database handle */
2972 sqlite3 *db, /* Database handle */
2979 sqlite3 *db, /* Database handle */
2996 ** CAPI3REF: Determine If An SQL Statement Writes The Database
3000 ** the content of the database file.
3003 ** [virtual tables] might change the database indirectly as a side effect.
3006 ** change the database file through side-effects:
3012 ** But because the [SELECT] statement does not change the database file
3017 ** since the statements themselves do not actually modify the database but
3019 ** database. ^The [ATTACH] and [DETACH] statements also cause
3021 ** change the configuration of a database connection, they do not make
3022 ** changes to the content of the database files on disk.
3038 ** to locate all prepared statements associated with a database
3050 ** that can be stored in a database table. SQLite uses dynamic typing
3312 ** ^These routines provide a means to determine the database, table, and
3315 ** ^The name of the database or table or column can be returned as
3317 ** the database name, the _table_ routines return the table name, and
3326 ** database, table, and column.
3336 ** occurs. ^Otherwise, they return the name of the attached database, table,
3372 ** ^(For example, given the database schema:
3413 ** ^[SQLITE_BUSY] means that the database engine was unable to acquire the
3414 ** database locks it needs to do its job. ^If the statement is a [COMMIT]
3443 ** be the case that the same database connection is being used by two or
3764 ** ^The first parameter is the [database connection] to which the SQL
3765 ** function is to be added. ^If an application uses more than one database
3767 ** to each database connection separately.
3811 ** overloaded or when the database connection closes.)^
3825 ** matches the database encoding is a better
3835 ** close the database connection nor finalize or reset the prepared
4016 ** CAPI3REF: Database Connection For Functions
4019 ** the pointer to the [database connection] (the 1st parameter)
4221 ** with the [database connection] specified as the first argument.
4283 ** [database connection] is closed using [sqlite3_close()].
4322 ** ^To avoid having to register all collation sequences before a database
4324 ** [database connection] to be invoked whenever an undefined collation
4335 ** sqlite3_collation_needed16(). The second argument is the database
4358 ** Specify the key for an encrypted database. This routine should be
4365 sqlite3 *db, /* Database to be rekeyed */
4370 ** Change the key on an open database. If the current database is not
4372 ** database is decrypted.
4378 sqlite3 *db, /* Database to be rekeyed */
4383 ** Specify the activation key for a SEE database. Unless
4393 ** Specify the activation key for a CEROD database. Unless
4432 ** if a [database connection] is being used at the same time in a separate
4456 ** zero if the given database connection is or is not in autocommit mode,
4468 ** If another thread changes the autocommit status of the database
4475 ** CAPI3REF: Find The Database Handle Of A Prepared Statement
4477 ** ^The sqlite3_db_handle interface returns the [database connection] handle
4478 ** to which a [prepared statement] belongs. ^The [database connection]
4479 ** returned by sqlite3_db_handle is the same [database connection]
4487 ** CAPI3REF: Return The Filename For A Database Connection
4490 ** associated with database N of connection D. ^The main database file
4491 ** has the name "main". If there is no attached database N on the database
4492 ** connection D, or if database N is a temporary or in-memory database, then
4498 ** to open the database originally was a URI or relative pathname.
4503 ** CAPI3REF: Determine if a database is read-only
4505 ** ^The sqlite3_db_readonly(D,N) interface returns 1 if the database N
4507 ** the name of a database on connection D.
4515 ** pStmt associated with the [database connection] pDb. ^If pStmt is NULL
4517 ** associated with the database connection pDb. ^If no prepared statement
4520 ** The [database connection] pointer D in a call to
4521 ** [sqlite3_next_stmt(D,S)] must refer to an open database
4532 ** for the same database connection is overridden.
4536 ** for the same database connection is overridden.
4543 ** on the same [database connection] D, or NULL for
4548 ** the database connection that invoked the callback. Any actions
4549 ** to modify the database connection must be deferred until after the
4554 ** the database connections for the meaning of "modify" in this paragraph.
4568 ** automatically rolled back because the database connection is closed.
4579 ** with the [database connection] identified by the first argument
4582 ** for the same database connection is overridden.
4592 ** database and table name containing the affected row.
4607 ** the database connection that invoked the update hook. Any actions
4608 ** to modify the database connection must be deferred until after the
4611 ** database connections for the meaning of "modify" in this paragraph.
4615 ** on the same [database connection] D, or NULL for
4631 ** ^(This routine enables or disables the sharing of the database cache
4632 ** and schema data structures between [database connection | connections]
4633 ** to the same database. Sharing is enabled if the argument is true
4642 ** Existing database connections continue use the sharing mode
4661 ** held by the database library. Memory used to cache database
4673 ** CAPI3REF: Free Memory Used By A Database Connection
4676 ** memory as possible from database connection D. Unlike the
4753 ** database table accessible using the [database connection] handle
4757 ** this function. ^The second parameter is either the name of the database
4758 ** (i.e. "main", "temp", or an attached database) containing the specified
4760 ** for the table using the same algorithm used by the database engine to
4803 ** ^(This function may load one or more schemas from database files. If an
4806 ** in the [database connection] (to be retrieved using sqlite3_errmsg()).)^
4813 const char *zDbName, /* Database name or NULL */
4849 sqlite3 *db, /* Load the extension into this database connection */
4874 ** each new [database connection] that is created. The idea here is that
4876 ** that is to be automatically loaded into all new database connections.
4901 ** will be called more than once for each database connection that is opened.
4944 ** module or until the [database connection] closes. The content
4946 ** any database connection.
5085 ** ^The module name is registered on the [database connection] specified
5219 ** in row iRow, column zColumn, table zTable in database zDb;
5232 ** ^Note that the database name is not the filename that contains
5233 ** the database but rather the symbolic name of the database that
5234 ** appears after the AS keyword when the database is connected using [ATTACH].
5235 ** ^For the main database file, the database name is "main".
5236 ** ^For TEMP tables, the database name is "temp".
5241 ** ^This function sets the [database connection] error code and message
5285 ** to a different row of the same database table. ^The new row is identified
5287 ** changed. ^The database, table and column on which the blob handle is open
5301 ** ^This function sets the database handle error code and message.
5312 ** database connection is in [autocommit mode].
5697 ** CAPI3REF: Retrieve the mutex for a database connection
5700 ** serializes access to the [database connection] given in the argument
5708 ** CAPI3REF: Low-Level Control Of Database Files
5712 ** with a particular database identified by the second argument. ^The
5713 ** name of the database is "main" for the main database or "temp" for the
5714 ** TEMP database, or the name that appears after the AS keyword for
5717 ** main database file.
5730 ** open database file, then SQLITE_ERROR is returned. ^This error
5915 ** CAPI3REF: Database Connection Status
5918 ** about a single [database connection]. ^The first argument is the
5919 ** database connection object to be interrogated. ^The second argument
5939 ** CAPI3REF: Status Parameters for database connections
5979 ** memory used by all pager caches associated with the database connection.)^
5987 ** schema memory is shared with other database connections due to
5994 ** the database connection.)^
6122 ** determine exactly which parts of a database file are cached and for
6162 ** SQLite will typically create one cache instance for each open database file,
6170 ** database page on disk. The value passed into szExtra depends
6173 ** created will be used to cache database pages of a file stored on disk, or
6174 ** false if it is used for an in-memory database. The cache implementation
6200 ** single database page. The pExtra element of sqlite3_pcache_page will be
6322 ** The backup API copies the content of one database into another.
6328 ** ^SQLite holds a write transaction open on the destination database file
6330 ** ^The source database is read-locked only while it is being read;
6332 ** ^Thus, the backup may be performed on a live source database without
6333 ** preventing other database connections from
6334 ** reading or writing to the source database while the backup is underway.
6351 ** [database connection] associated with the destination database
6352 ** and the database name, respectively.
6353 ** ^The database name is "main" for the main database, "temp" for the
6354 ** temporary database, or the name specified after the AS keyword in
6355 ** an [ATTACH] statement for an attached database.
6357 ** sqlite3_backup_init(D,N,S,M) identify the [database connection]
6358 ** and database name of the source database, respectively.
6359 ** ^The source and destination [database connections] (parameters S and D)
6365 ** destination [database connection] D.
6392 ** <li> the destination database was opened read-only, or
6393 ** <li> the destination database is using write-ahead-log journaling
6395 ** <li> the destination database is an in-memory database and the
6405 ** [database connection]
6406 ** is being used to write to the source database when sqlite3_backup_step()
6420 ** sqlite3_backup_step() obtains a [shared lock] on the source database that
6422 ** ^Because the source database is not locked between calls to
6423 ** sqlite3_backup_step(), the source database may be modified mid-way
6424 ** through the backup process. ^If the source database is modified by an
6425 ** external process or via a database connection other than the one being
6428 ** database is modified by the using the same database connection as is used
6429 ** by the backup operation, then the backup database is automatically
6440 ** active write-transaction on the destination database is rolled back.
6460 ** up and the total number of pages in the source database file.
6465 ** sqlite3_backup_step(). ^If the source database is modified during a backup
6467 ** pages that need to be updated or the size of the source database file
6470 ** <b>Concurrent Usage of Database Handles</b>
6472 ** ^The source [database connection] may be used by the application for other
6474 ** ^If SQLite is compiled and configured to support threadsafe database
6475 ** connections, then the source database connection may be used concurrently
6479 ** [database connection] is not passed to any other API (by any thread) after
6482 ** if the application incorrectly accesses the destination [database connection]
6484 ** nevertheless. Use of the destination database connection while a
6488 ** guarantee that the shared cache used by the destination database
6502 sqlite3 *pDest, /* Destination database handle */
6503 const char *zDestName, /* Destination database name */
6504 sqlite3 *pSource, /* Source database handle */
6505 const char *zSourceName /* Source database name */
6515 ** ^When running in shared-cache mode, a database operation may fail with
6526 ** ^Shared-cache locks are released when a database connection concludes
6531 ** identity of the database connection (the blocking connection) that
6583 ** related to the set of unblocked database connections.
6588 ** database waits for the callback to be issued before taking any further
6671 ** will be invoked each time a database connection commits data to a
6676 ** the associated write-lock on the database released, so the implementation
6677 ** may read, write or [checkpoint] the database as required.
6681 ** registering the callback. ^The second is a copy of the database handle.
6682 ** ^The third parameter is the name of the database that was written to -
6683 ** either "main" or the name of an [ATTACH]-ed database. ^The fourth parameter
6695 ** A single database handle may have at most a single write-ahead log callback
6712 ** [sqlite3_wal_hook()] that causes any database on [database connection] D
6727 ** ^Every new [database connection] defaults to having the auto-checkpoint
6736 ** CAPI3REF: Checkpoint a database
6738 ** ^The [sqlite3_wal_checkpoint(D,X)] interface causes database named X
6739 ** on [database connection] D to be [checkpointed]. ^If X is NULL or an
6741 ** connection D. ^If the database connection D is not in
6754 ** CAPI3REF: Checkpoint a database
6756 ** Run a checkpoint operation on WAL database zDb attached to database
6762 ** Checkpoint as many frames as possible without waiting for any database
6769 ** database writer and all readers are reading from the most recent database
6771 ** database file. This call blocks database writers while it is running,
6772 ** but not database readers.
6777 ** until all readers are reading from the database file only. This ensures
6778 ** that the next client to write to the database file restarts the log file
6779 ** from the beginning. This call blocks database writers while it is running,
6780 ** but not database readers.
6791 ** All calls obtain an exclusive "checkpoint" lock on the database file. If
6797 ** "writer" lock on the database file. If the writer lock cannot be obtained
6801 ** database readers as described above. If the busy-handler returns 0 before
6802 ** the writer lock is obtained or while waiting for database readers, the
6813 ** error occurs while processing an attached database, processing is abandoned
6818 ** If database zDb is the name of an attached database that is not in WAL
6821 ** attached database, SQLITE_ERROR is returned to the caller.
6824 sqlite3 *db, /* Database handle */
6825 const char *zDb, /* Name of attached database (or NULL) */
6882 ** is able to roll back a statement or database transaction, and abandon