1
hello 我想根据我的实体edmx文件更改我的数据库结构? 我知道如何创建一个数据库:更改实体中的数据库
if(myEntity.DatabaseExists())
{
//?????
//check database if there is any change in database alter database according to edmx file.
}
else
{
myEntity.CreateDatabase();
}
为什么我要做到这一点我想安装我program.I使用实体的一个新版本,我的EDMX文件已被更改,所以我的数据库有改变吗?根据我的新edmx文件。
+1。 仅供参考:可以为EF模型生成更改脚本(更改表等)的工具是我的VS2010加载项:http://huagati.com/edmxtools/ – KristoferA 2010-12-13 10:51:21