Ah, schema migration, not database migration.
Seeing the question I was thinking of database migration, which, quoting big G, is: Database migration is the process of migrating data from one or more source databases to one or more target databases by using a database migration service.
Maybe it is best to prefix all migrations with what is being migrated ![]()
In Zotonic each module has an optional manage_schema function, which is called whenever the module is installed or updated. As there is often some complex initialization of new columns or tables, we perform the needed updates with SQL queries (using the information_schema to check for the presence of tables/columns/indices) inside a transaction.