Hi everybody, I am using a Domain Model without a Proxy (I can't by
design) so without lazy loading.
I saw that I can use the "fetch" keyword in HQL to eager loading the
potential lazy loadable properties.
For example, in this structure:

Folder 1 -> * Files
Files * -> 1 Folder

I can write something like this when I retrieve a File, in order to
fetch its parent Folder:

                var sql = "from File f "
                    + "left join fetch f.ParentFolder p "
                    + "where w.UniqueId = :id";
Of course this works but I was wondering if there is a way to force
the mapping to fetch always a specific many-to-one.
I tried with lazy="false" and lazy="no-proxy" in the many-to-one node
but it doesn't do anything ...
Also the method NHIbernateUtil.Initialzie does not work with no proxy
mappings.
Am i wrong?

-- 
You received this message because you are subscribed to the Google Groups 
"nhusers" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/nhusers?hl=en.

Reply via email to