Qlik Community

Qlik Sense App Development

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

Highlighted
andreevaa
New Contributor

How to decode Value

Hello! How i can decode Last Name from field 'Reports to' if used 'EmpID'?

data.PNG

 

4 Replies
Ezir
Contributor II

Re: How to decode Value

Hi @andreevaa,

Could you show an expected example?

Thanks

 

andreevaa
New Contributor

Re: How to decode Value

For value 4 from 'Reports To'  I show for Last Name - Callins

Re: How to decode Value

Question is not clear? What is the outcome

Before develop something, think If placed (The Right information | To the right people | At the Right time | In the Right place | With the Right context)
Ezir
Contributor II

Re: How to decode Value

Hi @andreevaa,

You can try using Mapping. See below...

 

Table:
load * inline [
EmpID, LastName, ReportsTo,
24,Crawford,19
1,Roll,4,
2,Presley,,
3,Carsson,4,
9,Brolin,4,
42,Arlig,3,
52,Ashkenaz,42,
7,Lindwall,4,
8,Shine,2,
19,Lawson,8,
23,Sandu,19,
43,Park,7,
44,Kent,7,
4,Callins,2
];

MapLastName:
Mapping Load
EmpID,
LastName
Resident Table;

Decode:
Load
EmpID,LastName,ReportsTo,
ApplyMap('MapLastName',ReportsTo,Null()) as ReportsToLastName
Resident Table;
Drop table Table;

 

Regards,

Ezir