Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Is there something like ActiveRecord::Migration for .NET?

I've played around with ruby on rails' ActiveRecord::Migration class and I like how easy it is to keep database schemas versioned. I want to do something similar in my ASP.NET project and I'm wondering if anyone has heard of a tool that does what ActiveRecord::Migration does but for .NET.

I don't see the need of defining my SQL scripts in C# or ruby code, I just want to write SQL. But is there a tool that manages SQL scripts and keeps track of what scripts you need to run to get in sync?

like image 778
kelloti Avatar asked Feb 25 '23 21:02

kelloti


2 Answers

migratordotnet is a database versioning system much like Ruby on Rail's Migrations. Its purpose is to automate your database changes, and help keep those changes in sync throughout your environments.

like image 185
k3b Avatar answered Mar 06 '23 22:03

k3b


Here's one that focuses on cross database compatibility: https://github.com/dradovic/MigSharp/wiki/Feature-Overview

Write your migration once, and let them run on different platforms.

like image 32
Dejan Avatar answered Mar 06 '23 23:03

Dejan