Skip to main content
Announcements
Have questions about Qlik Connect? Join us live on April 10th, at 11 AM ET: SIGN UP NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
venkatqlik_411
Contributor
Contributor

Reuse field data using Subroutines

Hi,

Please guide me on below issue.

 

Firsttable:

Load *,

If(Country='India' and Region='South','First',

 If(Country='Singapore' and Region='South','Second',

----------------------------------------)) as Newfield

from [lib://Qlikdev/data/facts/-----.qvd](qvd);

From the above table 

I want to reuse "Newfield" data where ever I want using subroutines.

 

1 Reply
edwin
Master II
Master II

did you mean a way to lookup Newfield?  you can either do a left join with a list of Country, Region, and Newfield

or do an applymap (you just need to concat Country and Region:
https://help.qlik.com/en-US/sense/May2021/Subsystems/Hub/Content/Sense_Hub/Scripting/MappingFunction...