-->
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: Internationalization without UserType
PostPosted: Sun Jul 03, 2005 10:44 am 
Newbie

Joined: Sun Jul 03, 2005 9:45 am
Posts: 3
Hi,

I want to sore internationalized data, in a relative standard way, so that I will be able to reuse it.

So, I decided to use following "Label" table structure :
- label_id : int
- lang : varchar
- label : varchar
Primary key is a composite key (label_id, lang).

Firstly, I want to use this structure to store names of an item, here are attrbiuts of this "ite" object :
- item_id : int
- activated : string
- state : string
- names ????

I want to be able to do a "getNames" call on an "item" object and to get item names for all languages (in an Set containing Label objetcs for example ...).

I found a solution that works but it is necessary to create an intermediate table. Not really satisfying ... Il I want to reuse Label structure for other internationalized objets, I will have to create an intermediate table for each.

So, my question is :
How to declare ths relation (one-to-many) without modifying Label structure ?

Thanks a lot for your help.

Dany


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.