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

Announcements
Join us in NYC Sept 4th for Qlik's AI Reality Tour! Register Now
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Joining fields when it is a specific value

I want to join three fields together but I only want the third field to show if it is a specific value. What is the best way to do this in the script?


For example, I have three fields: Product, Location, Color. I want to combine product_value + location_value + color_value (only if it is yellow). If it is not yellow, then I only want the new field to have Product_value + Location_value.


1 Solution

Accepted Solutions
Anonymous
Not applicable
Author

You can concatenate in the load script.  See attached.

View solution in original post

3 Replies
preminqlik
Specialist II
Specialist II

if i understood

Load Product_value,Location_Value

from table1;

join

Load Product_value ,

Location_Value,

Color_value

resident table2 where Color_value='yellow';

Anonymous
Not applicable
Author

You can concatenate in the load script.  See attached.

Not applicable
Author

I still need those product and location fields so I used the below to create a new field....

if(Color='Yellow',Product & Location & Color,Product & Location) as NewField

Thank you very much for your help as it was very helpful.