Qlik Community

App Development

Discussion board where members can learn more about Qlik Sense App Development and Usage.

cancel
Showing results for 
Search instead for 
Did you mean: 
qlikuser22
Creator II
Creator II

Mapping load and apply map

Hi

I am facing an issue in mapping load script.

MappingTableAddr:

Mapping load 

CustomerID,

Address

from abc.qvd;

MappingTableCity:

Mapping load 

CustomerID,

City

from abc.qvd;

Table11:

BillDate,

CustomerID,

Applymap('MappingTableAddr',CustomerID,'NA') as Address,

Applymap('MappingTable'City,CustomerID,'NA') as City

from abc.qvd;

 

My raw data is 

qlikuser22_0-1642512868775.png

I have null values for the bill date 1.4.21. I would like to copy the same address since the customer ID is same. I tried the above code but I still get NULL values. Any help.

 

Thanks in advance!

Labels (1)
1 Reply
micheledenardi
Specialist II
Specialist II

Since your CustomerID is numeric, try to convert it as text by using Text()in both mapping tables and fact table.

MappingTableAddr:
Mapping load 
Text(CustomerID) as CustomerID
Address
from abc.qvd;

MappingTableCity:
Mapping load 
Text(CustomerID) as CustomerID
City
from abc.qvd;

Table11:
Load
BillDate,
CustomerID,
Applymap('MappingTableAddr',text(CustomerID),'NA') as Address,
Applymap('MappingTable'City,Text(CustomerID),'NA') as City
from abc.qvd;

 

Michele De Nardi
If a post helps to resolve your issue, please accept it as a Solution.