diff options
| author | David Rowley | 2022-12-24 00:18:35 +0000 |
|---|---|---|
| committer | David Rowley | 2022-12-24 00:18:35 +0000 |
| commit | b5aff9255700b0b3155a4d2be865b6a776c2bda4 (patch) | |
| tree | e37e34d45f5e304bd2852555a945bdd12a001068 /src/test | |
| parent | c6f21b2ac215ad870a95159ea22024f734429622 (diff) | |
Fix recent accidental omission in pg_proc.dat
ed1a88dda added support functions for the ntile(), percent_rank() and
cume_dist() window functions but neglected to actually add these support
functions to the pg_proc entry for the corresponding window function.
Also, take this opportunity to add these window functions to one of the
regression tests added in ed1a88dda to give the support functions a little
bit of exercise. If I'd done that in the first place then the omission
would have been more obvious.
Bump the catversion, again.
Diffstat (limited to 'src/test')
| -rw-r--r-- | src/test/regress/expected/window.out | 8 | ||||
| -rw-r--r-- | src/test/regress/sql/window.sql | 8 |
2 files changed, 14 insertions, 2 deletions
diff --git a/src/test/regress/expected/window.out b/src/test/regress/expected/window.out index 776861808b..5505e9a2da 100644 --- a/src/test/regress/expected/window.out +++ b/src/test/regress/expected/window.out @@ -3326,7 +3326,13 @@ SELECT rank() OVER (PARTITION BY depname ORDER BY enroll_date ROWS BETWEEN UNBOUNDED PRECEDING AND UNBOUNDED FOLLOWING) rnk, dense_rank() OVER (PARTITION BY depname ORDER BY enroll_date RANGE BETWEEN - CURRENT ROW AND CURRENT ROW) drnk + CURRENT ROW AND CURRENT ROW) drnk, + ntile(10) OVER (PARTITION BY depname ORDER BY enroll_date RANGE BETWEEN + CURRENT ROW AND UNBOUNDED FOLLOWING) nt, + percent_rank() OVER (PARTITION BY depname ORDER BY enroll_date ROWS BETWEEN + CURRENT ROW AND UNBOUNDED FOLLOWING) pr, + cume_dist() OVER (PARTITION BY depname ORDER BY enroll_date RANGE BETWEEN + CURRENT ROW AND UNBOUNDED FOLLOWING) cd FROM empsalary; QUERY PLAN ---------------------------------------- diff --git a/src/test/regress/sql/window.sql b/src/test/regress/sql/window.sql index deaf2217a6..10f450fee4 100644 --- a/src/test/regress/sql/window.sql +++ b/src/test/regress/sql/window.sql @@ -987,7 +987,13 @@ SELECT rank() OVER (PARTITION BY depname ORDER BY enroll_date ROWS BETWEEN UNBOUNDED PRECEDING AND UNBOUNDED FOLLOWING) rnk, dense_rank() OVER (PARTITION BY depname ORDER BY enroll_date RANGE BETWEEN - CURRENT ROW AND CURRENT ROW) drnk + CURRENT ROW AND CURRENT ROW) drnk, + ntile(10) OVER (PARTITION BY depname ORDER BY enroll_date RANGE BETWEEN + CURRENT ROW AND UNBOUNDED FOLLOWING) nt, + percent_rank() OVER (PARTITION BY depname ORDER BY enroll_date ROWS BETWEEN + CURRENT ROW AND UNBOUNDED FOLLOWING) pr, + cume_dist() OVER (PARTITION BY depname ORDER BY enroll_date RANGE BETWEEN + CURRENT ROW AND UNBOUNDED FOLLOWING) cd FROM empsalary; -- Ensure WindowFuncs which cannot support their WindowClause's frameOptions |
