Search Postgresql Archives

Re: SQL help - multiple aggregates

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, Aug 18, 2016 at 4:56 AM, <hamann.w@xxxxxxxxxxx> wrote:
select custid, count(vendid) as c415 from cv where vendid = 415 group by custid
​[...]

Is there a better way (by creating an aggregate function, perhaps)

​You may find crosstab in the tablefuncs extension to be of use.

 https://www.postgresql.org/docs/current/static/tablefunc.html

​David J.​


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux