-->
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: unique constraint
PostPosted: Thu Sep 23, 2004 12:09 pm 
Regular
Regular

Joined: Thu Sep 23, 2004 11:53 am
Posts: 83
I some what understand why we should not use comppsite_ids. Though I am having a hard time creating a composite unique index. If I use one of the default generated keys ie. hilo how do I create a comopsite unique index?

this creates the compsite index...

<property name="a" type="int" not-null="true" index="INDX"/>
<property name="b" type="int" not-null="true" index="INDX"/>
<property name="c" type="int" not-null="true" index="INDX"/>

what else do I need to do to make the index unique, please include the xml to do this. ?

Thanks for your help.


Top
 Profile  
 
 Post subject:
PostPosted: Thu Sep 23, 2004 2:00 pm 
Regular
Regular

Joined: Thu Sep 23, 2004 11:53 am
Posts: 83
I found the answer using the DTD ... use unique-key.


Thanks


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.