Re: [HACKERS] Grouping Sets: Fix unrecognized node type bug

2015-07-26 Thread Andres Freund
On 2015-07-17 19:57:22 +0100, Andrew Gierth wrote: > Attached is the current version of my fix (with Jeevan's regression > tests plus one of mine). Pushed, thanks for the report and fix! -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription:

Re: [HACKERS] Grouping Sets: Fix unrecognized node type bug

2015-07-26 Thread Andres Freund
On 2015-07-17 11:37:26 +0530, Jeevan Chalke wrote: > However I wonder why we are supporting GROUPING SETS inside GROUPING SETS. > On Oracle, it is throwing an error. > We are not trying to be Oracle compatible, but just curious to know. The SQL specification seems to be pretty unambigous about sup

Re: [HACKERS] Grouping Sets: Fix unrecognized node type bug

2015-07-21 Thread Kyotaro HORIGUCHI
Hello, At Mon, 20 Jul 2015 15:45:21 +0530, Jeevan Chalke wrote in > On Sat, Jul 18, 2015 at 12:27 AM, Andrew Gierth > wrote: > > > > "Kyotaro" == Kyotaro HORIGUCHI > > writes: > > > > Kyotaro> Hello, this looks to be a kind of thinko. The attached patch > > Kyotaro> fixes it. > > > >

Re: [HACKERS] Grouping Sets: Fix unrecognized node type bug

2015-07-20 Thread Jeevan Chalke
On Sat, Jul 18, 2015 at 12:27 AM, Andrew Gierth wrote: > > "Kyotaro" == Kyotaro HORIGUCHI > writes: > > Kyotaro> Hello, this looks to be a kind of thinko. The attached patch > Kyotaro> fixes it. > > No, that's still wrong. Just knowing that there is a List is not enough > to tell whether t

Re: [HACKERS] Grouping Sets: Fix unrecognized node type bug

2015-07-17 Thread Andrew Gierth
> "Kyotaro" == Kyotaro HORIGUCHI writes: Kyotaro> Hello, this looks to be a kind of thinko. The attached patch Kyotaro> fixes it. No, that's still wrong. Just knowing that there is a List is not enough to tell whether to concat it or append it. Jeevan's original patch tries to get around

Re: [HACKERS] Grouping Sets: Fix unrecognized node type bug

2015-07-17 Thread Kyotaro HORIGUCHI
Hello, this looks to be a kind of thinko. The attached patch fixes it. === According to the comment of transformGroupingSet, it assumes that the given GROUPING SETS node is already flatted out and flatten_grouping_sets() does that. The details of the transformation is described in the comment for

Re: [HACKERS] Grouping Sets: Fix unrecognized node type bug

2015-07-16 Thread Jeevan Chalke
On Wed, Jul 15, 2015 at 10:21 PM, Andrew Gierth wrote: > > "Jeevan" == Jeevan Chalke writes: > > Jeevan> Hi, > Jeevan> It looks like we do support nested GROUPING SETS, I mean Sets > Jeevan> withing Sets, not other types. However this nesting is broken. > > Good catch, but I'm not yet su

Re: [HACKERS] Grouping Sets: Fix unrecognized node type bug

2015-07-15 Thread Andrew Gierth
> "Jeevan" == Jeevan Chalke writes: Jeevan> Hi, Jeevan> It looks like we do support nested GROUPING SETS, I mean Sets Jeevan> withing Sets, not other types. However this nesting is broken. Good catch, but I'm not yet sure your fix is correct; I'll need to look into that. -- Andrew (irc

[HACKERS] Grouping Sets: Fix unrecognized node type bug

2015-07-15 Thread Jeevan Chalke
Hi, It looks like we do support nested GROUPING SETS, I mean Sets withing Sets, not other types. However this nesting is broken. Here is the simple example where I would expect three rows in the result. But unfortunately it is giving "unrecognized node type" error. Which is something weird and

Re: [HACKERS] Grouping Sets

2013-07-04 Thread Dev Kumkar
On Thu, Jul 4, 2013 at 7:53 PM, Atri Sharma wrote: > On Thu, Jul 4, 2013 at 6:56 PM, Dev Kumkar > wrote: > > Ok, no problem. Will await for any other pointers regarding any related > > patch here. > > > > Currently using UNION to archive similar results but looking if anything > is > > already d

Re: [HACKERS] Grouping Sets

2013-07-04 Thread Atri Sharma
On Thu, Jul 4, 2013 at 6:56 PM, Dev Kumkar wrote: > On Thu, Jul 4, 2013 at 6:31 PM, Pavel Stehule > wrote: >> >> Hello >> >> >> I don't work on this topic now, and my code is not usable for production. > > > Ok, no problem. Will await for any other pointers regarding any related > patch here. > >

Re: [HACKERS] Grouping Sets

2013-07-04 Thread Dev Kumkar
On Thu, Jul 4, 2013 at 6:31 PM, Pavel Stehule wrote: > Hello > > I don't work on this topic now, and my code is not usable for production. Ok, no problem. Will await for any other pointers regarding any related patch here. Currently using UNION to archive similar results but looking if anything

Re: [HACKERS] Grouping Sets

2013-07-04 Thread Pavel Stehule
Hello 2013/7/4 Dev Kumkar : > Hello, > > Am looking for the patch related to 'Implementation of GROUPING SETS'. > Where can get this from? > > Related thread: > http://www.postgresql.org/message-id/162867790905121420p7c910054x24d8e327abd58...@mail.gmail.com > I don't work on this topic now, and m

[HACKERS] Grouping Sets

2013-07-04 Thread Dev Kumkar
Hello, Am looking for the patch related to 'Implementation of GROUPING SETS'. Where can get this from? Related thread: http://www.postgresql.org/message-id/162867790905121420p7c910054x24d8e327abd58...@mail.gmail.com Regards...

Re: [HACKERS] Grouping Sets

2011-09-20 Thread Pavel Stehule
mber 19, 2011 10:45 PM > To: edwbro...@gmail.com > Cc: pgsql-hackers@postgresql.org > Subject: Re: [HACKERS] Grouping Sets > > Hello > > 2011/9/20 David Rinaldi : >> Paul, >> >> I was able to apply the patch to 9.0.4 and so far looks good.  My Oracle >&g

Re: [HACKERS] Grouping Sets

2011-09-20 Thread David Rinaldi
40 hours or more like 5000 hours, in your estimate? Thanks. -- Regards David -Original Message- From: Pavel Stehule [mailto:pavel.steh...@gmail.com] Sent: Monday, September 19, 2011 10:45 PM To: edwbro...@gmail.com Cc: pgsql-hackers@postgresql.org Subject: Re: [HACKERS] Grouping Sets

Re: [HACKERS] Grouping Sets

2011-09-19 Thread Pavel Stehule
h rep.      1   8000    0.8     80      80 > bmw     germany 18000   15000   0.8333  83. 83 > > > > Thanks > > > > > -- > Regards > > David > > > -Original Message- > From: Pavel Stehule [mailto:pavel.steh...@gmail.com] > Sent: Sunda

Re: [HACKERS] Grouping Sets

2011-09-19 Thread David Rinaldi
0.7143 71.4286 71 skoda czech rep. 1 80000.8 80 80 bmw germany 18000 15000 0.8333 83. 83 Thanks -- Regards David -Original Message- From: Pavel Stehule [mailto:pavel.steh...@gmail.com] Sent: Sunday, September 18, 2011 2:34 PM To: David

Re: [HACKERS] Grouping Sets

2011-09-19 Thread Joshua Tolley
On Sun, Sep 18, 2011 at 02:08:01PM -0500, David Rinaldi wrote: > I tried to apply the Grouping Sets Patch to 8.4, but received several Hunks > failed messages, does anyone know if the failing hunks can be applied > manually? Or what version they were applied to specifically? Your best bet is prob

[HACKERS] Grouping Sets

2011-09-18 Thread David Rinaldi
Hi, I tried to apply the Grouping Sets Patch to 8.4, but received several Hunks failed messages, does anyone know if the failing hunks can be applied manually? Or what version they were applied to specifically? -- Regards David

Re: [HACKERS] Grouping Sets

2011-06-20 Thread Pavel Stehule
Hello I have not any newest patch related to GROUPING SETS. The last version of this patch is probably correct, but it is not well tested. Actually, this patch has not quality to production usage :(. It is just concept. You can test it. Regards Pavel Stehule 2011/6/18 Mariano Mara : > Hi hacker

[HACKERS] Grouping Sets

2011-06-18 Thread Mariano Mara
Hi hackers (and specially Pavel Stehule), I could really use the grouping set feature for some complex queries I'm migrating from other db vendor. If my WEB searching is precise, this wiki page [1] and this thread[2] are the last updates on the subject. I'm willing to test how these functions

Re: [HACKERS] GROUPING SETS revisited

2010-08-18 Thread Pavel Stehule
Hello I found a break in GROUPING SETS implementation. Now I am playing with own executor and planner node and I can't to go forward :(. Probably this feature will need a significant update of our agg implementation. Probably needs a some similar structure like CTE but it can be a little bit reduc

Re: [HACKERS] grouping sets - updated patch

2010-08-09 Thread Pavel Stehule
2010/8/10 Joshua Tolley : > On Mon, Aug 09, 2010 at 10:59:26PM +0200, Pavel Stehule wrote: >> Hello >> >> I fixed an issues with empty sets. It just work, but there are some ugly >> hacks. >> >> It's really needs own planner node - now grouping functions are not >> supported by ORDER BY clause. >

Re: [HACKERS] grouping sets - updated patch

2010-08-09 Thread Joshua Tolley
On Mon, Aug 09, 2010 at 10:59:26PM +0200, Pavel Stehule wrote: > Hello > > I fixed an issues with empty sets. It just work, but there are some ugly > hacks. > > It's really needs own planner node - now grouping functions are not > supported by ORDER BY clause. I haven't made it through the last

Re: [HACKERS] GROUPING SETS revisited

2010-08-09 Thread Pavel Stehule
Hello I was confused when I though so I found a solution of 1 shift/reduce conflict :( All identificators used for buildin functions have to be a col_name_keywords or reserved keyword. There is conflict with our (probably obsolete) feature SELECT colname(tabname). So for this moment the real solu

Re: [HACKERS] GROUPING SETS revisited

2010-08-06 Thread Pavel Stehule
2010/8/7 Joshua Tolley : > On Thu, Aug 05, 2010 at 04:46:51PM +0200, Pavel Stehule wrote: >> I am sending a updated version. > > I've been looking at the changes to gram.y, and noted the comment under > func_expr > where you added CUBE and ROLLUP definitions. It says that CUBE can't be a > reserve

Re: [HACKERS] GROUPING SETS revisited

2010-08-06 Thread Joshua Tolley
On Thu, Aug 05, 2010 at 04:46:51PM +0200, Pavel Stehule wrote: > I am sending a updated version. I've been looking at the changes to gram.y, and noted the comment under func_expr where you added CUBE and ROLLUP definitions. It says that CUBE can't be a reserved keyword because it's already used i

Re: [HACKERS] GROUPING SETS revisited

2010-08-05 Thread Pavel Stehule
I found other issue :( postgres=# select name, place from cars group by grouping sets(name, place,()); name | place ---+ bmw | skoda | opel | | germany | czech rep. skoda | czech rep. skoda | germany bmw | czech rep. bmw | germany opel | czech rep

Re: [HACKERS] GROUPING SETS revisited

2010-08-05 Thread Joshua Tolley
On Thu, Aug 05, 2010 at 04:46:51PM +0200, Pavel Stehule wrote: > So Joshua, can you look on code? Sure... thanks :) -- Joshua Tolley / eggyknap End Point Corporation http://www.endpoint.com signature.asc Description: Digital signature

Re: [HACKERS] GROUPING SETS revisited

2010-08-04 Thread Joshua Tolley
On Thu, Aug 05, 2010 at 06:21:18AM +0200, Pavel Stehule wrote: > I hope, so next week you can do own work on this job - I am not a > native speaker, and my code will need a checking and fixing comments I haven't entirely figured out how the code in the old patch works, but I promise I *can* edit c

Re: [HACKERS] GROUPING SETS revisited

2010-08-04 Thread Pavel Stehule
2010/8/4 Joshua Tolley : > On Wed, Aug 04, 2010 at 04:44:05AM +0200, Pavel Stehule wrote: >> > Yeah, I seem to have done a poor job of producing the patch based on the >> > repository I was working from. That said, it seems Pavel's working >> > actively on >> > a patch anyway, so perhaps my updati

Re: [HACKERS] GROUPING SETS revisited

2010-08-04 Thread Joshua Tolley
On Wed, Aug 04, 2010 at 04:44:05AM +0200, Pavel Stehule wrote: > > Yeah, I seem to have done a poor job of producing the patch based on the > > repository I was working from. That said, it seems Pavel's working actively > > on > > a patch anyway, so perhaps my updating the old one isn't all that

Re: [HACKERS] GROUPING SETS revisited

2010-08-03 Thread Pavel Stehule
2010/8/3 Joshua Tolley : > On Tue, Aug 03, 2010 at 12:58:03PM -0700, David Fetter wrote: >> On Mon, Aug 02, 2010 at 11:50:00PM -0600, Josh Tolley wrote: >> > In case anyone's interested, I've taken the CTE-based grouping sets >> > patch from [1] and made it apply to 9.1, attached. I haven't yet >>

Re: [HACKERS] GROUPING SETS revisited

2010-08-03 Thread Joshua Tolley
On Tue, Aug 03, 2010 at 12:58:03PM -0700, David Fetter wrote: > On Mon, Aug 02, 2010 at 11:50:00PM -0600, Josh Tolley wrote: > > In case anyone's interested, I've taken the CTE-based grouping sets > > patch from [1] and made it apply to 9.1, attached. I haven't yet > > done things like checked it f

Re: [HACKERS] GROUPING SETS revisited

2010-08-03 Thread David Fetter
On Mon, Aug 02, 2010 at 11:50:00PM -0600, Josh Tolley wrote: > In case anyone's interested, I've taken the CTE-based grouping sets > patch from [1] and made it apply to 9.1, attached. I haven't yet > done things like checked it for whitespace consistency, style > conformity, or anything else, but (

Re: [HACKERS] GROUPING SETS revisited

2010-08-03 Thread Pavel Stehule
2010/8/3 Hitoshi Harada : > 2010/8/3 Pavel Stehule : >> Hello >> >> 2010/8/3 Joshua Tolley : >>> In case anyone's interested, I've taken the CTE-based grouping sets patch >>> from >>> [1] and made it apply to 9.1, attached. I haven't yet done things like >>> checked >>> it for whitespace consiste

Re: [HACKERS] GROUPING SETS revisited

2010-08-03 Thread Hitoshi Harada
2010/8/3 Pavel Stehule : > Hello > > 2010/8/3 Joshua Tolley : >> In case anyone's interested, I've taken the CTE-based grouping sets patch >> from >> [1] and made it apply to 9.1, attached. I haven't yet done things like >> checked >> it for whitespace consistency, style conformity, or anything e

Re: [HACKERS] GROUPING SETS revisited

2010-08-02 Thread Pavel Stehule
Hello 2010/8/3 Joshua Tolley : > In case anyone's interested, I've taken the CTE-based grouping sets patch from > [1] and made it apply to 9.1, attached. I haven't yet done things like checked > it for whitespace consistency, style conformity, or anything else, but (tuits > permitting) hope to fig

[HACKERS] GROUPING SETS revisited

2010-08-02 Thread Joshua Tolley
In case anyone's interested, I've taken the CTE-based grouping sets patch from [1] and made it apply to 9.1, attached. I haven't yet done things like checked it for whitespace consistency, style conformity, or anything else, but (tuits permitting) hope to figure out how it works and get it closer t

[HACKERS] Grouping sets

2009-10-29 Thread Pavel Stehule
Hello I got a possibility to continue on GROUPING SETS see http://wiki.postgresql.org/wiki/Grouping_Sets My last patch was based on an sharing functionality with non recursive CTE. I would to recapitulate all options here and I would to prepare this patch for next commitfest. a) using actualised