Re: Changing column width of full table?

From: Michael Nolan <nolan_at_helios.unl.edu>
Date: 1995/06/16
Message-ID: <3rqhni$890_at_crcnis3.unl.edu>#1/1


syam_at_axionet.com (Steve Yam) writes:

>However, if you're talking about decreasing the column size, you will be
>in the trouble water. You need to export it out, freeze all related
>operation, drop the table, recreate the table with new size, import the
>data back!!!

There may be another option. You can transfer the data from the column to be redefined to another table, along with the primary key so you can restore it later, then set the entire column to NULL, at which point you can decrease the size of the column, then reload the data from the copy of the column you saved. Not exactly fun for 2,000,000 rows, though, and if you don't have a primary key you're out of luck. (I suppose you could do it by saving the ROWID, but I've never tried that.)

---
Michael Nolan, Sysop for the DBMS RoundTable on GEnie
nolan_at_tssi.com, dbms_at_genie.com, nolan_at_inetnebr.com
(posted from nolan_at_helios.unl.edu)


>Good luck,
>Steve Yam.
Received on Fri Jun 16 1995 - 00:00:00 CEST

Original text of this message