Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Qlik Open Lakehouse is Now Generally Available! Discover the key highlights and partner resources here.
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

convert Country name to Country code

Ver: 5.1.1
Level : New
hi,
I have a input Access table with field "Land" containing country name. eg.
----------------
Land
----------------
France
Germany
United Kingdom
..
..
..
..
---------------
Now I would like to convert this to two letter international code in the new SQL database. So
---------------
France --> FR
Germany --> DE
United Kingdom --> UK
..
..
.. and so on.
---------------
I have the complete list for all countries.
I see that I can do it in tMap express builder. But its a over kill to write conditional statement like if = val:then:else for all countries.

Can any body suggest best way to handle this situation ?
Labels (2)
1 Reply
Anonymous
Not applicable
Author

Hi
You'd better create a referrence table which contains two columns.
One is the entire country name(e.g. United Kingdom). The other is abbreviation (e.g. UK).
Then do inner join in tMap with the access table and this referrence table.
Regards,
Pedro