Parameterizing a tOracleInput component using Talend

0 votes

I am working on a Job in which I have a tOracleInput and a tFileOutputDelimited component. I want to filter the incoming data which I think can be done using a “WHERE” clause but my problem is I also have to pass the filtered data as an argument for the remote execution of the job as Jar files. Also, I need to name my output file same as the first argument passed during execution.

Please do share your ideas and suggestions on this.

Apr 18, 2018 in Talend by anto.trigg4
• 3,420 points
118 views

1 answer to this question.

Your answer

Your name to display (optional):
Privacy: Your email address will only be used for sending these notifications.
0 votes

I think you should use context variables. You can create two context variables (output_file & where_val ) of “String” type.

Now, in the component tab of the tOracleInput type the below code to concatenate the where clause:

"select * from my_view where field" + context.where_val;"

Next, in the tOutputDelimited component’s name field, you can use the context variable to name your output file: 

"/home/user/" + context.out_filename”.

I think these will fulfill your requirements. After this, you can easily access your job remotely. In the terminal, you can type in the command as below:

my_job_launcher.sh --context_param output_file='output.txt' --context_param where_val='>7';
answered Apr 18, 2018 by geek.erkami
• 2,320 points

Related Questions In Talend

0 votes
1 answer

How to load a set of files into database using Talend

Using tFileList component,  you can read all the files present ...READ MORE

answered Apr 16, 2018 in Talend by code.reaper12
• 3,450 points
378 views
0 votes
1 answer
0 votes
1 answer
0 votes
1 answer
0 votes
1 answer

Database Migration In Talend

You can easily migrate your database by ...READ MORE

answered Apr 18, 2018 in Talend by code.reaper12
• 3,450 points
63 views
0 votes
1 answer
0 votes
1 answer

Closed loop in Talend

As you might know,  in Talend all ...READ MORE

answered Apr 19, 2018 in Talend by code.reaper12
• 3,450 points
237 views
0 votes
1 answer

Connecting tJIRAOutput component using Talend

Your entire configuration is correct apart from ...READ MORE

answered Apr 19, 2018 in Talend by geek.erkami
• 2,320 points
106 views
0 votes
1 answer

tWaitForFile component insufficiency in Talend

Regarding your first issue, tWaitForFile component provides ...READ MORE

answered Apr 10, 2018 in Talend by geek.erkami
• 2,320 points
189 views

© 2018 Brain4ce Education Solutions Pvt. Ltd. All rights Reserved.
"PMP®","PMI®", "PMI-ACP®" and "PMBOK®" are registered marks of the Project Management Institute, Inc. MongoDB®, Mongo and the leaf logo are the registered trademarks of MongoDB, Inc.