MCPcopy Create free account
hub / github.com/sqlalchemy/sqlalchemy / union_all

Method union_all

lib/sqlalchemy/orm/query.py:2175–2186  ·  view source on GitHub ↗

Produce a UNION ALL of this Query against one or more queries. Works the same way as :meth:`~sqlalchemy.orm.query.Query.union`. See that method for usage examples. .. seealso:: :meth:`_sql.Select.union_all` - v2 equivalent method.

(self, *q: Query[Any])

Source from the content-addressed store, hash-verified

2173 return self._set_op(expression.union, *q)
2174
2175 def union_all(self, *q: Query[Any]) -> Self:
2176 """Produce a UNION ALL of this Query against one or more queries.
2177
2178 Works the same way as :meth:`~sqlalchemy.orm.query.Query.union`. See
2179 that method for usage examples.
2180
2181 .. seealso::
2182
2183 :meth:`_sql.Select.union_all` - v2 equivalent method.
2184
2185 """
2186 return self._set_op(expression.union_all, *q)
2187
2188 def intersect(self, *q: Query[Any]) -> Self:
2189 """Produce an INTERSECT of this Query against one or more queries.

Calls 1

_set_opMethod · 0.95