Filtering in tmap

Highlighted
Six Stars

Filtering in tmap

Hello All,

Im trying to filter two columns ORGANIZATION_ID and TRANSACTION_SOURCE_TYPE_ID in my job and below is the expression I used in TMAP. 

 

Not sure why but the job is not loading any records to the target table. Please correct me if im missing anything in the way I used the expression in TMAP.

2.PNG3.PNG

Thank You


Accepted Solutions
Fifteen Stars TRF
Fifteen Stars

Re: Filtering in tmap

"&&" is for "and". For "or" use "||" as ORGANIZATION_ID cannot be equals to 116, 117, ... at the same time!

The answer is

(Source1.ORGANIZATION_ID.equals("116") || Source1.ORGANIZATION_ID.equals("117") || ...) && 
Source1.TRANSACTION_SOURCE_TYPE_ID.equals("25")

TRF

All Replies
Fifteen Stars TRF
Fifteen Stars

Re: Filtering in tmap

"&&" is for "and". For "or" use "||" as ORGANIZATION_ID cannot be equals to 116, 117, ... at the same time!

The answer is

(Source1.ORGANIZATION_ID.equals("116") || Source1.ORGANIZATION_ID.equals("117") || ...) && 
Source1.TRANSACTION_SOURCE_TYPE_ID.equals("25")

TRF
Six Stars

Re: Filtering in tmap

Thank You. That worked.

What’s New for Talend Spring ’19

Watch the recorded webinar!

Watch Now

Definitive Guide to Data Quality

Create systems and workflow to manage clean data ingestion and data transformation.

Download

Tutorial

Introduction to Talend Open Studio for Data Integration.

Watch

Downloads and Trials

Test drive Talend's enterprise products.

Downloads