Hi,
I've got probably a simple problem to solve, but I've been rtfm and looking for a solution, but I admit I already have a problem to express my problem in plain english... So here it goes:
I've got 2 tables : countries and countries_i18n that, among others, have these columns:
Country:
- id: PK
- iso: char[2]: [A-Z]{2} UNIQUE
Country_I18N
- id: PK
- iso: char[2]: [A-Z]{2}
- lang: char[2]: [a-z]{2}
- country: varchar
I'd like to achieve following mapping: Country having a Map with as index Country_i18N.lang and element Country_i18n.country so that the JOIN on both tables are on Country.iso <=> Country_i18n.iso and not on Country.id <=> Country_i18n.??? since I don't have it...
How should I do this? change the schema to have that last JOIN made possible?
In advance many thanks
|