2 unstable releases
Uses new Rust 2024
| new 0.2.0 | Feb 15, 2026 |
|---|---|
| 0.1.1 | Feb 5, 2026 |
#2329 in Database interfaces
Used in 2 crates
1MB
18K
SLoC
Type-safe SQL query builder for SQLModel Rust.
sqlmodel-query is the query construction layer. It provides the fluent builder
API and expression DSL that turn Model metadata into executable SQL plus parameters.
Role In The Architecture
- Query macros:
select!,insert!,update!,delete!build typed queries. - Expression DSL:
Exprand operators build WHERE/HAVING clauses safely. - Dialect support: generates SQL for Postgres, MySQL, and SQLite.
The resulting queries execute through the Connection trait from sqlmodel-core.
Most users access these builders via the sqlmodel facade crate.
sqlmodel-query
Type-safe SQL query builder and expression DSL.
Role in the SQLModel Rust System
- Provides select!/insert!/update!/delete! macros.
- Builds SQL + params across Postgres/MySQL/SQLite dialects.
- Executes via sqlmodel-core::Connection implementations.
Usage
Most users should depend on sqlmodel and import from sqlmodel::prelude::*.
Use this crate directly if you are extending internals or building tooling around the core APIs.
Links
Dependencies
~26–43MB
~650K SLoC