From: Joe Conway <mail@joeconway.com>
To: Tim Clarke <tim.clarke@minerva.info>
To: pgsql-general@lists.postgresql.org <pgsql-general@lists.postgresql.org>
Subject: Re: CROSSTAB( .. only one column has values... )
Date: Tue, 5 Jan 2021 13:45:44 -0500
Message-ID: <a0b93b67-eaf1-0d3d-1a97-37ba578e6a4b@joeconway.com> (raw)
In-Reply-To: <e3e66f2d-67c9-c4f8-d931-128c14ac4ec8@minerva.info>
References: <39d8f6180ae91806f6d6738ccb761b4b615e404c.camel@whitemice.org>
<CAKFQuwZDC4rqyRWA42EHqDjZroNagvjw+MnqPi5gL8fzQeOQzg@mail.gmail.com>
<e3e66f2d-67c9-c4f8-d931-128c14ac4ec8@minerva.info>
On 1/5/21 12:11 PM, Tim Clarke wrote:
> imho the crosstab() function isn't a good implementation. The biggest failure it
> has is that you must know exactly how many output columns you will have in the
> result /_prior to running it
*That* is a function of how Postgres set returning functions work, and not
specific to crosstab(). It is not easily fixed. Patches to fix that would be
welcomed!
Joe
--
Crunchy Data - http://crunchydata.com
PostgreSQL Support for Secure Enterprises
Consulting, Training, & Open Source Development
Attachments:
signature.asc (application/pgp-signature, 832B) download
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-general@postgresql.org
Cc: mail@joeconway.com, tim.clarke@minerva.info
Subject: Re: CROSSTAB( .. only one column has values... )
In-Reply-To: <a0b93b67-eaf1-0d3d-1a97-37ba578e6a4b@joeconway.com>
References: <39d8f6180ae91806f6d6738ccb761b4b615e404c.camel@whitemice.org> <CAKFQuwZDC4rqyRWA42EHqDjZroNagvjw+MnqPi5gL8fzQeOQzg@mail.gmail.com> <e3e66f2d-67c9-c4f8-d931-128c14ac4ec8@minerva.info> <a0b93b67-eaf1-0d3d-1a97-37ba578e6a4b@joeconway.com>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox