title: Hibernate - join un related objects
body: <p>I have a requirement, wherein I have to join two unrelated objects using Hibernate HQL.
  Here is the sample POJO class</p>
  
  <pre><code>class Product{
  int product_id;        
  String name;
  String description;
  }
  </code></pre>
  
  <p>and</p>
  
  <pre><code>Class Item{
  int item_id;
  String name;
  String description;
  int quantity;
  int product_id; //Note that there is no composed product object.
  }
  </code></pre>
  
  <p>Now I want to perform a query like
  select * from Product p left outer join Item i on p.product_id = i.item_id</p>
  
  <p>I want a multidimensional array as an output of this query so that I can have separate instances of Product and Item, instead of one composed in another.
  Is there any way to do this in Hibernate?</p>