From: | Jason Tan Boon Teck <tanboonteck(at)gmail(dot)com> |
---|---|
To: | pgsql-novice(at)postgresql(dot)org |
Subject: | Transform table data |
Date: | 2009-05-15 08:43:48 |
Message-ID: | dd8f6c970905150143l6c1114f2jf210810060537948@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-novice |
I have a table A of data:
[id][parameter][value]
-----------------------------
[01][aa][20]
[02][bb][21]
[03][cc][22]
[04][aa][23]
[05][bb][24]
[06][cc][25]
[07][aa][26]
[08][bb][27]
[09][cc][28]
that i would like to convert into the following table B:
[key][aa][bb][cc]
---------------------
[001][20][21][22]
[002][23][24][25]
[003][26][27][28]
I program in PHP5, and would use arrays to transform it. But, I
believe that if table A is large, I am going to run out of working
memory or having a server timed out, before I can finish the task. Can
I make postgresql perform this task instead?
I am not sure where to find any reference to do this in postgresql.
Thanks in advance.
--
Jason Tan Boon Teck
From | Date | Subject | |
---|---|---|---|
Next Message | A. Kretschmer | 2009-05-15 09:31:49 | Re: Transform table data |
Previous Message | Ognjen Blagojevic | 2009-05-14 19:29:20 | Re: INSERTING "NEW LINES" IN A SELECT STATEMENT |