Abort this job when a length of a column exceeds/subceeds the specified length

Four Stars

Abort this job when a length of a column exceeds/subceeds the specified length

Hi

 

I am creating a job, where the Input is a File with 2 columns

Column1: String (5)

Column2 : String (2)

 

I have some transformation function to be applied on these columns & load into a Output file:

Column1: String (3)

Column2: String (1)

 

How to abort this job when a length of a column exceeds/subceeds the specified length of a input compoment without having to use the Length function & check the length.

 

tFileInputDelimited --> tMap --> tFileOutputDelimited

Forteen Stars

Re: Abort this job when a length of a column exceeds/subceeds the specified length

you can check the length of column in tmap itself, and take two output.

1) check the length of the column to the expected value then populate to output delimitted.

2) check the lenght of the column is less than then populate to tDie.

Manohar B
Don't forget to give kudos/accept the solution when a replay is helpful.
Four Stars

Re: Abort this job when a length of a column exceeds/subceeds the specified length

Thanks, I am aware of this method. But I wanted to know if there is any other method without checking the length & aborting the job, like a option enabled in either tMap or tFileOutputDelimited component in restricting records if it doesnt fall in the appropriate length by aborting the job automatically.

2019 GARTNER 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

Best Practices for Using Context Variables with Talend – Part 2

Part 2 of a series on Context Variables

Blog

Best Practices for Using Context Variables with Talend – Part 1

Learn how to do cool things with Context Variables

Blog

Migrate Data from one Database to another with one Job using the Dynamic Schema

Find out how to migrate from one database to another using the Dynamic schema

Blog