How to check in tmap NULL and NOTNULL value in IF Conditional.

Highlighted
One Star

How to check in tmap NULL and NOTNULL value in IF Conditional.

Hi
I have been reading through some posts, but not sure I am understanding.
I have an input tables with values. I need to do the following Conditional in tmap.
All the columns are string value.
IF ISNULL(ROW1.JURISDICTION1) THEN
INPUT.XMLTAG1
ELSEIF ISNOTNULL(ROW1.JURISDICTION1) and ISNULL(ROW2.JURISDICTION2) THEN
INPUT.XMLTAG2
ELSEIF ISNOTNULL(ROW1.JURISDICTION1) and ISNOTNULL(ROW2.JURISDICTION2) THEN
INPUT.XMLTAG3
END IF;
Could you please help me this..
Thanks
Rajesh G
One Star

Re: How to check in tmap NULL and NOTNULL value in IF Conditional.

Hi Rajesh
Try this.
ROW1.JURISDICTION1==null? INPUT.XMLTAG1Smiley Sad(ROW1.JURISDICTION1!=null)&&(ROW2.JURISDICTION2==null)?INPUT.XMLTAG2Smiley Sad(ROW1.JURISDICTION1!=null)&&(ROW2.JURISDICTION2!=null)?INPUT.XMLTAG3:""))
Regards,
Pedro
One Star

Re: How to check in tmap NULL and NOTNULL value in IF Conditional.

Hi,
This solution works??
Thanks!
One Star

Re: How to check in tmap NULL and NOTNULL value in IF Conditional.

Hi,
This solution works?
I have the same problem.... but this not resolve....
Thanks,
Cláudia
Hi Rajesh
Try this.
ROW1.JURISDICTION1==null? INPUT.XMLTAG1Smiley Sad(ROW1.JURISDICTION1!=null)&&(ROW2.JURISDICTION2==null)?INPUT.XMLTAG2Smiley Sad(ROW1.JURISDICTION1!=null)&&(ROW2.JURISDICTION2!=null)?INPUT.XMLTAG3:""))
Regards,
Pedro
One Star

Re: How to check in tmap NULL and NOTNULL value in IF Conditional.

Use Talend relational functions

15TH OCTOBER, COUNTY HALL, LONDON

Join us at the Community Lounge.

Register Now

2019 GARNER MAGIC QUADRANT FOR DATA INTEGRATION TOOL

Talend named a Leader.

Get your copy

OPEN STUDIO FOR DATA INTEGRATION

Kickstart your first data integration and ETL projects.

Download now

What’s New for Talend Summer ’19

Watch the recorded webinar!

Watch Now

Best Practices for Using Context Variables with Talend – Part 4

Pick up some tips and tricks with Context Variables

Blog

How Media Organizations Achieved Success with Data Integration

Learn how media organizations have achieved success with Data Integration

Read

Why Companies Move to the Cloud: 7 Success Stories

Learn how and why companies are moving to the Cloud

Read Now