ASP.Net MVC: Best Practices for dbml files

前端 未结 3 1893
挽巷
挽巷 2021-01-01 00:42

This may just be a yes or no type of question but here goes anyway...

From all (well most) of the examples that I\'ve seen for using mvc, it appears that method for

3条回答
  •  失恋的感觉
    2021-01-01 00:58

    If the schema was large, I think i would be relying fully on a SQLMetal script to generate my *.dbml and backing classes. This way you can just regenerate your entire data model whenever your database gets updated. Otherwise, if a table, view, etc, gets updated in the database you don't have to delete and then re drag-and-drop that table into your visual *.dbml file.

    Actually, I am not expert with SQLMetal, but I think you can even use it it to generate everything you need for Linq-toSql and not even require/generate a *.dbml file.

提交回复
热议问题