API reference@evolu/common › Sqlite

SQLite database abstraction and query execution.

Functions

FunctionDescription
booleanToSqliteBooleanConverts a JavaScript boolean to a SqliteBoolean.
createPreparedStatementsCacheCreates a PreparedStatements cache backed by the given factory and dispose function.
createSqliteCreates a Sqlite instance backed by a platform-specific driver.
getSqliteSchemaGet the current SQLite schema by reading SQLite metadata.
getSqliteSnapshotCaptures a full SqliteSnapshot for testing and diagnostics.
sqlCreates a safe SQL query using a tagged template literal.
sqliteBooleanToBooleanConverts a SqliteBoolean to a JavaScript boolean.
sqliteQueryStringToSqliteQueryConverts a SqliteQueryString back into a SqliteQuery.
sqliteQueryToSqliteQueryStringConverts a SqliteQuery into a stable SqliteQueryString.
testSetupSqliteCreates a test setup with a in-memory Sqlite.

Interfaces

InterfaceDescription
CreateSqliteDriverDep-
PreparedStatementsCache for compiled prepared statements.
RawSqlAn unescaped SQL fragment inserted verbatim into a query.
SqlIdentifierA double-quoted SQL identifier for safe column or table name interpolation.
SqlitePlatform-agnostic SQLite wrapping a SqliteDriver.
SqliteDep-
SqliteDriverSQLite driver interface.
SqliteExecResultResult of executing a SQLite query.
SqliteIndexIndex metadata stored in sqlite_master for a Sqlite database.
SqliteQueryRepresents a SQL query to be executed on a Sqlite database.
SqliteQueryOptionsOptions for configuring SqliteQuery execution behavior.
SqliteSchemaFull schema metadata for a Sqlite database.
SqliteSnapshotReturns SqliteSchema and full SqliteRow table contents for inspection and testing.
SqliteTransaction-

Type Aliases

Type AliasDescription
CreateSqliteDriverCreates a SqliteDriver.
SafeSqlA sanitized SQL string for SqliteQuery.
SqliteBooleanSQLite represents boolean values using 0 (false) and 1 (true) instead of a dedicated boolean type.
SqliteDriverOptionsOptions for creating a CreateSqliteDriver.
SqliteQueryStringSerialized SqliteQuery used as a stable string key.
SqliteRowA row returned from a Sqlite query, mapping column names to SqliteValue.
SqliteValueA value that can be stored in Sqlite.
SqlTemplateParamA parameter accepted by the sql tagged template.

Variables

VariableDescription
eqSqliteIndexEq instance for SqliteIndex.
eqSqliteValueEquality comparison for SqliteValue.
SqliteBooleanSQLite represents boolean values using 0 (false) and 1 (true) instead of a dedicated boolean type.
sqliteFalseRepresents the SqliteBoolean value for false.
SqliteIndexIndex metadata stored in sqlite_master for a Sqlite database.
SqliteSchemaFull schema metadata for a Sqlite database.
sqliteTrueRepresents the SqliteBoolean value for true.
SqliteValueA value that can be stored in Sqlite.