Now that Oracle supports EF officially (at least in Beta), EF looks like a reasonable choice to work with Oracle database. In the other hand, NHibernate seems very suited for the same job.
Does anyone has experience with both? Any recommendation for someone who wants to get started? Which one seem to make most sense on the long run?
EF is still a new born in regards of object persistance. It uses an underlying object inheritance which some times could make you lose your inheritance possibility while designing. This could have been fixed with the new version of EF, and still, it lacks the flexibility of NHibernate.
NHibernate is a port to .NET of Hibernate in JAVA. It is likely about the same maturity now, if I remember correctly from version 3.0 of NHibernate. It uses either Attribute mapping, XML mapping or you may also use Fluent NHibernate or ConfORM, which allow you to map your objects in an object-oriented and optionally convention-based manner.
Though EF4 seems to deliver more performance in some ways, my preference resides still with using NHibernate, as it has proved better flexibility with foreign database engines other than SQL Server, IMHO.
Please, see for yourself:
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With