I wrote a decent stand-alone I18n implementation a while back. I think you're going after the same thing I was. You're free to use it if you please.
Here is the table structure I use: Describing: I18N ---------------- ID,N,VARCHAR2,255,null,null LANG,N,VARCHAR2,255,null,null NS,N,VARCHAR2,255,null,null TEXT,Y,VARCHAR2,4000,null,null ID for the id, LANG for the W3C language code, NS for the namespace (ie MyApp/MyJSP.jsp) and TEXT for the user-customizable text. Attached is the interface code, with some samples in the Javadoc comments. Read I18n.java. Ttyl, ------------------------------- Derek C. Anderson AUREPM Project Lead https://cmscvs.maxwell.af.mil Computer Sciences Corporation [EMAIL PROTECTED] http://www.csc.com/ ------------------------------- -----Original Message----- From: Alex Hepp [mailto:[EMAIL PROTECTED] Sent: Tuesday, February 22, 2005 10:49 AM To: Apache Torque Users List Subject: Re: Multilanguage application Hi everybody, hi Kintzel. If I had enough time to develop such a solution (for there are no problems, but only solutions;) ), i would only save references to resources in db instead of real text. have a resource table with ids and optionally names. then have a language table with ids and optionally names. then have a table language_resources with resource id, language id and the real text. in the table link in the column description you only have a reference to the id of the resources table. then you can decide, whether you have a property, or let the user decide, which language to use. With the combination of language id and resource id you know the row of language_resources you have to fetch. simple criteria there. But there is one factor you have to think about. This method is pretty time intensive. You can surely also use the internationalisation service (i18n) that comes with turbine, but i didnīt try that. Good luck and have fun! kind regards Alex Hepp T E Schmitz schrieb: > Kintzel Levente wrote: > >> This is important for a multilanguage application. Example: For a >> "link" on a linkpage I have a description in more than one language >> and the url. I want to store the description in several languages in >> such a way to be easy to maintain. Some design patterns for this >> problem? How to design the tables for this problem? (schema?). > > > Recently I came across Jakarta Commons Resources > http://jakarta.apache.org/commons/resources/ > > The API provides access to JDBC Resources. I haven't had a close look > at it, so I don't really know whether it is suitable for your > application, but it might give you some ideas. > File attachment: I18N.zip The file attached to this email was removed because the file name is not allowed.
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]