title: how to create a two column left join in jpa?
body: <p>Is there a way to make a query in jpa with a left join on two columns, like the following in plain sql?</p>
  
  <pre><code>select
      combinedin1_.SHIPMENTNUMBER ,
      shipmentin3_.INBOUNDDELIVERYITEM ,
      combinedin1_.PURCHASEORDERNUMBER,
      combinedin1_.PURCHASEORDERITEMNUMBER ,
      purchaseor2_.FACTORY 
  from
      REPORT.REPORTLINK this_
  left outer join
      REPORT.COMBINEDINFO combinedin1_
          on this_.COMBINEDINFOID=combinedin1_.COMBINEDINFOID
  left outer join
      REPORT.PURCHASEORDERINFO purchaseor2_
          on this_.PURCHASEORDERINFOID=purchaseor2_.PURCHASEORDERINFOID and purchaseor2_.DELETED='N'
  left outer join
      REPORT.SHIPMENTINFO shipmentin3_
          on this_.SHIPMENTINFOID=shipmentin3_.SHIPMENTINFOID and shipmentin3_.DELETED='N'
  </code></pre>
  
  <p>More specific this is the left join written in plain sql:</p>
  
  <pre><code>left outer join
      REPORT.SHIPMENTINFO shipmentin3_
          on this_.SHIPMENTINFOID=shipmentin3_.SHIPMENTINFOID and shipmentin3_.DELETED='N'
  </code></pre>
  
  <p>This is my reportLink entity in JPA:</p>
  
  <pre><code>@Entity
  @Table(name = "REPORTLINK")
  public class ReportLinkFull implements Serializable {
  
  private static final long serialVersionUID = -2330676941570524461L;
  
  @Id
  @GeneratedValue(strategy = GenerationType.IDENTITY)
  @Column(name = "REPORTLINKID")
  private Integer id;
  
  @ManyToOne
  @JoinColumn(name = "SALESORDERINFOID")
  private SalesOrderInfo salesOrderInfo;
  
  @ManyToOne
  @JoinColumn(name = "PURCHASEORDERINFOID")
  private PurchaseOrderInfo purchaseOrderInfo;
  
  @ManyToOne
  @JoinColumn(name = "SHIPMENTINFOID")
  private ShipmentInfo shipmentInfo;
  
  @ManyToOne
  @JoinColumn(name = "MATERIALINFOID")
  private MaterialInfo materialInfo;
  
  @ManyToOne
  @JoinColumn(name = "CUSTOMERINFOID")
  private CustomerInfo customerInfo;
  
  @ManyToOne(cascade={CascadeType.MERGE, CascadeType.PERSIST, CascadeType.REMOVE})
  @JoinColumn(name = "COMBINEDINFOID")
  private CombinedInfo combinedInfo;
  
  @Version
  private Integer version;
  </code></pre>
  
  <p>Greetings.</p>