3 ms·
Using DbUp, which is basically a library that you use to wrap SQL scripts in a console app. This gives you full control over your migrations, while still being
by GordonS 8y ago
Using DbUp, which is basically a library that you use to wrap SQL scripts in a console app.
This gives you full control over your migrations, while still being incredibly simple - it's just SQL!
For views, sprocs and functions, we don't use sequential migration scripts, instead opting for idempotent creation. This also means it's easy to see the evolution of views etc when looking in source control.
In the past I've used Entity Framework and Entity Framework Core migrations, and hated them both - I'll never be a fan of codegen, but aside from that they sometimes generated wrong code that had to manually adjusted, and you also quickly end up with hundreds of scripts.
I like DbUp very much.