Hacker News new | ask | show | jobs
by chrisacky 2218 days ago
Can you explain why the ALTER approach isn't feasible? If you are locking anyway, is it not the same thing?
1 comments

My mistake, I didn't check before posting.

The use case was: Keep the table online and don't bring down the Galera cluster (which happened when running an ALTER on a table with millions of rows).

We went for pt-online-schema-change (from Percona) which copies, alters the new table, keeps them in sync, and then replaces it. All automated which is pretty sweet.

One of the answers on here has more info:

https://stackoverflow.com/questions/463677/alter-table-witho...