like this?

sqlite> SELECT t1.key1, t1.key2, t2.description FROM MASTERLANGUAGES as t1,
MASTERLANGUAGES as t2 WHERE t1.ISOCode = 'DEU' and t2.ISOCode = 'ENG' and
t1.key1 = t2.key1 and t1.key2 = t2.key2;
FORM1|SAVE_BUTTON|Save
FORM1|HELP_BUTTON|Help

Sorry if my try is wrong.


2013/1/15 Kai Peters <kpet...@otaksoft.com>

> Hi all,
>
> given
>
> CREATE TABLE masterlanguages (
>   ID          integer primary key autoincrement,
>   Key1        varchar not null,
>   Key2        varchar not null,
>   ISOCode     varchar not null,
>   Description varchar not null,
>   MaxChars    integer default 0
> );
>
>
> insert into masterlanguages values (null, 'FORM1', 'SAVE_BUTTON', 'ENG',
> 'Save', 0);
> insert into masterlanguages values (null, 'FORM1', 'HELP_BUTTON', 'ENG',
> 'Help', 0);
> insert into masterlanguages values (null, 'FORM1', 'SAVE_BUTTON', 'DEU',
> 'Speichern', 0);
> insert into masterlanguages values (null, 'FORM1', 'HELP_BUTTON', 'DEU',
> 'Hilfe', 0);
>
>
>
> In addition to the data from
>
> SELECT * FROM MASTERLANGUAGES WHERE ISOCode = 'DEU'
>
> I also need the Description field for the corresponding record (based on
> Key1 + Key2) in English so
> that I can display the original English description as well as its German
> translation.
>
>
> How can I achieve this?
>
> TIA,
> Kai
> _______________________________________________
> sqlite-users mailing list
> sqlite-users@sqlite.org
> http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users
>
_______________________________________________
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Reply via email to