我们正在使用的数据库先用的EntityFramework的方法。 我们已经几个客户,当我们部署新的产品版本,我们现在采用DB模式的变化手动像工具SQL比较。
We're using Database first approach with EntityFramework. We've several customers, and when we deploy new product version, we're now applying DB schema changes "manually" with tools like SQL Compare.
有没有办法如何EF迁移有助于将更改应用到客户数据库自动?
Is there a way how EF Migrations could help to apply changes to customers DB automatically?
推荐答案据我所知,EF迁移是针对CodeFirst产品,不支持数据库优先操作。
As far as I know, EF Migrations is a product targeted at CodeFirst and doesn't support Database First operations.
CodeFirst假定你将永远不会手动进行任何更改到数据库。所有对数据库的修改将通过代码先迁移。
CodeFirst assumes that you will never make any changes manually to the database. All the changes to the database will go through the code first migrations.
更多推荐
EF迁移数据库,第一种方法?
发布评论