开发者

Choosing data access methods in ASP.NET MVC

开发者 https://www.devze.com 2022-12-11 23:34 出处:网络
As I am a beginner to ASP.NET MVC, I would like to know what are the best data access methods f开发者_运维百科or ASP.NET MVC?This is somehow subjective. There\'s no such thing as best data access meth

As I am a beginner to ASP.NET MVC, I would like to know what are the best data access methods f开发者_运维百科or ASP.NET MVC?


This is somehow subjective. There's no such thing as best data access method for ASP.NET MVC. This will depend on your application requirements and specific needs. There are many different ORM frameworks you can choose from such as NHibernate, Entity Framework, Linq to SQL, ... (If there was a best framework this list wouldn't be so big).


As ASP.NET MVC is all about TDD and separation of concerns it is more natural to use any type of ORM for data access (NHibernate, Entity Framework, LINQ to SQL etc.). What type of ORM - depends on your project goals and experience.


If you're just learning MVC, and are ok with SQL server, then I would recommend using Linq to SQL for a start. Later you can then introduce more powerful ORM like NHibernate or EF. If you try to tackle MVC and something like NHibernate at once you will likely bite off more than you can chew.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号