How to rename folders in ADLS using ADF

Bhavin Dedhia 25 Reputation points
2023-03-04T08:02:17.1966667+00:00

Hello Everyone!

How to rename folder in ADLS using ADF pipeline. I can't find any content for same on the internet.

Thanks in advance.

Azure Data Lake Storage
Azure Data Lake Storage
An Azure service that provides an enterprise-wide hyper-scale repository for big data analytic workloads and is integrated with Azure Blob Storage.
1,426 questions
Azure Data Factory
Azure Data Factory
An Azure service for ingesting, preparing, and transforming data at scale.
10,196 questions
0 comments No comments
{count} votes

Accepted answer
  1. KranthiPakala-MSFT 46,442 Reputation points Microsoft Employee
    2023-03-06T22:49:48.2666667+00:00

    Hi @Bhavin Dedhia ,

    Welcome to Microsoft Q&A forum and thanks for reaching out here.

    As you want to rename a folder in ADLS Gen2 using ADF, you can utilize ADLS Gen2 REST API and call the API using Web Activity in Azure Data Factory.

    1. ADLS Gen2 Path - Create
    2. Web activity in Azure Data Factory and Azure Synapse Analytics

    If you are comfortable in using Azure Databricks notebooks, then you may also use notebooks to execute below python code which can rename folder in ADLS Gen2. And then you can execute those ADB notebook from ADF. In case if you already have a Synapse analytics Workspace, then you can use the below code and execute it in Synapse notebook directly and attach it to a pipeline in Synapse.

    Ref doc: ADLS Gen2 - Rename or move a directory (Python)
    User's image

    Hope this helps.


    Please don’t forget to Accept Answer and Yes for "was this answer helpful" wherever the information provided helps you, this can be beneficial to other community members.

    2 people found this answer helpful.

0 additional answers

Sort by: Most helpful