Re: retrieve grouping sets/rollup rows

From: Tom Smith <tomsmith1989sk(at)gmail(dot)com>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: James Keener <jim(at)jimkeener(dot)com>, PostgreSQL General <pgsql-general(at)postgresql(dot)org>
Subject: Re: retrieve grouping sets/rollup rows
Date: 2016-03-14 03:13:06
Message-ID: CAKwSVFFfaJKA4O1Wi+3j7iAsd30ixzPBnaJeh04PNpuwSFZxBw@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

exactly what I am looking for. very nice. Thx

On Sun, Mar 13, 2016 at 10:44 PM, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> wrote:

> >> 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
>

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Dmitry Dolgov 2016-03-14 07:31:36 Re: MongoDB 3.2 beating Postgres 9.5.1?
Previous Message James Keener 2016-03-14 03:04:03 Re: retrieve grouping sets/rollup rows