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

Announcements
Qlik Open Lakehouse is Now Generally Available! Discover the key highlights and partner resources here.
cancel
Showing results for 
Search instead for 
Did you mean: 
soowork
Contributor III
Contributor III

[resolved] tMap - update only if value is non-Null?

Is there a way, using tMap, to say that I only want to update a value in the output table if the matching input value is not NULL?
If the input value is non NULL, then I want to update the column. If the input value is NULL, I want to leave the existing value alone. This will vary from row to row.
I suspect this is quite simple, but I am struggling figuring it out. TIA.
Input
ID Value
1 cat
2 NULL
4 fish
Existing Table
1 kitten
2 snake
3 koala
4 turtle
5 dog

Result
1 cat
2 snake
3 koala
4 fish
5 dog
Labels (2)
11 Replies
Anonymous
Not applicable

Hi Dorthy,
Could you please elaborate your case with an example with input and expected output values?
Best regards
Sabrina
_AnonymousUser
Specialist III
Specialist III

Here's my scenario.
I should take the first non null value.
I'm doing a lookup, where for one column i can have more than one values. 
Say for eg: (str1,str2,str3).-> In this case the value to be considered should be str1.
       case2: (null,str2,str3) -> In this case my value should be str2.
I need to handle this situation inside tmap where i should get the first non null value for that particular column.
Regards,
Dorthy