java - How to handle internationalization of names in Hiberante and db schema -
i saw few questions in stackoverflow, refer old answers (from 2004) , using hibernate xml mappings.
i writing api in java, return products stored in database based on algorithm.
the api locale , decide return name in locale language.
product table:
product_id name price how should support internalization? should add name_en name_fr etc columns?
or should create different tables?
how should return name in required locale in hibernate?
i using annotations o/r mapping
i suggest adding column "lang" contains prefix of language (ex. en, fr, ro, etc.) , column "name" contains name in languages separated separator "," , parse string.
Comments
Post a Comment