summaryrefslogtreecommitdiff
path: root/lib/sqlalchemy/dialects/postgresql/base.py
diff options
context:
space:
mode:
authorMike Bayer <mike_mp@zzzcomputing.com>2022-07-10 21:24:17 -0400
committerMike Bayer <mike_mp@zzzcomputing.com>2022-07-10 21:27:12 -0400
commit3916bfc9ccf2904f69498075849a82ceee225b3a (patch)
treeab835bf174a4047de0d2b62f6a3ac2731c321434 /lib/sqlalchemy/dialects/postgresql/base.py
parent805a1323b973a30af99ce506dd5c5c4ab96cff0f (diff)
downloadsqlalchemy-3916bfc9ccf2904f69498075849a82ceee225b3a.tar.gz
support "SELECT *" for ORM queries
A :func:`_sql.select` construct that is passed a sole '*' argument for ``SELECT *``, either via string, :func:`_sql.text`, or :func:`_sql.literal_column`, will be interpreted as a Core-level SQL statement rather than as an ORM level statement. This is so that the ``*``, when expanded to match any number of columns, will result in all columns returned in the result. the ORM- level interpretation of :func:`_sql.select` needs to know the names and types of all ORM columns up front which can't be achieved when ``'*'`` is used. If ``'*`` is used amongst other expressions simultaneously with an ORM statement, an error is raised as this can't be interpreted correctly by the ORM. Fixes: #8235 Change-Id: Ic8e84491e14acdc8570704eadeaeaf6e16b1e870
Diffstat (limited to 'lib/sqlalchemy/dialects/postgresql/base.py')
0 files changed, 0 insertions, 0 deletions