Skip to main content

Crate musq

Crate musq 

Source
Expand description

An async SQLite driver focused on performance, correctness, and flexibility.

Musq supports the SQLite release bundled by its libsqlite3-sys dependency. It does not support linking against older or system SQLite libraries. With libsqlite3-sys 0.38.1, the bundled SQLite release is 3.53.2.

Re-exports§

pub use crate::types::vec::VecBit;vec
pub use crate::types::vec::VecF32;vec
pub use crate::types::vec::VecInt8;vec
pub use crate::encode::Null;
pub use crate::encode::Null;
pub use crate::error::DecodeError;
pub use crate::error::EncodeError;
pub use crate::error::Error;
pub use crate::error::Result;
pub use crate::expr::Expr;
pub use crate::query::Query;
pub use crate::query::query;
pub use crate::query::query_as;
pub use crate::query::query_as_with;
pub use crate::query::query_scalar;
pub use crate::query::query_scalar_with;
pub use crate::query::query_with;
pub use crate::query::quote_identifier;

Modules§

decode
Decoding support for database values. Provides Decode for decoding values from the database.
encode
Encoding support for database values. Provides Encode for encoding values for the database.
error
Error types and result helpers. Types for working with errors produced by Musq.
expr
SQL expression helpers for dynamic queries. Helpers for building safe SQL expressions for use with Values.
query
Query types and helpers.
types
Built-in type adapters. Conversions between Rust and SQLite types.

Macros§

sql
Expand a SQL query from a format string and arguments.
sql_as
Expand a SQL query that maps rows into a destination type.
values
Build a Values collection from literal key/value pairs.

Structs§

Arguments
Collection of bound SQL arguments.
Connection
A single, standalone connection to a SQLite database.
DbStatus
A database-connection status measurement.
Musq
Create a Musq connection
Pool
An asynchronous pool of database connections.
PoolConnection
A single database connection acquired from a crate::Pool.
PoolStats
Point-in-time diagnostic counters for a Pool.
Prepared
A prepared statement that can build executable queries.
QueryBuilder
Incrementally build a SQL query with bound parameters.
QueryResult
Summary information returned after executing a query.
Row
Implementation of Row for SQLite.
SqliteError
An error returned from Sqlite
SqliteRuntimeInfo
Runtime identity and compile options for the bundled SQLite library.
Transaction
An in-progress database transaction or savepoint.
Values
An ordered collection of key-value pairs for building dynamic SQL queries.
WalCheckpoint
Result of a WAL checkpoint operation.

Enums§

AutoVacuum
Refer to SQLite documentation for auto-vacuum mode semantics.
DbStatusKind
Per-connection SQLite status counter.
JournalMode
Refer to SQLite documentation for the meaning of the database journaling mode.
LockingMode
Refer to SQLite documentation for the meaning of the connection locking mode.
SqliteDataType
Data types supported by SQLite.
Synchronous
Refer to SQLite documentation for the meaning of various synchronous settings.
Value
Owned representation of a SQLite value.
ValuesEntry
A value in a Values collection.
WalCheckpointMode
WAL checkpoint mode.

Traits§

AllNull
Helper trait used internally to determine if all columns belonging to a record are NULL in a given row.
Execute
A type that may be executed against a database connection.
FromRow
A record that can be built from a row returned by the database.
IntoValuesEntry
Convert a value into a ValuesEntry.

Derive Macros§

Codec
Derive combined encode and decode implementations.
Decode
Derive a Decode implementation.
Encode
Derive an Encode implementation.
FromRow
Derive a FromRow implementation.
Json
Derive JSON encode/decode implementations.