pub struct CteChain { /* private fields */ }Expand description
A common table expression under construction.
with("recent", body) is already a complete mod; the methods add the optional
parts of SQLite’s common-table-expression production
(https://www.sqlite.org/syntax/common-table-expression.html):
table-name [ ( column-name [, ...] ) ] AS [ [ NOT ] MATERIALIZED ] ( select-stmt )PostgreSQL’s SEARCH and CYCLE sub-clauses have no counterpart in SQLite, so
they are not reachable from here. Nor is a data-modifying CTE: SQLite’s grammar
admits only a select-stmt between the parentheses.
Implementations§
Source§impl CteChain
impl CteChain
Sourcepub fn columns(
self,
columns: impl IntoIterator<Item = impl Into<Cow<'static, str>>>,
) -> CteChain
pub fn columns( self, columns: impl IntoIterator<Item = impl Into<Cow<'static, str>>>, ) -> CteChain
Name the CTE’s output columns: WITH "c" ("a", "b") AS (…).
Sourcepub fn materialized(self) -> CteChain
pub fn materialized(self) -> CteChain
AS MATERIALIZED (…) — compute it once into a transient table. SQLite 3.35
and later.
Sourcepub fn not_materialized(self) -> CteChain
pub fn not_materialized(self) -> CteChain
AS NOT MATERIALIZED (…) — allow it to be folded into the outer query.
Trait Implementations§
Auto Trait Implementations§
impl !RefUnwindSafe for CteChain
impl !UnwindSafe for CteChain
impl Freeze for CteChain
impl Send for CteChain
impl Sync for CteChain
impl Unpin for CteChain
impl UnsafeUnpin for CteChain
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more