Expand description
Contains traits responsible for the actual construction of SQL statements
The types in this module are part of Diesel’s public API, but are generally only useful for implementing Diesel plugins. Applications should generally not need to care about the types inside of this module.
Modules§
- bind_
collector - Types related to managing bind parameters during query construction.
Structs§
- AstPass
- The primary type used when walking a Diesel AST during query execution.
- Boxed
SqlQuery - See
SqlQuery::into_boxed. - Collected
Query - A SQL query variant with already collected bind data which can be moved
- Debug
Query - A struct that implements
fmt::Displayandfmt::Debugto show the SQL representation of a query. - Delete
Statement - Represents a SQL
DELETEstatement. - Incomplete
Insert Statement - The structure returned by
insert_into. - Insert
Statement - A fully constructed insert statement.
- SqlQuery
- The return value of
sql_query. - Update
Statement - Represents a complete
UPDATEstatement. - Update
Target
Traits§
- AsChangeset
- Types which can be passed to
update.set. - AsQuery
- Types that can be converted into a complete, typed SQL query.
- Bind
Collector - A type which manages serializing bind parameters during query construction.
- Decoratable
Target - Interface to add information to conflict targets. Designed to be open for further additions to conflict targets like constraints
- Into
Boxed Clause - A trait used to construct type erased boxed variant of the current query node
- Into
Update Target - A type which can be passed to
updateordelete. - Moveable
Bind Collector - A movable version of the bind collector which allows it to be extracted, moved and refilled.
- Query
- A complete SQL query with a return type.
- Query
Builder - Constructs a SQL query from a Diesel AST.
- Query
Fragment - An untyped fragment of SQL.
- QueryId
- Uniquely identifies queries by their type for the purpose of prepared statement caching.
- Select
Query - Indicates that a type is a
SELECTstatement.
Functions§
- debug_
query - Takes a query
QueryFragmentexpression as an argument and returns a type that implementsfmt::Displayandfmt::Debugto show the query.
Type Aliases§
- Boxed
Delete Statement - A
DELETEstatement with a boxedWHEREclause - Boxed
Update Statement - An
UPDATEstatement with a boxedWHEREclause. - Build
Query Result - A specialized Result type used with the query builder.
- Incomplete
Insert OrIgnore Statement - Represents the return type of
diesel::insert_or_ignore_into - Incomplete
Replace Statement - Represents the return type of
diesel::replace_into - Insert
OrIgnore Statement - Represents a complete
INSERT OR IGNOREstatement. - Replace
Statement - Represents a complete
INSERT OR REPLACEstatement.
Derive Macros§
- AsChangeset
- Implements
AsChangeset - QueryId
- Implements
QueryId