I personally like to make my migrations look as any other database related handler. For example if I use a query builder tools for my repositories, I will use the same style for my migrations. I also usually don't make down version of each migration. When something goes wrong I just add a fixing up migration. To reduce possibility of a situation when something goes wrong I create tests for my migrations. I rise a fresh db with random name. Roll up all migrations. Run some repo related logic if necessary. Then drop it. Go native testing framework provides a really convenient toolset to make all these operations to run without any manual actions.
Thanks for the grate video Mario, I had some idea of how migrations work but after this video I'm confident in what they are and how simple it should be to manage them. Excellent video
writing your own migration tool is probably the best option for people using database libraries that do not implement the standard interface and want to run the every time they run the app.
I personally like to make my migrations look as any other database related handler. For example if I use a query builder tools for my repositories, I will use the same style for my migrations.
I also usually don't make down version of each migration. When something goes wrong I just add a fixing up migration.
To reduce possibility of a situation when something goes wrong I create tests for my migrations. I rise a fresh db with random name. Roll up all migrations. Run some repo related logic if necessary. Then drop it. Go native testing framework provides a really convenient toolset to make all these operations to run without any manual actions.
Thanks for the grate video Mario, I had some idea of how migrations work but after this video I'm confident in what they are and how simple it should be to manage them. Excellent video
Thanks Simon! I'm glad you found the video useful. Cheers!
hope your subscribers reach 1000 soon! I have subscribed!
Thanks for the support! Take care
writing your own migration tool is probably the best option for people using database libraries that do not implement the standard interface and want to run the every time they run the app.
Very helpful. Thanks!
Thanks Tom, cheers!
No veo como relacionar dos tablas