3 ms·
It seems like generating the diffs from the schema's version history is equivalent to doing it the opposite way, provided that each diff is tested to make sure
by skybrian 2y ago
It seems like generating the diffs from the schema's version history is equivalent to doing it the opposite way, provided that each diff is tested to make sure the database upgrade works. Not all diffs will correspond to feasible database upgrades, so some patches would have to be rejected.
- pounderstanding 2y agoMigrations give more control. Alter table foo add column bar; Update foo set bar=baz; Alter table foo modify column bar NOT NULL;
- skybrian 2y agoTrue. Perhaps annotating the schema would help for simple things?
- bootsmann 2y agoNot all migrations are as simple as adding and removing columns.