[jboss-user] [JBoss Seam] - Re: deleted entity passed to persist

blackers do-not-reply at jboss.com
Wed Aug 8 20:36:26 EDT 2007


I am assuming you have a @ManyToOne realationship in the Entity you are trying to delete.  On the @OneToMany side you most likely have




  | @OneToMany(cascade = CascadeType.ALL, .....)
  | 

If you change to 

@OneToMany(cascade = {CascadeType.MERGE,CascadeType.REMOVE}, ....)

It may solve your problem, at least it did for me.  You will have to work out if this will affect your application before doing so.

View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4072260#4072260

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4072260



More information about the jboss-user mailing list