Skip to main content
Announcements
See what Drew Clarke has to say about the Qlik Talend Cloud launch! READ THE BLOG
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

Null Handling - String replacement in Tmap

Hello,

 

I've searched the community and I thought the correct syntax for null string replacement is as such:

 

row2.Reason_Code == null ? "NA" : row2.Reason_Code

 

However, TMAP is giving me a String to Boolean Type Mismatch for some reason.   What would be causing this?

 

 

 

 

 

 

 

 

 

 

 

 

 

Labels (2)
2 Replies
Raghuram_Puram
Contributor III
Contributor III

Check the datatype or Reason_Code in source and target schemas, there might have been a mismatch.
If datatype of Reason_Code is boolean and you're trying to assign a String value "NA" to it, error is thrown.

row2.Reason_Code == null ? true/false : row2.Reason_Code
Jaggu1992
Contributor
Contributor

Hi Raghuram,

 

Place that function in tmap in filter condition  in Target. Then you wont get datatype mismatch error. And if you keep that functuntion in Expression Editor in tmap you will get datatype mismatch error.

 

Thanks,

Jagan.