Is it possible to add a migration file using DbMigrator in code instead of through the powershell commands?
Asked
Active
Viewed 421 times
1 Answers
0
DbMigrator
is class for running migrations. Classes for creating migration are in System.Data.Entity.Migrations.Design
. ToolingFacade
is called by powershell commands. Other classes represents low level API for creating migration code.

Ladislav Mrnka
- 360,892
- 59
- 660
- 670
-
Thanks! Can you please expand on that a bit more? How would I add a migration using these files? Sorry, i'm very new to EF. – newbie_86 Sep 11 '12 at 07:28
-
1I have never tried it, I'm just pointing you to correct classes. You must find it yourselves. You can also check [EF source codes](https://entityframework.codeplex.com/SourceControl/changeset/view/2773077f0a16#src%2fEntityFramework.PowerShell%2fMigrations%2fAddMigrationCommand.cs) to get better idea how it works. – Ladislav Mrnka Sep 11 '12 at 07:58