EF迁移migration.exe生成脚本 [英] EF Migrations migrate.exe generate script

查看:347
本文介绍了EF迁移migration.exe生成脚本的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在使用实体框架和持续构建.到目前为止,通过使用migrate.exe和适当的参数,我可以运行迁移或一系列迁移而不会出现任何问题.

I'm playing around with Entity framework and continuous builds. So far i'm able to run a migration or series of migrations without any problem by using migrate.exe and the appropriate arguments.

但是,当我尝试使migrate.exe踢出脚本而不是执行迁移时遇到麻烦,就像我可以通过运行

However, i've hit trouble when trying to get migrate.exe to kick out a script, rather than perform the migration, in the same way as I could get by running

update-database -TargetMigration TestMigration -script

在Visual Studio的Package Manager控制台中.

from within Package Manager Console in Visual Studio.

目前有一种方法可以做到吗?

Is there currently a way to do this?

谢谢.

推荐答案

当前不支持.请对该问题投赞成票:迁移:-Migrate.exe脚本

It is currently not supported. Please add your vote to the issue: Migrations: -Script for Migrate.exe

这篇关于EF迁移migration.exe生成脚本的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆