MCPcopy
hub / github.com/sqlalchemy/sqlalchemy / intersect

Method intersect

lib/sqlalchemy/sql/selectable.py:6997–7014  ·  view source on GitHub ↗

r"""Return a SQL ``INTERSECT`` of this select() construct against the given selectables provided as positional arguments. :param \*other: one or more elements with which to create a UNION. .. versionchanged:: 1.4.28 multiple elements are now accepted.

(
        self, *other: _SelectStatementForCompoundArgument[Unpack[_Ts]]
    )

Source from the content-addressed store, hash-verified

6995 return CompoundSelect._create_except_all(self, *other)
6996
6997 def intersect(
6998 self, *other: _SelectStatementForCompoundArgument[Unpack[_Ts]]
6999 ) -> CompoundSelect[Unpack[_Ts]]:
7000 r"""Return a SQL ``INTERSECT`` of this select() construct against
7001 the given selectables provided as positional arguments.
7002
7003 :param \*other: one or more elements with which to create a
7004 UNION.
7005
7006 .. versionchanged:: 1.4.28
7007
7008 multiple elements are now accepted.
7009
7010 :param \**kwargs: keyword arguments are forwarded to the constructor
7011 for the newly created :class:`_sql.CompoundSelect` object.
7012
7013 """
7014 return CompoundSelect._create_intersect(self, *other)
7015
7016 def intersect_all(
7017 self, *other: _SelectStatementForCompoundArgument[Unpack[_Ts]]

Callers

nothing calls this directly

Calls 1

_create_intersectMethod · 0.80

Tested by

no test coverage detected