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.  [ 3 posts ] 
Author Message
 Post subject: How to control FOREING KEY way of creation?
PostPosted: Mon Jan 22, 2007 1:55 pm 
Regular
Regular

Joined: Fri Feb 18, 2005 3:34 am
Posts: 88
Location: Poland/Wrocław
Hi again,

Another question related to dialects' implementation. I have a very limited implementation of HSQLDB in C# which does not implement ALTER TABLE ADD CONSTRAINT unfortunately.

Is there a way to controll FOREIGN KEY constraint strategy? I would like to replace existing way (via ALTER TABLE) with adding constraint at the table time.

Also, the question is whether it makes sense (the lack of ADD CONSTRAINT syntax leads to lack of schema update possibility). I have a possibility of implementation supplementation (I am working with the code taken from gotDotNet).

_________________
Please rate this post if you've found it helpfull
Roland


Top
 Profile  
 
 Post subject:
PostPosted: Tue Jan 23, 2007 11:12 am 
Regular
Regular

Joined: Fri Feb 18, 2005 3:34 am
Posts: 88
Location: Poland/Wrocław
I've investigated it a little and it looks like there is the only way of table creation (among whith the constraints) - creating a table first and then altering it with adding constraints.

Maybe this is the best way from the point of view of DB engine variety - please let somebody explain it to me...

What was the exact reason of doing it this way and closing the alternative paths? Maybe it could be easily extended - I can do this, possibly...

_________________
Please rate this post if you've found it helpfull
Roland


Top
 Profile  
 
 Post subject:
PostPosted: Tue Jan 23, 2007 12:30 pm 
Contributor
Contributor

Joined: Wed May 11, 2005 4:59 pm
Posts: 1766
Location: Prague, Czech Republic
You can try looking at HSQLDialect in Hibernate and port it over to .NET.


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 3 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.