Re: Final Patch for GROUPING SETS - Mailing list pgsql-hackers

From Josh Berkus
Subject Re: Final Patch for GROUPING SETS
Date
Msg-id 541A258F.7070701@agliodbs.com
Whole thread Raw
In response to WIP Patch for GROUPING SETS phase 1  (Atri Sharma <atri.jiit@gmail.com>)
List pgsql-hackers
On 09/17/2014 03:02 PM, Marti Raudsepp wrote:
> So instead of:
>  GroupAggregate
>    Output: four, ten, hundred, count(*)
>    Grouping Sets: (onek.four, onek.ten, onek.hundred), (onek.four,
> onek.ten), (onek.four), ()
> 
> Perhaps print:
>    Grouping Sets: (onek.four, onek.ten, onek.hundred)
>                   (onek.four, onek.ten)
>                   (onek.four)
>                   ()

So:
 Grouping Sets: [    [ onek.four, onek.ten, onek.hundred ],    [ onek.four, onek.ten ],    [ onek.four ],    []]

.. in JSON?

Seems to me that we need a better way to display the grand total
grouping set.

> 
> Or maybe:
>    Grouping Set: (onek.four, onek.ten, onek.hundred)
>    Grouping Set: (onek.four, onek.ten)
>    Grouping Set: (onek.four)
>    Grouping Set: ()

The latter won't work with JSON and YAML output.

-- 
Josh Berkus
PostgreSQL Experts Inc.
http://pgexperts.com



pgsql-hackers by date:

Previous
From: Robert Haas
Date:
Subject: Re: Collations and Replication; Next Steps
Next
From: Robert Haas
Date:
Subject: Re: Immediate standby promotion