facebook

HQL outer join multilple table with no relationship

  1. MyEclipse IDE
  2.  > 
  3. Off Topic
Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #310205 Reply

    kvphan
    Participant

    How do you do something like this in HQL with no relationship between each table? I don’t want to use RAW Query. I want to achieve this by using HQL or Criteria.

    Query below work in Oracle
    select t.*
    from Outsource_Invoice_Data t,
    Rms_Mexico_Invoice_Filters t2,
    Rms_Mexico_Invoice_Filters t3
    where t.bt_Code = t2.filter_Code(+)
    and t2.filter_Code is null
    and to_char(t.gp_Num) = t3.filter_Code(+)
    and t3.filter_code is null
    order by t.customer_Id

    #310221

    support-joy
    Member
    #310224

    kvphan
    Participant

    support-joy,
    your link result in an inner join. I need a left outer join and I don’t think hibernate is capable of doing that if the two table have no relationship.

    #310250

    support-joy
    Member

    kvphan,

    In your initial query, you haven’t mentioned anything regarding left outer join. I am not sure on how to perform left outer join on 2 tables having no relationship. Can you cross-post on hibernate forums – https://forum.hibernate.org/

Viewing 4 posts - 1 through 4 (of 4 total)
Reply To: HQL outer join multilple table with no relationship

You must be logged in to post in the forum log in