Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>In an object-oriented program relations are expressed as associations.</p> <p>That is:</p> <ul> <li>If Product has Orders then Product must have a collection of Orders.</li> <li>If an Order is for a Product, the Order must have a property Product.</li> <li>and so on.</li> </ul> <p>In object-oriented programming you don't associate by an identifier: you don't need this because this is a different world ruled by hierarchical data.</p> <p>Honestly, if you follow what I said before, NHibernate will be a very powerful tool as it'll be able of loading objects and properties without your intervention.</p> <p>Think about "getting all orders of some product": <strong>you're not going to intentionally execute an SQL Join but you're going to access to the <code>Orders</code> property of <code>Product</code> and NHibernate will translate this access to the database world</strong>.</p> <p>This is the point of using an OR/M. It's not just "I map tables <em>as is</em>". It's about joining two very different worlds: the object-oriented hierarchical world with relational data with no pain.</p> <p><strike>Check this very old (2004!) CodeProject article and how it creates the Northwind SQL Server database-based model:</p> <ul> <li><a href="http://www.codeproject.com/Articles/8773/NHibernate-in-real-world-applications" rel="nofollow">http://www.codeproject.com/Articles/8773/NHibernate-in-real-world-applications</a></li> </ul> <p>Don't pay attention to how maps the model to the database but to the model design.</strike></p> <p>Check this article, it's more modern than the other one:</p> <ul> <li><a href="http://litemedia.info/introduction-to-nhibernate" rel="nofollow">http://litemedia.info/introduction-to-nhibernate</a></li> </ul>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload