Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
399 views
in Technique[技术] by (71.8m points)

Azure Data Factory- Data Flow - After completion - move

I am using ADF v2 DataFlow ativity to load data from a csv file in a Blob Storage into a table in Azure SQL database. In the Dataflow (Source - Blob storage), in Source options, there is an option 'After Completion(No Action/Delete Source file/ Move)'. I am looking to utilize the move option to save those csv files in a container renaming those files in concatenation with with today's date. How do I frame the logic for this? Can someone please help?

question from:https://stackoverflow.com/questions/65882913/azure-data-factory-data-flow-after-completion-move

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Answer

0 votes
by (71.8m points)

You could parameter the source file to achieve that. Please ref my example.

Data Flow parameter settings: enter image description here

Set the source file and move expression in Source Options: enter image description here

Expressions to rename the source with "name + current date":

concat(substring($filename, 1, length($filename)-4),toString(currentUTC(),'yyyy-MM-dd') )

My full file name is "word.csv", the output file name is "word2020-01-26", enter image description here

HTH.


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...