Move file in Azure data Factory

Sarah C Benjamin 6 Reputation points
2021-05-18T20:19:52.5+00:00

Hi
I was following this post https://learn.microsoft.com/en-us/answers/questions/57483/move-file-rather-than-copy-in-azure-data-factory.html
and asked a question there too.

I need to move files in ADF and used this create a new file and delete the old file approach. I don't need to read the file so thought copying like this be fine.

The only problem with this approach I am seeing is that I am losing the timestamp of the file because of creating a new file and deleting it.

Is there no way in ADF that we can move the original file without reading it and thus able to maintain the timestamp of the file? This is the last step in my pipeline and I really don't want to take this step to logic app. Unless there is a way for me to call the logic app within ADF?

Thanks

Azure Data Factory
Azure Data Factory
An Azure service for ingesting, preparing, and transforming data at scale.
11,623 questions
{count} votes

1 answer

Sort by: Most helpful
  1. MartinJaffer-MSFT 26,236 Reputation points
    2021-05-19T19:47:12.913+00:00

    Hello @Sarah C Benjamin and welcome to Microsoft Q&A.

    There are a couple things you can try.

    First, use binary type dataset, instead of a more specific one like CSV, JSON, etc. The binary does not attempt to parse what is inside the file.

    Also, you can try using settings to preserve some of the metadata.

    98012-image.png

    The post you linked is a little stale. There is now a way to make the delete part of the copy action. You need not make the delete a separate activity.

    97959-image.png


Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.