开发者

.NET Data Access [closed]

Closed. This question needs to be more focused. It is not currently accepting answers.

Want to improve this question? Update the question so it focuses on one problem only by editing this post.

Closed 7 years ago.

开发者_开发百科 Improve this question

What is the best way to learn data access in .net? The Entity Framework seems to be the new "it" thing, but what other options do I have?

Thanks,

Robert


Your starting point is ADO.NET, with documentation available at :http://msdn.microsoft.com/en-us/library/e80y5yhx(v=vs.80).aspx .

The two most current Microsoft libraries that are based on ADO.NET are LINQ to SQL and the Entity Framework. They are maintained by Microsoft.

NHibernate is a very commonly used and highly recommended open-source ORM and persistence framework. Documentation and resources are available from : http://nhforge.org/ .

SubSonic is a "Super High-fidelity Batman Utility Belt that works up your Data Access (using Linq in 3.0), throws in some much-needed utility functions, and generally speeds along your dev cycle". It is open source with a GitHub page at https://github.com/subsonic/SubSonic-3.0.

There are many other ORMs as well, but these are the most commonly used open source relational database solutions. Wikipedia has a pretty extensive list of .NET ORM software at http://en.wikipedia.org/wiki/List_of_object-relational_mapping_software#.NET.

ADO.NET includes the fundamental objects behind Data Access in the .NET Framework. LINQ to SQL is probably the most simple ORM to learn and use, but it will always be easier if you understand what is happening underneath. The Entity Framework is similar to LINQ to SQL but includes much more functionality and aims at a more domain-driven approach, where as LINQ to SQL is more of an Active Record pattern.


My new favorite is Massive It's a small lightweight db abstraction that uses the ExpandoObject class and SQL.

"A small, happy, data access tool that will love you forever"


Have a look at these:

http://www.nhibernate.com/

http://msdn.microsoft.com/en-us/library/Ee817654%28pandp.10%29.aspx

http://msdn.microsoft.com/en-us/library/ff632023.aspx

[]'s


I personally like Dapper.NET. It's a very lightweight ORM (mostly handles mapping types and dynamically populating classes from the DB). It's also part of Stack Overflow's dev stack.

0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜