pub struct Query {
pub with: Option<With>,
pub body: SetExpr,
pub order_by: Vec<OrderByExpr>,
pub limit: Option<Expr>,
pub offset: Option<Offset>,
pub fetch: Option<Fetch>,
pub lock: Option<LockType>,
}
Expand description
The most complete variant of a SELECT
query expression, optionally
including WITH
, UNION
/ other set operations, and ORDER BY
.
Fields
with: Option<With>
WITH (common table expressions, or CTEs)
body: SetExpr
SELECT or UNION / EXCEPT / INTERSECT
order_by: Vec<OrderByExpr>
ORDER BY
limit: Option<Expr>
LIMIT { <N> | ALL }
offset: Option<Offset>
OFFSET <N> [ { ROW | ROWS } ]
fetch: Option<Fetch>
FETCH { FIRST | NEXT } <N> [ PERCENT ] { ROW | ROWS } | { ONLY | WITH TIES }
lock: Option<LockType>
FOR { UPDATE | SHARE }
Trait Implementations
impl Eq for Query
impl StructuralEq for Query
impl StructuralPartialEq for Query
Auto Trait Implementations
impl RefUnwindSafe for Query
impl Send for Query
impl Sync for Query
impl Unpin for Query
impl UnwindSafe for Query
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> ToOwned for T where
T: Clone,
impl<T> ToOwned for T where
T: Clone,
type Owned = T
type Owned = T
The resulting type after obtaining ownership.
sourcefn clone_into(&self, target: &mut T)
fn clone_into(&self, target: &mut T)
🔬 This is a nightly-only experimental API. (
toowned_clone_into
)Uses borrowed data to replace owned data, usually by cloning. Read more