I have been trying to use either Liquibase or DBDeploy. I'm more drawn toward Liquibase because of its non-SQL interface (I.E. I can just use JSON or Yaml changesets). However, there is a problem I have with both of these software.
Liquibase Workflow
- I create a master changelog. All it does is to
includeAll
a folder which contains small files with small changesets inside. - I then create changesets, and prefix them with a number (E.G. a timestamp, or a simple integer like 1, 2, etc).
DBDeploy Workflow
- I just start making delta sql files, prefixed by the same strategy as number 2 above.
The problem
Well, the problem is so trivial I'm feeling stupid for asking it, but here it goes. Consider this scenario:
- I make a branch to work on my feature, say, adding orders to the system.
- My colleague, Bob, makes his own branch to add products to the system.
- When it comes time to merge, there is no telling whose changesets or delta sqls will run first. This may break the database.
Doesn't this happen to anyone? If so, what's the way to solve it in the PHP land?
Thanks.