Hi, I am hoping to get some advice on a problem I have.
I have a table that have 109 million records and is about 30 G in size. I need to rename a column, because it seem that localtime have become a reserved word. The alter table statement makes mysql generate a tmp table and regenerate the index. And with a 30G data file and a 20G index file this takes some time. I have tried the following: 1. first I did a ALTER TABLE xxx CHANGE...... 2. next I copied the #sql-zxzxxcxcssd.frm file 3. then I killed the ALTER TABLE command 4. In the end I stopped mysqld and switched the old .frm file with the new (from 2.) And it seem to work. My question is if any body now / can think of any reason not to change the column name this way. Waiting for the index to rebuild takes at least a week, and I don't want to wait. I have only changed the column name, not the type. And the column is not part of any index. Hope to hear from you! Best regards, Gunnar