Ask Your Question
1

How to retrieve input data file name dynamically?

asked 2018-12-04 13:13:10 -0600

boWang gravatar image

I am using a pipeline to upload data from a .csv file into postgres DB. I'd like to record input data file name into DB too. But how can I retrieve input file name dynamically?

For example, I have a Directory Stage reading .csv file data from /opt/data. The data file name will different from time to time, and while my pipeline is processing data from this file, I want to record the file name as well. How can I do that?

Thanks

Michelle

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
1

answered 2018-12-04 14:25:39 -0600

iamontheinet gravatar image

Hi!

You can use Expression Evaluator to add (current) filename as a new record field. See below.

image description

Result:

image description

Cheers, Dash

edit flag offensive delete link more

Comments

Dash, thank you so much. Works perfectly. Michelle

boWang gravatar imageboWang ( 2018-12-04 15:13:04 -0600 )edit

You're welcome!

iamontheinet gravatar imageiamontheinet ( 2018-12-04 15:14:01 -0600 )edit
Login/Signup to Answer

Question Tools

2 followers

Stats

Asked: 2018-12-04 13:13:10 -0600

Seen: 23 times

Last updated: Dec 04