MCPcopy
hub / github.com/sqlalchemy/sqlalchemy / label

Method label

lib/sqlalchemy/sql/selectable.py:3798–3807  ·  view source on GitHub ↗

Return a 'scalar' representation of this selectable, embedded as a subquery with a label. .. seealso:: :meth:`_expression.SelectBase.scalar_subquery`.

(self, name: Optional[str])

Source from the content-addressed store, hash-verified

3796 return ScalarSelect(self)
3797
3798 def label(self, name: Optional[str]) -> Label[Any]:
3799 """Return a 'scalar' representation of this selectable, embedded as a
3800 subquery with a label.
3801
3802 .. seealso::
3803
3804 :meth:`_expression.SelectBase.scalar_subquery`.
3805
3806 """
3807 return self.scalar_subquery().label(name)
3808
3809 def lateral(self, name: Optional[str] = None) -> LateralFromClause:
3810 """Return a LATERAL alias of this :class:`_expression.Selectable`.

Callers 2

_implicit_coercionsMethod · 0.45
_all_selected_columnsMethod · 0.45

Calls 1

scalar_subqueryMethod · 0.95

Tested by

no test coverage detected