Re: [SQL] copy old column's values to new column

2004-09-02 Thread Bruno Wolff III
On Thu, Sep 02, 2004 at 06:16:47 -0700, [EMAIL PROTECTED] wrote: > Hello, > > I need some basic SQL help. I added a new column to an existing table, > and now I need to copy values from one of the old columns to this new > columns. > > I need something like this: > > FOR pvId IN SELECT id FRO

[SQL] copy old column's values to new column

2004-09-02 Thread ogjunk-pgjedan
Hello, I need some basic SQL help. I added a new column to an existing table, and now I need to copy values from one of the old columns to this new columns. I need something like this: FOR pvId IN SELECT id FROM preference_value LOOP update preference_value SET display_value = (select v