Need help with Hibernate? Read this first:
http://www.hibernate.org/ForumMailingli ... AskForHelp
Hibernate version: 
Mapping documents:
Code between sessionFactory.openSession() and session.close():
Full stack trace of any exception that occurs:
Name and version of the database you are using:
The generated SQL (show_sql=true):
Debug level Hibernate log excerpt:
Problems with Session and transaction handling?
Read this: 
http://hibernate.org/42.html
Hi,
I'm little bit confused. So pardon me if it sounds stupid.
a) Consider two table  Order, LineItem.   Lineitem table has reference to order_id.
     
       class LineitemBO{
      }
       Class OrderBO{
           Set lineitems;
           .....
       }
b) Assume *.hbm files are written  for those tables and there is a one to many relation between order and lineitem.  The entities are marked "lazy"  and made to use outer join
c) Insert an order with 3 lineitems whose order_id=10 (say)
d) Do  OrderDAO.load(OrderId=10), which creates one OrderBO with 3 lineitems in the set as a result of association
       
e) Run the same query using HQL  
         (ie) Criteria.add(Expression.eq("orderid",10));
     The returned collection is going to have 3 orderbo objects  having the same identity.
I expected HQL result should be same as that of  session.load(...).  Am I missing something?  
regards,
Haneef