My favorites | Sign in
Project Home Source
Project Information
Members
Links

Working with NHibernate, even after reading all the documentation, is still too doubtfull, there are too many things you need to discover in trenches.

With this project, we aim to skip this very high learning curve and give you for as much as possible "special" cases NHibernate handles, a test which will show you the mapping, the sql generated, the sql executed...so BEFORE, IN THE MIDDLE, AND AFTER effects of NH functionalities!


Example:

  • You create a many-to-many relationship, create new instances of entities, add both entities to both sides (Product to Customer, you add a Product to Customer, and that same Customer to Product). One would expect on save that three inserts in db will happen:
    • one to Products
    • one to Customers
    • and one to ProductsToCustomers

Well they don't, only two happen...one to Customers, one to Products.
SOLUTION: Wrap that save in a transaction...on save, the two inserts will happen, on commit the third one to joint table will happen.




There are allot of cases like these, where you might be surprised how NH works...We want to cover as much of them as possible to provide visibility and give a little bit less gray hairs :)

Powered by Google Project Hosting