pub struct QueryResult<T, P>(_);
Expand description

Result of a query or statement execution.

Implementations§

Last insert id (if not 0).

Value of affected_rows returned from a server.

true if there is no more rows nor result sets in this query.

One could use it to check if there is more than one result set in this query result.

Returns future that collects result set of this query result.

It is parametrized by R and internally calls R::from_row(Row) on each row.

It will stop collecting on result set boundary. This means that you should call collect as many times as result sets in your query result. For example query SELECT 'foo'; SELECT 'foo', 'bar'; will produce QueryResult with two result sets in it. One can use QueryResult::is_empty to make sure that there is no more result sets.

Returns future that collects result set of a query result and drops everything else. It will resolve to a pair of wrapped Queryable and collected result set.

Returns future that will execute fun on every row of current result set.

It will stop on result set boundary (see QueryResult::collect docs).

Returns future that will execute fun on every row of current result set and drop everything else. It will resolve to a wrapped Queryable.

Returns future that will map every row of current result set to U using fun.

It will stop on result set boundary (see QueryResult::collect docs).

Returns future that will map every row of current result set to U using fun and drop everything else. It will resolve to a pair of wrapped Queryable and mapped result set.

Returns future that will reduce rows of current result set to U using fun.

It will stop on result set boundary (see QueryResult::collect docs).

Returns future that will reduce rows of current result set to U using fun and drop everything else. It will resolve to a pair of wrapped Queryable and U.

Returns future that will drop this query result end resolve to a wrapped Queryable.

Returns reference to columns in this query result.

Returns copy of columns of this query result.

Auto Trait Implementations§

Blanket Implementations§

Gets the TypeId of self. Read more
Immutably borrows from an owned value. Read more
Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Should always be Self
The type returned in the event of a conversion error.
Performs the conversion.
The type returned in the event of a conversion error.
Performs the conversion.