how to give dynamic file path input to tFileInputPositional

One Star

how to give dynamic file path input to tFileInputPositional

Hello,
I am trying to take data from text file and store them into database. right now fortFileInputPositional filename/stream
i have set a static path. i want to know that whether is it possible to set dynamic path ? so i can run my job on multiple file in one execution?
thanks.
Moderator

Re: how to give dynamic file path input to tFileInputPositional

Hi,
It is possible to set dynamic path.
For your scenario, you can use tContextLoad or explicit tContext to load your multiple filename and give a Context value in filename/stream of tFileInputPositional.
Please take a look at my screenshots and online component reference TalendHelpCenter:tContextLoad
Best regards
Sabrina
--
Don't forget to give kudos when a reply is helpful and click Accept the solution when you think you're good with it.
Four Stars

Re: how to give dynamic file path input to tFileInputPositional

Hi Dipens,
I Assume this is what you are looking for - https://help.talend.com/search/all?query=tFileList&content-lang=en
Use tFileList-->tFileInputPositional--> DatabaseOutput
- in tFileInputPositional - use tFileListCurrentFilePath for Filename
- use appropriate filter if any...
After executing the job, you would iterate on each file based on standard metadata and see the output of each file.
Thanks
Vaibhav

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

APIs for Dummies

View this on-demand webinar about APIs....

Watch Now