Qlik Community

New to QlikView

Discussion board where members can get started with QlikView.

soniasweety
Contributor III

country maping

Hi all,

omar bensalem

i want to map the country values to limited. how can achieve this?

i have  region and country

region:

Americas 

AsiaPacific

EMEA

in country i have so many but my requirment is   i want to show in country list   if i select  EMEA ,Americas,AsiaPacific , only below criteria should come.

In americas - UnitedStates,Canada ,OtherAMS

in AsiaPacific-  India,China, OtherAPJ

in EMEA - Germany,UnitecdKingdom ,OtherEMEA

Tags (2)
1 Solution

Accepted Solutions

Re: country maping

Create an new Country field like this


IF(Region='Asia Pacific' and (Country='India' or Country='China' ),Country,

if(Region='Asia Pacific' and (Country<>'India' or Country<>'China' ),'OtherAPJ',

if(Region='Americas' and (Country='United States' or Country='Canada' ),Country,

if(Region='Americas' and (Country<>'United States' or Country<>'Canada' ),'OtherAMS',

if(Region='EMEA' and (Country='Germany' or Country='United Kingdom' ),Country,

if(Region='EMEA' and (Country<>'Germany' or Country<>'United Kingdom' ),'OtherEMEA',Country

))

)))) as Country_NEW,

18 Replies
YoussefBelloum
Esteemed Contributor

Re: country maping

Hi,

you can try to use a where clause on the Country field, like this

table:

load

.

.

FROM

WHERE Match(Country,'UnitedStates','Canada ','OtherAMS','India','China','OtherAPJ','Germany','UnitecdKingdom ','OtherEMEA');

soniasweety
Contributor III

Re: country maping

Not working sir.

youssef belloum

in country listbox   rest of the country's is not showing like


OtherAMS

OtherAPJ

OtherEMEA  match.PNG

soniasweety
Contributor III

Re: country maping

Hi Avinash R

Tresesco B  any idea on this?

franky_h79
Honored Contributor

Re: country maping

Maybe like attached

hope this helps

soniasweety
Contributor III

Re: country maping

is there any other way in scripting   

i dont want to use caluclated dimension    we need to use direct dimension itself

soniasweety
Contributor III

Re: country maping

cant we achieve throguh this where clause?

FROM

WHERE Match(Country,'UnitedStates','Canada ','OtherAMS','India','China','OtherAPJ','Germany','UnitecdKingdom ','OtherEMEA');

Re: country maping

Create an new Country field like this


IF(Region='Asia Pacific' and (Country='India' or Country='China' ),Country,

if(Region='Asia Pacific' and (Country<>'India' or Country<>'China' ),'OtherAPJ',

if(Region='Americas' and (Country='United States' or Country='Canada' ),Country,

if(Region='Americas' and (Country<>'United States' or Country<>'Canada' ),'OtherAMS',

if(Region='EMEA' and (Country='Germany' or Country='United Kingdom' ),Country,

if(Region='EMEA' and (Country<>'Germany' or Country<>'United Kingdom' ),'OtherEMEA',Country

))

)))) as Country_NEW,

YoussefBelloum
Esteemed Contributor

Re: country maping

so you want to limit Country values only on selections ?

soniasweety
Contributor III

Re: country maping

i want to use country in pivot table when user select region  the respected country values should show in pivot table.