class documentation

A :class:`_asyncio.AsyncResult` that's typed as returning plain Python tuples instead of rows. Since :class:`_engine.Row` acts like a tuple in every way already, this class is a typing only class, regular :class:`_asyncio.AsyncResult` is still used at runtime.

Async Method __aiter__ Undocumented
Async Method __anext__ Undocumented
Async Method all Return all scalar values in a list.
Async Method fetchall A synonym for the :meth:`_engine.ScalarResult.all` method.
Async Method fetchmany Fetch many objects.
Async Method fetchone Fetch one tuple.
Async Method first Fetch the first object or ``None`` if no object is present.
Async Method one Return exactly one object or raise an exception.
Async Method one_or_none Return at most one object or raise an exception.
Async Method partitions Iterate through sub-lists of elements of the size given.
Async Method scalar Fetch the first column of the first row, and close the result set.
Async Method scalar_one Return exactly one scalar result or raise an exception.
Async Method scalar_one_or_none Return exactly one or no scalar result.
Class Variable __slots__ Undocumented

Inherited from AsyncCommon:

Async Method close Close this result.
Property closed proxies the .closed attribute of the underlying result object, if any, else raises ``AttributeError``.
Class Variable _metadata Undocumented
Class Variable _real_result Undocumented

Inherited from FilterResult (via AsyncCommon):

Method __enter__ Undocumented
Method __exit__ Undocumented
Method yield_per Configure the row-fetching strategy to fetch ``num`` rows at a time.
Method _fetchall_impl Undocumented
Method _fetchiter_impl Undocumented
Method _fetchmany_impl Undocumented
Method _fetchone_impl Undocumented
Method _soft_close Undocumented
Class Variable _post_creational_filter Undocumented
Property _attributes Undocumented
Property _soft_closed Undocumented

Inherited from ResultInternal (via AsyncCommon, FilterResult):

Method _allrows Undocumented
Method _column_slices Undocumented
Method _iter_impl Undocumented
Method _iterator_getter Undocumented
Method _manyrow_getter Undocumented
Method _next_impl Undocumented
Method _onerow_getter Undocumented
Method _only_one_row Undocumented
Method _raw_all_rows Undocumented
Method _row_getter Undocumented
Method _unique_strategy Undocumented
Class Variable _is_cursor Undocumented
Class Variable _row_logging_fn Undocumented
Class Variable _source_supports_scalars Undocumented
Class Variable _unique_filter_state Undocumented
Instance Variable _generate_rows Undocumented

Inherited from InPlaceGenerative (via AsyncCommon, FilterResult, ResultInternal):

Method _generate Undocumented

Inherited from TypingOnly (via AsyncCommon, FilterResult, ResultInternal, InPlaceGenerative):

Method __init_subclass__ Undocumented
async def __aiter__(self) -> AsyncIterator[_R]: (source)

Undocumented

async def __anext__(self) -> _R: (source)

Undocumented

async def all(self) -> Sequence[_R]: (source)

Return all scalar values in a list. Equivalent to :meth:`_result.Result.all` except that tuple values, rather than :class:`_engine.Row` objects, are returned.

async def fetchall(self) -> Sequence[_R]: (source)

A synonym for the :meth:`_engine.ScalarResult.all` method.

async def fetchmany(self, size: Optional[int] = None) -> Sequence[_R]: (source)

Fetch many objects. Equivalent to :meth:`_result.Result.fetchmany` except that tuple values, rather than :class:`_engine.Row` objects, are returned.

async def fetchone(self) -> Optional[_R]: (source)

Fetch one tuple. Equivalent to :meth:`_result.Result.fetchone` except that tuple values, rather than :class:`_engine.Row` objects, are returned.

async def first(self) -> Optional[_R]: (source)

Fetch the first object or ``None`` if no object is present. Equivalent to :meth:`_result.Result.first` except that tuple values, rather than :class:`_engine.Row` objects, are returned.

async def one(self) -> _R: (source)

Return exactly one object or raise an exception. Equivalent to :meth:`_result.Result.one` except that tuple values, rather than :class:`_engine.Row` objects, are returned.

async def one_or_none(self) -> Optional[_R]: (source)

Return at most one object or raise an exception. Equivalent to :meth:`_result.Result.one_or_none` except that tuple values, rather than :class:`_engine.Row` objects, are returned.

async def partitions(self, size: Optional[int] = None) -> AsyncIterator[Sequence[_R]]: (source)

Iterate through sub-lists of elements of the size given. Equivalent to :meth:`_result.Result.partitions` except that tuple values, rather than :class:`_engine.Row` objects, are returned.

@overload
async def scalar(self: AsyncTupleResult[Tuple[_T]]) -> Optional[_T]:
@overload
async def scalar(self) -> Any:
(source)

Fetch the first column of the first row, and close the result set. Returns ``None`` if there are no rows to fetch. No validation is performed to test if additional rows remain. After calling this method, the object is fully closed, e.g. the :meth:`_engine.CursorResult.close` method will have been called. :return: a Python scalar value , or ``None`` if no rows remain.

@overload
async def scalar_one(self: AsyncTupleResult[Tuple[_T]]) -> _T:
@overload
async def scalar_one(self) -> Any:
(source)

Return exactly one scalar result or raise an exception. This is equivalent to calling :meth:`_engine.Result.scalars` and then :meth:`_engine.Result.one`. .. seealso:: :meth:`_engine.Result.one` :meth:`_engine.Result.scalars`

@overload
async def scalar_one_or_none(self: AsyncTupleResult[Tuple[_T]]) -> Optional[_T]:
@overload
async def scalar_one_or_none(self) -> Optional[Any]:
(source)

Return exactly one or no scalar result. This is equivalent to calling :meth:`_engine.Result.scalars` and then :meth:`_engine.Result.one_or_none`. .. seealso:: :meth:`_engine.Result.one_or_none` :meth:`_engine.Result.scalars`