On Wed, 1 Nov 2000, Richard Poole wrote:
> Long answer: create a new table with the same columns, except give the
> one you want to change its new size. Then copy all the data across
I just did it (for another reason)
To alter a table (remove, or change columns)
# Copy the data
CREATE TABLE temp AS SELECT * FROM distributors;
# Drop and recreate the table
DROP TABLE distributors;
CREATE TABLE distributors (did DECIMAL(3) DEFAULT 1,
name VARCHAR(40) NOT NULL);
# Get back the data
INSERT INTO distributors SELECT * FROM temp;
# Drop the temporary table.
DROP TABLE temp;