-->
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: specifying the order of columns in an index in the mapping
PostPosted: Mon Sep 19, 2005 6:01 am 
Newbie

Joined: Mon Sep 19, 2005 4:30 am
Posts: 11
I know how to specify indexes (indices) on the column entries of my hibernate mapping.
I know how to let a single column take part in two different indexes.

What I don't know is how to specify the order of the columns in the index (which seems to be a common requirement to me).

In other words:
is it possible - in the following example - to let
FirstIndex be an Index on (name1, name2) and
SecondIndex be an Index on (name2, name1)?

Code:
<poperty name="name1" type="something.Class">
    <column name="NAME1" index="FirstIndex,SecondIndex"/>
</property>
<poperty name="name2" type="something.Class">
    <column name="NAME2" index="FirstIndex,SecondIndex"/>
</property>


Thanks for your Help

lnz


Top
 Profile  
 
 Post subject: create indexes from script
PostPosted: Tue Sep 20, 2005 11:42 am 
Expert
Expert

Joined: Fri Jul 22, 2005 2:42 pm
Posts: 670
Location: Seattle, WA
Why do not you generate database from a script and create those indexes as you need them to be?

_________________
--------------
Konstantin

SourceLabs - dependable OpenSource systems


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.