Re: Tool to drop Columns
From: Jacob Love <jlove_at_engin.umich.edu>
Date: 1997/10/15
Message-ID: <622nh2$l6k_at_srvr1.engin.umich.edu>#1/1
Date: 1997/10/15
Message-ID: <622nh2$l6k_at_srvr1.engin.umich.edu>#1/1
[Quoted] In article <01bcd941$f6fdefb0$54110b87_at_clamagent>,
[Quoted] Dan Clamage <clamage_at_mime.dw.lucent.com> wrote:
>Why not just do
>1) CREATE new_table AS SELECT col1, col3, colN FROM old_table;
>2) DROP TABLE old_table;
>3) RENAME new_table TO old_table;
Because this doesn't take care of grants, indexes, primary and foreign keys. If you have an extraordinarily simple system which doesn't take advantage of referential integrity, the solution you propose would work.
-- ----------------------- Jack F. Love Opinions expressed are mine alone, unless you happen to agreeReceived on Wed Oct 15 1997 - 00:00:00 CEST