Last post Sep 05, 2007 04:15 AM by ducquan
Sep 03, 2007 12:03 PM|ducquan|LINK
I really need your helps. I am familar with J2EE. But now I want to learn about .Net. I have a question about Object persistence in C# and ASP,NET.
As you know that in order to access database, we often use ADO.NET. But it provide low-level data access API. Is there any way to acess data using object persistence (Similar to JPA or Entity Bean or Hibernate in J2EE) if we do not use NHibernate? Is there
any thing similar to JPA and EJB in J2EE?
Object Persistence in .Net
Sep 03, 2007 04:35 PM|gunteman|LINK
Well, NHibernate is the most widespread implementation, but there are plenty of alternatives, most of them open source.
Search for ORM at http://www.codeplex.com
Linq to SQL
Sep 04, 2007 05:40 AM|ducquan|LINK
Thanks for your helps.
I have quickly read through LINQ to SQL and Entity Framework. I will try it now. But I have more questions.
+ Which is the best solution (according to you) for this issue among plenty of alternatives if we DO NOT want to work with configuration file? (I have to do a lot with configuration file if I use NHibernate, Entity Framework. It is easy to make mistakes
with configuration file. And it is difficult to detect the errors coming from configuration file. This is due to the fact that I do not have much experiecne.) I want do all of things using C# code so that the compiler can help me to detect my mistakes (Configuration
file is in form of xml so that if it is well-formed, it is hard to detect the errors).
I am happy to recieve all your helps.
Sep 04, 2007 05:37 PM|gunteman|LINK
Quite a few of the existing frameworks lets you set up the mappings by using class and property attributes, instead of using XML files. Even NHibernate has this.
Sep 05, 2007 04:15 AM|ducquan|LINK
I have try it and it work very well
Thank you very much