Im building a localized application. All data needs to be available in 
different languages. As a storage model I try to use Nhibernate because of 
the better performance over Entity Framework. I store a root node in the 
database to get a unique Id for an entity and then I have a second table 
with the child nodes per language (the locale table).

My database table looks like:

Country
   Int Id;Country_Locale
   Int Id;
   Int CountryId;
   String LangCode;
   String Name;
City
   Int Id;
   Int CountryId;City_Locale
   Int Id;
   Int CityId;
   String LangCode;
   String Name;

My prefered Entities would look like

Country
  Int Id (from Coutry table)
  String LangCode (from locale table)
  String Name (from locale table)
  IList<City> Cities (Referenced to City entity)City
  Int Id (From City table)
  String LangCode (from locale table)
  String Name (from locale table)
  Country Country (Referenced to Country entity)
  Int CountryId (From country table)

I realize that I cannot map the above, but it is a sort of the structure I 
would prefer. How could I do this mapping or are there other suggestions.

-- 
You received this message because you are subscribed to the Google Groups 
"nhusers" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/nhusers?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to