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: 
Anonymous
Not applicable

tmap update with null value and not equals function

Hello, 

 

I would like to know if it's possible or not to update field with null value in tMap .

 

I use this :!row1.NOM.equals(row5.NOM) to compare row1(source table) and row2(target table) if I have updated values. It works if I have not null value or empty value but it doesn't work with null or empty value...

 

Can someone help me how I can figure that with tmap or explain me an other way?

 Any help would be really appreciated

 

Thank you.

 

 Version of Talend :Talend Open Studio for Data IntegrationVersion: 6.3.1

 

0683p000009LuZq.png

 

 

 

 

Labels (2)
1 Solution

Accepted Solutions
cterenzi
Specialist
Specialist

You'll have to test for null values before comparing the two values to each other (ex: row1.NOM != null) or else replace null values with empty strings. You can replace nulls using a tMap by changing the output expression for a column from row1.NOM to: row1.NOM == null ? "" : row1.NOM

View solution in original post

2 Replies
cterenzi
Specialist
Specialist

You'll have to test for null values before comparing the two values to each other (ex: row1.NOM != null) or else replace null values with empty strings. You can replace nulls using a tMap by changing the output expression for a column from row1.NOM to: row1.NOM == null ? "" : row1.NOM
Anonymous
Not applicable
Author

 Thank you cterenzi it works !!! 

I put "row1.NOM == null ? "" : row1.NOM" in a variable tmap.

0683p000009LuaF.png