-->
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: Collections with MySQL MyIsam
PostPosted: Tue Dec 09, 2003 11:39 am 
Newbie

Joined: Tue Dec 09, 2003 11:30 am
Posts: 1
Hi there,

I am using hibernate 2.1 in a webapp running in Tomcat and MySQL 4.0.14 (MyISAM) for persistent storage. My questions is, I used SchemaExport to generate all relational schemas - without any errors. However, the ForeignKey constraints added by hibernate seem to be ignored by the DBMS. No cascade options work for me :(

I would very much like to use Collections of Objects (BusinessObjects) and cascade any save but can't seem to get it to work. Any ideas? Is this something to do with me using the MyISAM storage engine of MySQL?

THX, Jan

_________________
try some dark chocolat ;)


Top
 Profile  
 
 Post subject:
PostPosted: Tue Dec 09, 2003 11:44 am 
Hibernate Team
Hibernate Team

Joined: Mon Aug 25, 2003 9:11 pm
Posts: 4592
Location: Switzerland
MySQL supports proper foreign key constraints only with INNODB tables and some other restrictions also apply:

http://www.mysql.com/doc/en/InnoDB_foreign_key_constraints.html

The "cascade" option in Hibernate is something different. You need it to cascade operations from one entity to other entities. Read the "Parent/Child Relationship" chapter in the documentation and start reading here:

http://www.hibernate.org/ForumMailinglists/HowToAskForHelp

_________________
JAVA PERSISTENCE WITH HIBERNATE
http://jpwh.org
Get the book, training, and consulting for your Hibernate team.


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.