Fail the job when no rows returned

Five Stars

Fail the job when no rows returned

Hi,

I'm new to Talend.

I'm looking to create job where it exits (or fails with return code 1) when no rows are returned and succeeds if there's data in source table.

I tried a couple of approaches but they're not working. appreciate if someone can help me.

 

 

 

Community Manager

Re: Fail the job when no rows returned

Hi

You can use a tDie to die the job and customize the error message and error code. eg;

tMysqlInput--main--tJavaRow

   -runIf--tDie

Set the condition of runIf as:

((Integer)globalMap.get("tMysqlInput_1_NB_LINE"))==0

 

Regards

Shong

 

----------------------------------------------------------
Talend | Data Agility for Modern Business

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