diff options
author | Bruce Momjian <bruce@momjian.us> | 2023-09-26 17:31:06 -0400 |
---|---|---|
committer | Bruce Momjian <bruce@momjian.us> | 2023-09-26 17:31:06 -0400 |
commit | 28919a063d8c8b81ca574ac063e26304f41ed2fe (patch) | |
tree | 0e186a98ad2a0afc832d563a81a58339506234a2 | |
parent | 747cef5a58ca9122aca4e7a901d1f22ef70d94bc (diff) |
doc: mention GROUP BY columns can reference target col numbers
Reported-by: hape <postgres-hape@gmx.de>
Discussion: https://postgr.es/m/168871536004.379168.9352636188330923805@wrigleys.postgresql.org
Backpatch-through: 11
-rw-r--r-- | doc/src/sgml/ref/select.sgml | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/doc/src/sgml/ref/select.sgml b/doc/src/sgml/ref/select.sgml index 181edf32741..b4a3f029b79 100644 --- a/doc/src/sgml/ref/select.sgml +++ b/doc/src/sgml/ref/select.sgml @@ -131,6 +131,9 @@ TABLE [ ONLY ] <replaceable class="parameter">table_name</replaceable> [ * ] eliminates groups that do not satisfy the given condition. (See <xref linkend="sql-groupby"/> and <xref linkend="sql-having"/> below.) + Although query output columns are nominally computed in the next + step, they can also be referenced (by name or ordinal number) + in the <literal>GROUP BY</literal> clause. </para> </listitem> |