-->
These old forums are deprecated now and set to read-only. We are waiting for you on our new forums!
More modern, Discourse-based and with GitHub/Google/Twitter authentication built-in.

All times are UTC - 5 hours [ DST ]



Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 2 posts ] 
Author Message
 Post subject: Deleting assignments in Many-to-Many mappings
PostPosted: Thu Jul 27, 2006 11:53 am 
Newbie

Joined: Thu Jul 27, 2006 10:26 am
Posts: 4
As the subject suggests I have problem with deleting the records in many to many relationship.

I have referred the link in forum and is quiet helpful
http://forum.hibernate.org/viewtopic.ph ... manytomany


I have a many to many relationship between the Employee and Project.

As per the link mentioned above everthing works fine when I delete Employee where i have mentioned cascade="save-update". and Project records left alone where i have mentioned inverse="true" But I also want the same functionality from Project side. I mean when I delete Project record, it should just delete the links and the Project Record and leave the employee records alone.

Logically, I tried to put cascade=" save-update" at project side as well but it is of no help. I am getting same exception " constraint violation"

I know the solution of this problem must be easy and I must have overlooked but your help would be great.

I am also wondering that at first place is it possible. My comman sense and the defination of bi-derectional relationship says "yes" but I may be wrong.

Guys and Gals, Look forward to your replies
Your help is much appreciated.

Rahul


Top
 Profile  
 
 Post subject:
PostPosted: Thu Jul 27, 2006 2:13 pm 
Newbie

Joined: Thu Jul 27, 2006 10:26 am
Posts: 4
http://forum.hibernate.org/viewtopic.ph ... manytomany
http://forum.hibernate.org/viewtopic.ph ... manytomany


these two links i found in the forum...
and I also found out that I have to do it in a clumsy way..
If you know any other efficient solution...please let me know

it would be great ..


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 2 posts ] 

All times are UTC - 5 hours [ DST ]


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
© Copyright 2014, Red Hat Inc. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc.