Re: Column ordering

From: brian <brian(at)zijn-digital(dot)com>
To: pgsql-general(at)postgresql(dot)org
Subject: Re: Column ordering
Date: 2007-09-10 17:09:53
Message-ID: 46E57A61.10308@zijn-digital.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Ashish Karalkar wrote:
> Hello All,
>
> I am having a table with 5 columns.
> I want to add another column by altering the table at 2nd position
> constraint is that I can not drop and recreate the table as column
> ordering is of importance.
> Is there anyway to do so.

Copy everything into a tmp table, drop the original, recreate it with
the new column in the correct position, and move the data back into it.

brian

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Scott Marlowe 2007-09-10 17:41:33 Re: Column Ordering
Previous Message Ron Johnson 2007-09-10 16:13:44 Re: Time Zone design issues