2

I have a MySQL table with 4 columns. The 1st column record_id is of type int, primary key, and auto-incremented. Now that I have added more than 2 billion records to this table I am finding that I have exceeded the range of my auto-incremented field. I need to modify record_id to a "bigint" to accommodate more records. What would be the fastest way to do this?

Is there a way to do this in-situ without dumping the tables?

1

Take a look here at Percona's online schema change tool (anything from Percona is good - I'd advise you to look at all of the tools while you're at it). You could also try Shlomo Noach's online table change tool - test with both and see which one works for you (again, look at his entire toolkit).

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.