-->
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.  [ 1 post ] 
Author Message
 Post subject: persisting LinkedHashMap
PostPosted: Thu Nov 01, 2007 7:36 am 
Newbie

Joined: Wed Mar 22, 2006 5:43 am
Posts: 15
Location: Belgium
a LinkedList's order can be persisted by using something like <list-index column="sortOrder"/>

now i am looking for a way to keep the order in a LinkedHashMap

i have this code now:

Code:
        <map name="quoteItems" table="priceQuote_priceQuoteItem" cascade="save-update">
         <key column="priceQuote"/>
         <index column="kkey" type="string"/>
         <many-to-many column="priceQuoteItem" class="myPackage.PriceQuoteItem"/>
      </map>


i have found i can set a order-by attribute to the map that does a SQL ordering.

but the trouble is that when saving that map, the column with the order isn't populated ... is there a way to to do this automatically ?


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 1 post ] 

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.