Auto generated doctrine migrations don't execute in transaction
When you're applying an auto-generated doctrine migrations to your environment ex. staging or production. Remember to test it well. Because they executing sql by sql. And when last migration throws PDOException you're in serious trouble. How serious? It depends on environment :).
Before you reapply the migration you need to clean up your database bit by bit ex. removing added columns dropping indexes etc.
Conclusion.
1. Test your migration on your local development station!
2. Always Backup that DB you're migrating!
3. Again first test and later trust the generated migration!
Written by Max Małecki
Related protips
Have a fresh tip? Share with Coderwall community!
Post
Post a tip
Best
#Php
Authors
Sponsored by #native_company# — Learn More
#native_title#
#native_desc#