保持LinqToSQL同步与数据库数据库、LinqToSQL

由网友(人走茶凉)分享简介:我要开发一个新的网站,asp.net 3.5和LinqToSQL。为了维护的目的,我怎么能修改的LINQ类,如果一个属性添加到一个数据库中的表?I am going to develop a new website with asp.net 3.5 and LinqToSQL. For maintainability...

我要开发一个新的网站,asp.net 3.5和LinqToSQL。为了维护的目的,我怎么能修改的LINQ类,如果一个属性添加到一个数据库中的表?

I am going to develop a new website with asp.net 3.5 and LinqToSQL. For maintainability purposes, how can I modify a Linq class if an attribute is added to a table in the database ?

感谢你。

推荐答案

不幸的是LinqToSQL没有在Visual Studio中的同步支持。选项​​有:

Unfortunately LinqToSQL does not have synchronization support in Visual Studio. The options are:

表中删除,并重新添加。当然,任何自定义更改将丢失 直接编辑.dbml文件文件,并添加属性。该文件包含XML内容并保存时,它会重新生成cs文件。 使用3'rd党的加载项,如: http://www.huagati.com/dbmltools/ 的http://www.perpetuumsoft.com/Product.aspx?lang=en&pid=55&tid=linqtosqlsynchronization Remove the table and add it again. Of course any customization changes are lost Edit the .dbml file file directly and add the attribute. The file has xml content and when saving it will regenerate the .cs file. Use 3'rd party addins like: http://www.huagati.com/dbmltools/ http://www.perpetuumsoft.com/Product.aspx?lang=en&pid=55&tid=linqtosqlsynchronization
阅读全文

相关推荐

最新文章