-->
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: Index sequence for EmbeddedID
PostPosted: Mon Feb 04, 2013 7:47 am 
Newbie

Joined: Mon Feb 04, 2013 7:38 am
Posts: 2
Hello~
As Hibernate will automatically create index for the primary keys in the table, as well as the primary key type of EmbeddedID, I would need your advice on how to specify the sequence of column in the index. Currently it seems it auto created in alphabetic order.

Code:
Index Name      Table_name   Column_name   Column_pos   Descend
--------------   ------------   -----------   ----------   ------------
SYS_C00209013   HOSTTRAFFIC   BACKBONEID   1      ASC
SYS_C00209013   HOSTTRAFFIC   HOSTID      2      ASC
SYS_C00209013   HOSTTRAFFIC   TIMESTAMP   3      ASC


How could I make it like this

Code:
Index Name    Table_name   Column_name   Column_pos   Descend
--------------   ------------   -----------   ----------   ------------
SYS_C00209013   HOSTTRAFFIC   TIMESTAMP   1      ASC
SYS_C00209013   HOSTTRAFFIC   HOSTID      2      ASC
SYS_C00209013   HOSTTRAFFIC   BACKBONEID   3      ASC



Thank you


Top
 Profile  
 
 Post subject: Re: Index sequence for EmbeddedID
PostPosted: Wed Feb 06, 2013 3:57 am 
Newbie

Joined: Mon Feb 04, 2013 7:38 am
Posts: 2
sorry to bump to the thread, but if anyone has any idea regarding composite key's indexing?
I have been googling for few days but still has no clue on it.


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:
cron
© Copyright 2014, Red Hat Inc. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc.