postgresql/src/include/parser
Tom Lane bb16dc49ab Modify the definition of window-function PARTITION BY and ORDER BY clauses
so that their elements are always taken as simple expressions over the
query's input columns.  It originally seemed like a good idea to make them
act exactly like GROUP BY and ORDER BY, right down to the SQL92-era behavior
of accepting output column names or numbers.  However, that was not such a
great idea, for two reasons:

1. It permits circular references, as exhibited in bug #5018: the output
column could be the one containing the window function itself.  (We actually
had a regression test case illustrating this, but nobody thought twice about
how confusing that would be.)

2. It doesn't seem like a good idea for, eg, "lead(foo) OVER (ORDER BY foo)"
to potentially use two completely different meanings for "foo".

Accordingly, narrow down the behavior of window clauses to use only the
SQL99-compliant interpretation that the expressions are simple expressions.
2009-08-27 20:08:03 +00:00
..
analyze.h Update copyright for 2009. 2009-01-01 17:24:05 +00:00
gramparse.h Tweak the core scanner so that it can be used by plpgsql too. 2009-07-14 20:24:10 +00:00
keywords.h Tweak the core scanner so that it can be used by plpgsql too. 2009-07-14 20:24:10 +00:00
kwlist.h Rename the new CREATE DATABASE options to set collation and ctype into 2009-04-06 08:42:53 +00:00
parse_agg.h 8.4 pgindent run, with new combined Linux/FreeBSD/MinGW typedef list 2009-06-11 14:49:15 +00:00
parse_clause.h Modify the definition of window-function PARTITION BY and ORDER BY clauses 2009-08-27 20:08:03 +00:00
parse_coerce.h 8.4 pgindent run, with new combined Linux/FreeBSD/MinGW typedef list 2009-06-11 14:49:15 +00:00
parse_cte.h Update copyright for 2009. 2009-01-01 17:24:05 +00:00
parse_expr.h Update copyright for 2009. 2009-01-01 17:24:05 +00:00
parse_func.h Do some minor code refactoring in preparation for changing the APIs of 2009-05-12 00:56:05 +00:00
parse_node.h 8.4 pgindent run, with new combined Linux/FreeBSD/MinGW typedef list 2009-06-11 14:49:15 +00:00
parse_oper.h Update copyright for 2009. 2009-01-01 17:24:05 +00:00
parse_relation.h 8.4 pgindent run, with new combined Linux/FreeBSD/MinGW typedef list 2009-06-11 14:49:15 +00:00
parse_target.h Update copyright for 2009. 2009-01-01 17:24:05 +00:00
parse_type.h Make backend header files C++ safe 2009-07-16 06:33:46 +00:00
parse_utilcmd.h Update copyright for 2009. 2009-01-01 17:24:05 +00:00
parser.h Fix up PGDLLIMPORT marking for standard_conforming_strings. Moving it 2009-07-13 00:42:18 +00:00
parsetree.h Update copyright for 2009. 2009-01-01 17:24:05 +00:00
scansup.h Update copyright for 2009. 2009-01-01 17:24:05 +00:00