Trait diesel::expression::SelectableHelper[][src]

pub trait SelectableHelper<DB: Backend>: Selectable<DB> + Sized {
    fn as_select() -> SelectBy<Self, DB>;

    fn as_returning() -> SelectBy<Self, DB> { ... }

This helper trait provides several methods for constructing a select or returning clause based on a Selectable implementation.

Required methods

fn as_select() -> SelectBy<Self, DB>[src]

Construct a select clause based on a Selectable implementation.

The returned select clause enforces that you use the same type for constructing the select clause and for loading the query result into.

Loading content...

Provided methods

fn as_returning() -> SelectBy<Self, DB>[src]

An alias for as_select that can be used with returning clauses

Loading content...


impl<T, DB> SelectableHelper<DB> for T where
    T: Selectable<DB>,
    DB: Backend

Loading content...