Here is the new version of our grouping sets patch. This version
supersedes the previous post.
We believe the functionality of this version to be substantially
complete, providing all the standard grouping set features except T434
(GROUP BY DISTINCT). (Additional tweaks, such as extra variants on
GROUPING(), could be added for compatibility with other databases.)
Since the debate regarding reserved keywords has not produced any
useful answer, the main patch here makes CUBE and ROLLUP into
col_name_reserved keywords, but a separate small patch is attached to
make them unreserved_keywords instead.
So there are now 5 files:
gsp1.patch - phase 1 code patch (full syntax, limited functionality)
gsp2.patch - phase 2 code patch (adds full functionality using the
new chained aggregate mechanism)
gsp-doc.patch - docs
gsp-contrib.patch - quote "cube" in contrib/cube and contrib/earthdistance,
intended primarily for testing pending a decision on
renaming contrib/cube or unreserving keywords
gsp-u.patch - proposed method to unreserve CUBE and ROLLUP
--
Andrew (irc:RhodiumToad)