This week's giveaway is in the Spring forum.
We're giving away four copies of REST with Spring (video course) and have Eugen Paraschiv on-line!
See this thread for details.
The moose likes Object Relational Mapping and the fly likes One To Many BidirectionalMapping Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of REST with Spring (video course) this week in the Spring forum!
JavaRanch » Java Forums » Databases » Object Relational Mapping
Bookmark "One To Many BidirectionalMapping" Watch "One To Many BidirectionalMapping" New topic

One To Many BidirectionalMapping

vivek dhiman
Ranch Hand

Joined: Aug 05, 2011
Posts: 149


I have an issue in the below code in bidirectional mapping. As i am new in hibernate so not exactly knows where i am wrong.
My first class file is as below:

Customer2 Mapping File

Vendor2 Mapping File

My Logic File is :

Exception that i am getting

Bill Gorder

Joined: Mar 07, 2010
Posts: 1682


You have marked this topic as resolved. Was that intentional? If not let me know and I can fix it for you. People are less likely to comment on posts that are marked as resolved.

[How To Ask Questions][Read before you PM me]
vivek dhiman
Ranch Hand

Joined: Aug 05, 2011
Posts: 149

Thanks Bill for reply. I spent some time and found the mistake that was in my vendor2 mapping file. The there was wrong field in key tag.
Now its working.
I agree. Here's the link:
subject: One To Many BidirectionalMapping
It's not a secret anymore!