how to Use tSystem ??

Six Stars

how to Use tSystem ??

How to use tSystem (Cmd) function , how to get the return output value and match based on the condition,

 

Flow:

 

tSystem (Command: df /dev/sda1)  ----  tlogRow ( log returns :

Filesystem 1K-blocks Used Available Use% Mounted on
/dev/sda1 476575768 103320956 349023132 23% )

 

Then if percentage get more that 75 % we need to get some message .

 

 


Accepted Solutions
Fifteen Stars TRF
Fifteen Stars

Re: how to Use tSystem ??

Hi,

You may redirect the output to a file then read read it as a standard text file.

You may also choose the option to set "Standard Output" to "to Global variable" then retrieve the value from the global variable.

In this case, you should use an awk command to extract the % value from the df result then return only this value to the Talend job.

This link may also helps.


TRF

All Replies
Fifteen Stars TRF
Fifteen Stars

Re: how to Use tSystem ??

Hi,

You may redirect the output to a file then read read it as a standard text file.

You may also choose the option to set "Standard Output" to "to Global variable" then retrieve the value from the global variable.

In this case, you should use an awk command to extract the % value from the df result then return only this value to the Talend job.

This link may also helps.


TRF

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

6 Ways to Start Utilizing Machine Learning with Amazon We Services and Talend

Look at6 ways to start utilizing Machine Learning with Amazon We Services and Talend

Blog