This week's book giveaway is in the Agile and Other Processes forum.
We're giving away four copies of The Little Book of Impediments (e-book only) and have Tom Perry on-line!
See this thread for details.
Win a copy of The Little Book of Impediments (e-book only) this week in the Agile and Other Processes forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Hibernate : Groups of Groups / IllegalArgumentException calling getter

 
Craig Taylor
Ranch Hand
Posts: 64
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I'm struggling to find out the proper way to represent the following relationship within hibernate :




I'd like to have, in effect, groups of groups and am using the MyGroupGroups table as a join table from MyGroup to tie back to the child groups.

MyGroup.hbm.xml (fragment) :


and within the childGroupGroups.hbm.xml I have the following :


When all is said and done I'm receiving a


Note : I did have to go through and manually replace the MyGroup / MyGroupGroups elements - please adjust your reading glasses accordingly as I may have misapplied some changes.
 
Craig Taylor
Ranch Hand
Posts: 64
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Banging my head repeatdly against the issue resolved the problem :

Modifying the MyGroup.hbm.xml to reflect this, made it work.

 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic