Re: retrieve grouping sets/rollup rows - Mailing list pgsql-general

From Tom Lane
Subject Re: retrieve grouping sets/rollup rows
Date
Msg-id 18053.1457923495@sss.pgh.pa.us
Whole thread Raw
In response to Re: retrieve grouping sets/rollup rows  (James Keener <jim@jimkeener.com>)
Responses Re: retrieve grouping sets/rollup rows
Re: retrieve grouping sets/rollup rows
List pgsql-general
>> On 03/13/2016 10:07 PM, Tom Smith wrote:
>>> It would help if the resultset has some param to mark which is which
>>> with the grouping sets index.

I think you're looking for the GROUPING() function.  See
http://www.postgresql.org/docs/9.5/static/functions-aggregate.html

            regards, tom lane


pgsql-general by date:

Previous
From: James Keener
Date:
Subject: Re: retrieve grouping sets/rollup rows
Next
From: James Keener
Date:
Subject: Re: retrieve grouping sets/rollup rows