Re: Turning column into row

From: Oliver Elphick <olly(at)lfix(dot)co(dot)uk>
To: "Tille, Andreas" <TilleA(at)rki(dot)de>
Cc: PostgreSQL SQL <pgsql-sql(at)postgresql(dot)org>
Subject: Re: Turning column into row
Date: 2002-05-22 09:56:47
Message-ID: 1022061408.1400.1042.camel@linda
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-sql

On Wed, 2002-05-22 at 08:35, Tille, Andreas wrote:
>
> So I have to turn the different properties according to one item into
> one field insead of one column.
>
> How to do this sanely?

Use Perl?

According to Joe Celko's book, SQL For Smarties, Sybase provides a
LIST() aggregate function that does this. But I don't know of anything
in PostgreSQL.

--
Oliver Elphick Oliver(dot)Elphick(at)lfix(dot)co(dot)uk
Isle of Wight http://www.lfix.co.uk/oliver
GPG: 1024D/3E1D0C1C: CA12 09E0 E8D5 8870 5839 932A 614D 4C34 3E1D 0C1C

"We are troubled on every side, yet not distressed; we
are perplexed, but not in despair; persecuted, but not
forsaken; cast down, but not destroyed; Always bearing
about in the body the dying of the Lord Jesus, that
the life also of Jesus might be made manifest in our
body." II Corinthians 4:8-10

In response to

Responses

Browse pgsql-sql by date

  From Date Subject
Next Message Tille, Andreas 2002-05-22 10:28:31 Re: Turning column into row
Previous Message Tille, Andreas 2002-05-22 07:35:57 Turning column into row