title: JPA2 Criteria Query JOIN
body: <p>I have following class ( entity )</p>
  
  <pre><code>@Entity
  public class  Magazine {
      private int id ;
      private String magazine;
  
              //getters and setters
  }
  
  // tracking the magazine arrival
  @Entity 
  public class MagazineIn {
      private int id;
      private java.util.Date inDate;
      private java.util.Date magdate;
  
      @OneToOne
      private Magazine mag ; 
              //getters and setters
  
  }
  </code></pre>
  
  <p>Now i want to get all arrival status of all magazine , whether 
  magazine has in or not</p>
  
  <p>using criteria query</p>
  
  <p>following is code</p>
  
  <pre><code>    CriteriaBuilder cb = em.getCriteriaBuilder();
      CriteriaQuery&lt;Object[]&gt; cq = cb.createQuery(Object[].class);
  
          Root&lt;MagazineIn&gt; magIn = cq.from(MagazineIn.class);
      Join&lt;Magazine,MagazineIn&gt; mag =  magIn.join("mag" , JoinType.LEFT);
  
          cq.multiselect(mag.get("magazine") , magIn.get("magdate") , 
              magIn.get("inDate"));
      TypedQuery&lt;Object[]&gt; q = em.createQuery(cq);
  </code></pre>
  
  <p>But i am not getting  all the magazine listing with indate and magdate null.RIGHT JOIN is not supported. What's wrong?</p>