"change_table bulk: true" by default

At the moment, change_table executes every change as a separate “alter table” statement. The option to make all changes as one “alter table” was added forever ago:

It is supported by the most popular database systems in production: MySQL and Postgres. Despite that, the default remains the same. As you need to explicitly specify “bulk: true”, the feature sees far less use, even though it is strictly better than the default.

Am I missing some reason why we should still keep it this way? If not, I suggest we switch to bulk: true by default. Moreover, I would deprecate and remove the option entirely in a major release, if it simplifies the code. I don’t see any use-cases why would anyone need to execute separate statements. But if they really want to, they can just skip change_table method and use top-level methods like add_column.

What do you think? I can help prepare a pull request.

cc @rafaelfranca

1 Like