infoMore than 5 years have passed since last update.
dotnet ef でmigrationするとき のコマンド
Last updated at Posted at 2018-10-22
作成したmigrationの一覧
dotnet ef migrations list --context SomeContext
migrationを作成
Modelから新しいmigrationを作成
dotnet ef migrations add SomeName --context SomeContext
migrationをDBに適用
dotnet ef database update --context SomeContext
migrationを削除
削除したいmigrationを既にDBに適用した場合、以前のmigrationに戻す
dotnet ef database update PreviousMigrationName --context SomeContext
最後に作成したmigrationを削除
dotnet ef migrations remove --context SomeContext
Register as a new user and use Qiita more conveniently
- You get articles that match your needs
- You can efficiently read back useful information
- You can use dark theme
What you can do with signing up