Hi Guys,
Given the sample data on a table:
CODE CODESET LANGUAGE NAME ORDER
----------------------------------------------------------------------------------------------
PA_KNOWN FLAG_KNOWN ENG Known 10
PA_KNOWN FLAG_KNOWN NOB Kjent 10
PA_UNKNOWN FLAG_KNOWN ENG Unknown 20
PA_UNKNOWN FLAG_KNOWN NOB Ukjent 20
PA_YES FLAG_YES_NO ENG Yes 30
PA_YES FLAG_YES_NO NOB Ja 30
PA_NO FLAG_YES_NO ENG No 40
PA_NO FLAG_YES_NO NOB Nei 40
PA_DAILY FLAG_FREQ ENG Daily 50
PA_DAILY FLAG_FREQ NOB Av og til 50
----------------------------------------------------------------------------------------------
I wanted a query that will output unique CODESET whose LANGUAGE = 'ENG' and having the smallest value for ORDER
So output will be like:
CODE CODESET LANGUAGE NAME ORDER
----------------------------------------------------------------------------------------------
PA_KNOWN FLAG_KNOWN ENG Known 10
PA_YES FLAG_YES_NO ENG Yes 30
PA_DAILY FLAG_FREQ ENG Daily 50
----------------------------------------------------------------------------------------------
Thanks in advance,
Yorge
Given the sample data on a table:
CODE CODESET LANGUAGE NAME ORDER
----------------------------------------------------------------------------------------------
PA_KNOWN FLAG_KNOWN ENG Known 10
PA_KNOWN FLAG_KNOWN NOB Kjent 10
PA_UNKNOWN FLAG_KNOWN ENG Unknown 20
PA_UNKNOWN FLAG_KNOWN NOB Ukjent 20
PA_YES FLAG_YES_NO ENG Yes 30
PA_YES FLAG_YES_NO NOB Ja 30
PA_NO FLAG_YES_NO ENG No 40
PA_NO FLAG_YES_NO NOB Nei 40
PA_DAILY FLAG_FREQ ENG Daily 50
PA_DAILY FLAG_FREQ NOB Av og til 50
----------------------------------------------------------------------------------------------
I wanted a query that will output unique CODESET whose LANGUAGE = 'ENG' and having the smallest value for ORDER
So output will be like:
CODE CODESET LANGUAGE NAME ORDER
----------------------------------------------------------------------------------------------
PA_KNOWN FLAG_KNOWN ENG Known 10
PA_YES FLAG_YES_NO ENG Yes 30
PA_DAILY FLAG_FREQ ENG Daily 50
----------------------------------------------------------------------------------------------
Thanks in advance,
Yorge