From: | "Nick Fankhauser" <nickf(at)ontko(dot)com> |
---|---|
To: | "Jodi Kanter" <jkanter(at)virginia(dot)edu>, "Postgres Admin List" <pgsql-admin(at)postgresql(dot)org> |
Subject: | Re: drop column? |
Date: | 2002-01-23 20:25:59 |
Message-ID: | NEBBLAAHGLEEPCGOBHDGKEOEEDAA.nickf@ontko.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-admin |
>Can I remove this column or will I need to drop the entire table and
restore from backup?
There's not a "remove column" option for alter table, but you may be able to
get around restoring by renaming the existing table, creating a replacement
the way you want it to look, & then copy from the old to new using "insert
into table newtable (col1,col2) values (select col1,col2 from oldtable);"
-Nick
--------------------------------------------------------------------------
Nick Fankhauser nickf(at)ontko(dot)com Phone 1.765.935.4283 Fax 1.765.962.9788
Ray Ontko & Co. Software Consulting Services http://www.ontko.com/
From | Date | Subject | |
---|---|---|---|
Next Message | Phill Kenoyer | 2002-01-23 20:29:05 | Re: drop column? |
Previous Message | Jodi Kanter | 2002-01-23 19:54:43 | drop column? |