-->
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: @CascadeType and MySQL 5 foreign key restrictions
PostPosted: Sun Jun 17, 2007 3:06 pm 
Newbie

Joined: Sun May 27, 2007 7:44 am
Posts: 5
Hello!

I am using Hibernate Annotations and the org.hibernate.tool.ant.HibernateToolTask to automatically build my mysql create script.

However, I encountered problems when putting restrictions on my foreign keys. It seems that it doesn't matter what I put as CascadeType on my @OneToOne relationship, the script generated is always the same in mysql: On Update: restrict, On Refresh: Restrict.

Is this a bug or am I doing something wrong?

//John

Hibernate version:
3.2.3.ga

Name and version of the database you are using:
MySQL 5.0 InnoDB


Top
 Profile  
 
 Post subject:
PostPosted: Wed Jun 20, 2007 9:54 am 
Newbie

Joined: Tue Jun 13, 2006 9:03 am
Posts: 18
Hi John,

I run into the same issue with Hibernate annotations and MySQL as well as Postgresql. I haven't tried any other databases yet but I think it was intended for us to set the cascades in the db manually.

-nefi


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.