Win a copy of The Way of the Web Tester: A Beginner's Guide to Automating Tests this week in the Testing forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Join Table many-to-one issue

Harry Dhina
Posts: 6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I posted this on the hibernate forum, but no help. Sorry for the repost.

I have 3 tables:

My main table is PTNT_DATA_MSRMNT_CLCTN & join table is PTNT_PRCTC_PRFMNC_YR. I want to join these 2 tables by a non-primary key in the main table (PTNT_PRCTC_PRFMNC_YR_ID), but this does not work.

Hibernate Mapping:

The Hibernate generated SQL is:


But It should rather be

Hibernate version :

Can you guys help me on this. Hope my question is clear & understandable
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic