{"id":51555,"date":"2021-08-17T17:30:48","date_gmt":"2021-08-17T16:30:48","guid":{"rendered":"https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/?p=51555"},"modified":"2022-02-10T20:53:37","modified_gmt":"2022-02-10T19:53:37","slug":"backup-your-data-lake-using-azure-data-factory-metadata-copy-activity","status":"publish","type":"post","link":"https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/technetuk\/2021\/08\/17\/backup-your-data-lake-using-azure-data-factory-metadata-copy-activity\/","title":{"rendered":"Backup your data lake using Azure Data Factory \u2013 Metadata Copy activity"},"content":{"rendered":"<p><img loading=\"lazy\" decoding=\"async\" class=\"attachment-full size-full webp-format\" src=\"https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2020\/03\/datafactoryheader.png\" alt=\"An illustration depicting Azure Data Factory, next to a picture of Bit the Raccoon.\" width=\"1920\" height=\"700\" data-orig-srcset=\"https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2020\/03\/datafactoryheader.png 1920w, https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2020\/03\/datafactoryheader-300x109.png 300w, https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2020\/03\/datafactoryheader-1024x373.png 1024w, https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2020\/03\/datafactoryheader-768x280.png 768w, https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2020\/03\/datafactoryheader-1536x560.png 1536w, https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2020\/03\/datafactoryheader-330x120.png 330w, https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2020\/03\/datafactoryheader-800x292.png 800w, https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2020\/03\/datafactoryheader-400x146.png 400w\" data-orig-src=\"https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2020\/03\/datafactoryheader.png\"><\/p>\n<p>Most organisations leverage the disaster recovery options available to them on Azure to ensure they are properly protected in case of a data center outage. Depending on their requirements, they can choose among ZRS, GZRS, or GRS &amp; RA-GRS. More details are available <a href=\"https:\/\/docs.microsoft.com\/en-us\/azure\/storage\/blobs\/data-lake-storage-best-practices#resiliency-considerations\" target=\"_blank\" rel=\"noopener\">here<\/a>.<\/p>\n<p>However, none of these options protect against data deletion. Indeed, if records are accidentally deleted, that deletion is replicated. To protect against such events, customers should consider backing up their data lake. As of today, Azure Data Lake Gen 2 does not have native support for this kind of backup.<\/p>\n<p>Azure Data Factory (ADF) is one of many technical options for a custom backup solution. In this blog post, we\u2019ll walk you through how to leverage ADF pipelines for full and incremental backups of your data lake on Azure. Keeping in mind the size of most enterprise data lakes, we\u2019ll leverage the <strong>Metadata-driven<\/strong> copy task in Azure Data Factory (currently in preview), to build large-scale data loading pipelines. More details on the <strong>Metadata-driven<\/strong> copy task are available <a href=\"https:\/\/github.com\/Azure\/Azure-DataFactory\/blob\/main\/Metadata%20driven%20data%20ingestion%20solution%20in%20copy%20data%20tool\/Large-scale%20data%20loading%20pipelines%20with%20metadata-driven%20approach%20in%20copy%20data%20tool.pdf?ocid=AID3038246\" target=\"_blank\" rel=\"noopener\">here<\/a>.<\/p>\n<p>Let\u2019s proceed with a scenario that requires an incremental backup every day and a full back up on the last day of every month. We assume you are familiar with ADF. If not, you can find some learning resources <a href=\"https:\/\/docs.microsoft.com\/en-us\/azure\/data-factory\/introduction?ocid=AID3038246\" target=\"_blank\" rel=\"noopener\">here<\/a>.<\/p>\n<p>&nbsp;<\/p>\n<h3>Prerequisites<\/h3>\n<ul>\n<li>One Azure SQL Database to host the metadata table for the ADF metadata Task.<\/li>\n<li>A linked Service in ADF with a successful connection to the database.<\/li>\n<li>Source and Sink Azure Data Lake Gen 2 resources with storage contributor permissions at the minimum.<\/li>\n<li>Linked services to the source and sink storage account(s).<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<h3>Generate the ADF pipelines<\/h3>\n<p>In the ADF Author hub, launch the Copy Data Tool as shown below.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"attachment-full size-full webp-format aligncenter\" src=\"https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image001.png\" alt=\"A screenshot of the ADF Author Hub\" width=\"624\" height=\"445\" data-orig-srcset=\"https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image001.png 624w, https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image001-300x214.png 300w, https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image001-330x235.png 330w, https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image001-400x285.png 400w\" data-orig-src=\"https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image001.png\"><\/p>\n<p>1. In the properties page, select the Metadata-driven copy task type. You will be prompted to select a linked service to host the control table. The control table will be used to maintain metadata for the copy activity &#8211; the source storage account, the source container, the target storage account, etc. \u2013 and can be created in a Azure SQL DB or Synapse Analytics instance. Note that during the preview, you might need to apply minor changes to the script generated to create the table in Synapse. For this walkthrough, we\u2019ll use an Azure SQL Database to host the meta data properties.<\/p>\n<ul>\n<li>Choose an existing linked service or create a new one to the Azure SQL Database. After you select the linked service, new text boxes will appear for the schema and the name of the control table.<\/li>\n<li>Select an existing table or create a new one by checking on the Create new table option.<\/li>\n<li>Specify the task cadence or task schedule and provide appropriate values.<\/li>\n<li>Click on Next to move to the next step<\/li>\n<\/ul>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"attachment-full size-full webp-format aligncenter\" src=\"https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image002.png\" alt=\"A screenshot of the Copy Data properties page\" width=\"624\" height=\"337\" data-orig-srcset=\"https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image002.png 624w, https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image002-300x162.png 300w, https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image002-330x178.png 330w, https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image002-400x216.png 400w\" data-orig-src=\"https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image002.png\"><\/p>\n<p>2. Now we\u2019ll provide the connection details of our data source.<\/p>\n<ul>\n<li>Many source types are supported. In our case, we\u2019ll choose Azure Data Lake Storage Gen 2.<\/li>\n<li>Select an existing linked service to the source storage or create a new one.<\/li>\n<li>Click on the Browse button to select the container and\/or folder you want to backup.<\/li>\n<li>As mentioned above, we create a full backup once a month and an incremental backup on a daily basis. Select Incremental Load for the File loading behaviour. This will generate an entry in the control table for the incremental load. We\u2019ll manually create another entry for the full load.<\/li>\n<li>As this is a backup, we do not need to read the content of the files, so we\u2019ll select a Binary copy behaviour.<\/li>\n<li>Select Next.<\/li>\n<\/ul>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"attachment-full size-full webp-format aligncenter\" src=\"https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image003.png\" alt=\"A screenshot of the Source data store prompt in the Copy Data tool\" width=\"624\" height=\"339\" data-orig-srcset=\"https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image003.png 624w, https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image003-300x163.png 300w, https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image003-330x179.png 330w, https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image003-400x217.png 400w\" data-orig-src=\"https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image003.png\"><\/p>\n<p>3. In the Destination data store page, specify the properties of the target storage account.<\/p>\n<ul>\n<li>Choose the destination target type as Azure Data Lake Storage Gen2.<\/li>\n<li>Select an existing linked service to the target storage or create a new one.<\/li>\n<li>Click on the Browse button to select the backup container.<\/li>\n<li>Select the \u2018Preserve Hierarchy\u2019 copy behaviour to keep the folder structure \u2018as-is\u2019 from source to sink.<\/li>\n<\/ul>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"attachment-full size-full webp-format aligncenter\" src=\"https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image004.png\" alt=\"graphical user interface, text, application, email\" width=\"623\" height=\"339\" data-orig-srcset=\"https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image004.png 623w, https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image004-300x163.png 300w, https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image004-330x180.png 330w, https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image004-400x218.png 400w\" data-orig-src=\"https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image004.png\"><\/p>\n<p>4. Provide the Task Prefix name on the Settings step. Under Advanced Settings, you can select options like Data Consistency Verification, Fault Tolerance, Preserving the ACLs and many more.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"attachment-full webp-format aligncenter\" src=\"https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image026.png\" alt=\"A screenshot of the settings pane in the Copy Data tool\" width=\"624\" height=\"688\" data-orig-srcset=\"https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image026.png 624w, https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image026-272x300.png 272w, https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image026-227x250.png 227w, https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image026-317x350.png 317w, https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image026-400x441.png 400w\" data-orig-src=\"https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image026.png\"><\/p>\n<p>5. Review and validate your set up in the summary page and make sure it all looks good, then proceed by clicking Next.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"attachment-full size-full webp-format aligncenter\" src=\"https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image027.png\" alt=\"A screenshot of the summary page in the Copy Data tool\" width=\"593\" height=\"321\" data-orig-srcset=\"https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image027.png 593w, https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image027-300x162.png 300w, https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image027-330x179.png 330w, https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image027-400x217.png 400w\" data-orig-src=\"https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image027.png\"><\/p>\n<p>6. In the Deployment step, the following are created:<\/p>\n<ul>\n<li>The ADF pipelines for the backup.<\/li>\n<li>Source, target and control datasets.<\/li>\n<li>The SQL script to create the control tables and insert the parameters for the incremental load.<\/li>\n<\/ul>\n<p>Copy the SQL script and run against the Azure SQL database (the same database we used as the control table store) using your favourite client tool&nbsp; &#8211; Management Studio, Azure Data Studio or even the Query Editor option in the Azure portal. You also have the option to download the script, if needed.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"attachment-full size-full webp-format aligncenter\" src=\"https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image028.png\" alt=\"A screenshot of the Deployment complete screen in the Copy Data tool\" width=\"542\" height=\"439\" data-orig-srcset=\"https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image028.png 542w, https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image028-300x243.png 300w, https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image028-309x250.png 309w, https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image028-330x267.png 330w, https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image028-400x324.png 400w\" data-orig-src=\"https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image028.png\"><\/p>\n<p>Go back to the authoring hub in ADF to view the generated pipelines and datasets.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"attachment-full size-full webp-format aligncenter\" src=\"https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image029.png\" alt=\"A screenshot of the generated pipelines and datasets\" width=\"459\" height=\"128\" data-orig-srcset=\"https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image029.png 459w, https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image029-300x84.png 300w, https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image029-330x92.png 330w, https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image029-400x112.png 400w\" data-orig-src=\"https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image029.png\"><\/p>\n<p>As you can see, three pipelines are generated:<\/p>\n<ul>\n<li data-leveltext=\"\u00b7\" data-font=\"Symbol\" data-listid=\"2\" data-aria-posinset=\"19\" data-aria-level=\"1\"><strong>Top level Pipeline: &lt;Task_Prefix_Name&gt;_TopLevel<\/strong><\/li>\n<\/ul>\n<p>This pipeline counts the total number of objects (tables etc.) to be copied in this run, determines the number of sequential batches based on the maximum allowed concurrent copy task instances, and then executes another pipeline to copy different batches sequentially.<\/p>\n<ul>\n<li data-leveltext=\"\u00b7\" data-font=\"Symbol\" data-listid=\"2\" data-aria-posinset=\"20\" data-aria-level=\"1\"><strong>Middle level Pipeline:&nbsp;Task_Prefix_Name&gt;_MiddleLevel<\/strong><\/li>\n<\/ul>\n<p>This pipeline copies one batch of objects. The objects belonging to this batch will be copied in parallel.<\/p>\n<ul>\n<li data-leveltext=\"\u00b7\" data-font=\"Symbol\" data-listid=\"2\" data-aria-posinset=\"21\" data-aria-level=\"1\"><strong>Bottom level pipeline:&nbsp;MetadataDrivenCopyTask_xxx_&nbsp;BottomLevel<\/strong><\/li>\n<\/ul>\n<p>This pipeline copies objects from one group. The objects belonging to this group will be copied in parallel.<\/p>\n<p>&nbsp;<\/p>\n<h3>Updates on the generated artifacts<\/h3>\n<p>The incremental load for an ADLS data source is not yet supported as part of the Metadata Driven Copy Task. To make this work, we will tweak the ADF pipelines a little and create a stored procedure in the Azure SQL Database.<\/p>\n<h4>Stored procedure<\/h4>\n<p>The stored procedure will update the modifiedDatetimeStart attribute of the CopySourceSettings column with the pipeline trigger time, after each run. That way, the next time you execute the ADF pipeline, it will only copy files created or modified since the last run.<\/p>\n<p>If, for any reason, you want to rerun the pipeline from a specific date, you can manually update the modifiedDatetimeStart in the control table.<\/p>\n<pre><span style=\"color: #0000ff\">CREATE PROCEDURE<\/span> [dbo].[Update_modifiedDatetimeStart]\n@modifiedDatetimeStartDate <span style=\"color: #0000ff\">nvarchar<\/span>(<span style=\"color: #ff00ff\">max<\/span>),\n@Id <span style=\"color: #0000ff\">int<\/span>\n    <span style=\"color: #0000ff\">AS<\/span>\n<span style=\"color: #ff00ff\">UPDATE<\/span> &lt;Your Control table&gt;\n    <span style=\"color: #0000ff\">SET<\/span> CopySourceSettings=<span style=\"color: #ff00ff\">JSON_MODIFY<\/span>(CopySourceSettings,'<span style=\"color: #ff0000\">$.modifiedDatetimeStart<\/span>', @modifiedDatetimeStartDate) WHERE Id = @Id<\/pre>\n<h4>ADF pipelines<\/h4>\n<p>Open the xxx_&nbsp;<strong>BottomLevel<\/strong>&nbsp;pipeline. Drill down on the&nbsp;ForEach&nbsp;activities. A Switch activity decides when to do a full load and default (incremental load).<\/p>\n<h4>Incremental load<\/h4>\n<p>Select the Default Activity as we need to make changes to the incremental load.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"attachment-full size-full webp-format aligncenter\" src=\"https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image030.png\" alt=\"A screenshot showing how to find the Default Activity setting\" width=\"624\" height=\"350\" data-orig-srcset=\"https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image030.png 624w, https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image030-300x168.png 300w, https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image030-330x185.png 330w, https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image030-400x224.png 400w, https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image030-235x132.png 235w\" data-orig-src=\"https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image030.png\"><\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"attachment-full size-full webp-format aligncenter\" src=\"https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image031.png\" alt=\"A screenshot showing how to find the Default Activity setting\" width=\"624\" height=\"306\" data-orig-srcset=\"https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image031.png 624w, https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image031-300x147.png 300w, https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image031-330x162.png 330w, https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image031-400x196.png 400w\" data-orig-src=\"https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image031.png\"><\/p>\n<p>Add a new Stored procedure activity after the copy activity. Keep the default link between the activity (OnSuccess).<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"attachment-full size-full webp-format aligncenter\" src=\"https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image032.png\" alt=\"A screenshot showing a new stored procedure activity being added.\" width=\"624\" height=\"367\" data-orig-srcset=\"https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image032.png 624w, https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image032-300x176.png 300w, https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image032-330x194.png 330w, https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image032-400x235.png 400w\" data-orig-src=\"https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image032.png\"><\/p>\n<p>Select the \u2018Stored Procedure\u2019 activity.<\/p>\n<ul>\n<li data-leveltext=\"\u00b7\" data-font=\"Symbol\" data-listid=\"2\" data-aria-posinset=\"22\" data-aria-level=\"1\">In the activity settings, specify the link service to the Azure SQL database and select the [dbo].[Update_modifiedDatetimeStart] previously created.<\/li>\n<li data-leveltext=\"\u00b7\" data-font=\"Symbol\" data-listid=\"2\" data-aria-posinset=\"23\" data-aria-level=\"1\">Click on Import to retrieve the stored procedure parameters.&nbsp; Fill in the parameters with the below values:\n<ul>\n<li data-leveltext=\"\u00b7\" data-font=\"Symbol\" data-listid=\"2\" data-aria-posinset=\"23\" data-aria-level=\"1\">Id: @item().Id<\/li>\n<li data-leveltext=\"\u00b7\" data-font=\"Symbol\" data-listid=\"2\" data-aria-posinset=\"23\" data-aria-level=\"1\">modifiedDatetimeStartDate: @convertTimeZone(pipeline().TriggerTime,&#8217;UTC&#8217;, &#8216;Eastern Standard Time&#8217;)<\/li>\n<\/ul>\n<\/li>\n<\/ul>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"attachment-full size-full webp-format aligncenter\" src=\"https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image033.png\" alt=\"A screenshot showing an import of the stored procedure parameters.\" width=\"624\" height=\"526\" data-orig-srcset=\"https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image033.png 624w, https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image033-300x253.png 300w, https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image033-297x250.png 297w, https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image033-330x278.png 330w, https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image033-400x337.png 400w\" data-orig-src=\"https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image033.png\"><\/p>\n<p>Next, select the \u2018Copy data\u2019 activity. In the source tab, update the start date and the end date of the \u2018Filter by last modified\u2019 property as follows:<\/p>\n<ul>\n<li style=\"list-style-type: none\">\n<ul>\n<li data-leveltext=\"o\" data-font=\"&quot;Courier New&quot;\" data-listid=\"2\" data-aria-posinset=\"3\" data-aria-level=\"2\">Start Time (UTC): @formatDateTime(json(item().CopySourceSettings).modifiedDatetimeStart)<\/li>\n<li data-leveltext=\"o\" data-font=\"&quot;Courier New&quot;\" data-listid=\"2\" data-aria-posinset=\"4\" data-aria-level=\"2\">End Time (UTC): @formatDateTime(json(item().CopySourceSettings).modifiedDatetimeEnd)<\/li>\n<\/ul>\n<\/li>\n<\/ul>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"attachment-full size-full webp-format aligncenter\" src=\"https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image034.png\" alt=\"A screenshot showing the start and end times being updated\" width=\"624\" height=\"593\" data-orig-srcset=\"https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image034.png 624w, https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image034-300x285.png 300w, https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image034-263x250.png 263w, https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image034-330x314.png 330w, https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image034-400x380.png 400w\" data-orig-src=\"https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image034.png\"><\/p>\n<p>In the sink tab, update the&nbsp;folderPath&nbsp;property as follows:<\/p>\n<ul>\n<li style=\"list-style-type: none\">\n<ul>\n<li data-leveltext=\"o\" data-font=\"&quot;Courier New&quot;\" data-listid=\"2\" data-aria-posinset=\"5\" data-aria-level=\"2\">cw_folderPath:&nbsp;incremental\/@{formatDateTime(pipeline().TriggerTime,&#8217;yyyy&#8217;)}\/@{formatDateTime(pipeline().TriggerTime,&#8217;MM&#8217;)}\/@{formatDateTime(pipeline().TriggerTime,&#8217;dd&#8217;)}<\/li>\n<\/ul>\n<\/li>\n<\/ul>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"attachment-full size-full webp-format aligncenter\" src=\"https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image035.png\" alt=\"graphical user interface, text, application\" width=\"624\" height=\"532\" data-orig-srcset=\"https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image035.png 624w, https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image035-300x256.png 300w, https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image035-293x250.png 293w, https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image035-330x281.png 330w, https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image035-400x341.png 400w\" data-orig-src=\"https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image035.png\"><\/p>\n<p>The tweaks for the incremental load are now complete.<\/p>\n<h4>Full load<\/h4>\n<p>Now go back and edit the FullLoad \u2018Copy data\u2019 activity. The purpose of the FullLoad is to ensure the entire storage account and the account in the source is backed up and to specify the target folder hierarchy:<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"attachment-full size-full webp-format aligncenter\" src=\"https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image036.png\" alt=\"A screenshot showing the location of the FullLoad activity\" width=\"624\" height=\"330\" data-orig-srcset=\"https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image036.png 624w, https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image036-300x159.png 300w, https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image036-330x175.png 330w, https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image036-400x212.png 400w\" data-orig-src=\"https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image036.png\"><\/p>\n<p>In the source tab, make sure both the start date and the end date of the \u2018Filter by last modified\u2019 are blank.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"attachment-full size-full webp-format aligncenter\" src=\"https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image037.png\" alt=\"A screenshot showing the start and end dates are blank\" width=\"624\" height=\"597\" data-orig-srcset=\"https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image037.png 624w, https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image037-300x287.png 300w, https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image037-261x250.png 261w, https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image037-330x316.png 330w, https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image037-400x383.png 400w\" data-orig-src=\"https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image037.png\"><\/p>\n<p>In the sink tab, update the&nbsp;folderPath&nbsp;property as follows:<\/p>\n<ul>\n<li style=\"list-style-type: none\">\n<ul>\n<li data-leveltext=\"o\" data-font=\"&quot;Courier New&quot;\" data-listid=\"2\" data-aria-posinset=\"6\" data-aria-level=\"2\">cw_folderPath:&nbsp;fullbackup\/@{formatDateTime(pipeline().TriggerTime,&#8217;yyyy&#8217;)}\/@{formatDateTime(pipeline().TriggerTime,&#8217;MM&#8217;)}<\/li>\n<\/ul>\n<\/li>\n<\/ul>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"attachment-full webp-format aligncenter\" src=\"https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image038.png\" alt=\"A screenshot showing the updated folderPath property\" width=\"624\" height=\"604\" data-orig-srcset=\"https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image038.png 624w, https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image038-300x290.png 300w, https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image038-258x250.png 258w, https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image038-330x319.png 330w, https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image038-400x387.png 400w\" data-orig-src=\"https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image038.png\"><\/p>\n<h3>Create and schedule the triggers.<\/h3>\n<p>We now need to create 2 triggers, one each for the full and incremental backups.<\/p>\n<p>To create a trigger, click on Add trigger &gt; New\/Edit<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"attachment-full webp-format aligncenter\" src=\"https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image039.png\" alt=\"A screenshot of the Add trigger function\" width=\"340\" height=\"127\" data-orig-src=\"https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image039.png\"><\/p>\n<p>In the Add triggers panel that opens up, select New in the Choose trigger drop down.<\/p>\n<p>&nbsp;<\/p>\n<h4>Trigger for the Full Backup<\/h4>\n<p>This will initiate the full backup of the source container(s) on the last day of the month, irrespective of the number of days in each month. Create the trigger as shown below.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"attachment-full size-full webp-format aligncenter\" src=\"https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image040.png\" alt=\"A screenshot showing the date and timezone functions for the full backup\" width=\"611\" height=\"674\" data-orig-srcset=\"https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image040.png 611w, https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image040-272x300.png 272w, https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image040-227x250.png 227w, https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image040-317x350.png 317w, https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image040-400x441.png 400w\" data-orig-src=\"https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image040.png\"><\/p>\n<p>&nbsp;<\/p>\n<h4>Trigger for the Incremental Backup<\/h4>\n<p>This will copy only the new and edited files from the source since the previous run. The incremental backup in this example will run once a day to copy relevant files from the source container(s) to destination container(s).&nbsp;Create this trigger as shown below.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"attachment-full size-full webp-format aligncenter\" src=\"https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image041.png\" alt=\"graphical user interface, application, email\" width=\"575\" height=\"711\" data-orig-srcset=\"https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image041.png 575w, https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image041-243x300.png 243w, https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image041-202x250.png 202w, https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image041-283x350.png 283w, https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image041-400x495.png 400w\" data-orig-src=\"https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image041.png\"><\/p>\n<p>Remember to set the Activated status to \u2018Yes\u2019 for both Triggers created.<\/p>\n<p>&nbsp;<\/p>\n<h4>Control table &#8211; Incremental load record<\/h4>\n<p>Using your favourite client tool, connect to the Azure SQL database and run a select statement on the control table. As mentioned above, only one record was created as part of the generated script. That record contains the properties of the incremental load.<\/p>\n<p>When you execute the ADF pipeline (), the lookup activity filters on the trigger name:<\/p>\n<pre><span style=\"color: #0000ff\">SELECT<\/span> <span style=\"color: #ff00ff\">count<\/span>(*) <span style=\"color: #0000ff\">as<\/span> <span style=\"color: #ff00ff\">count<\/span> <span style=\"color: #0000ff\">FROM<\/span> @{pipeline().<span style=\"color: #00ff00\">parameters<\/span>.MainControlTableName}\n<span style=\"color: #0000ff\">where&nbsp;<\/span><a href=\"mailto:TopLevelPipelineName='@%7bpipeline().Pipeline\">TopLevelPipelineName='@{pipeline().Pipeline<\/a>}'&nbsp;and&nbsp;TriggerName&nbsp;like&nbsp;'<a href=\"mailto:%25@%7bpipeline().TriggerName\">%@{pipeline().TriggerName<\/a>}%'<\/pre>\n<p>Perform the following updates:<\/p>\n<ol>\n<li data-leveltext=\"%1.\" data-font=\"Segoe UI\" data-listid=\"1\" data-aria-posinset=\"1\" data-aria-level=\"1\">Make a copy of the current row in the table and insert it as a second row in the table.<\/li>\n<li data-leveltext=\"%1.\" data-font=\"Segoe UI\" data-listid=\"1\" data-aria-posinset=\"1\" data-aria-level=\"1\">In the newly inserted row, look up the columns \u201cTriggerName\u201d and \u201cDataLoadingBehaviorSettings\u201d&nbsp; and change the contents as below:<\/li>\n<\/ol>\n<pre>Column \u201cTriggerName\u201d:\n[&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; \"Sandbox\",&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<em>\"&lt; Name of your Incremental Trigger &gt;\"<\/em>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ]\nColumn \u201cDataLoadingBehaviorSettings\u201d:\n\n{&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; \"dataLoadingBehavior\": \"Default\"&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; }<\/pre>\n<p>After completing these steps, the content of the new row in the metadata table should look similar to:<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"attachment-full size-full webp-format\" src=\"https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image042.png\" alt=\"The content of the new row in the metadata table\" width=\"668\" height=\"131\" data-orig-srcset=\"https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image042.png 668w, https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image042-300x59.png 300w, https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image042-330x65.png 330w, https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image042-400x78.png 400w\" data-orig-src=\"https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image042.png\"><\/p>\n<p>Finally, in the newly inserted row, look up the column \u201cCopySourceSettings\u201d and change the entries in the column as follows:<\/p>\n<ul>\n<li>modifiedDatetimeStart: &lt;Datetime for initial start of Pipeline. e.g., 2021:06:25T18:00:00&gt;<\/li>\n<li>modifiedDatetimeEnd: &lt;Datetime for deactivate Pipeline from running. e.g., 2090:06:25T18:00:00&gt;<\/li>\n<\/ul>\n<p>After completing the updates, the column should look like below:<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"attachment-full webp-format alignnone\" src=\"https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image043.png\" alt=\"The final appearance of the new column\" width=\"695\" height=\"141\" data-orig-srcset=\"https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image043.png 695w, https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image043-300x61.png 300w, https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image043-330x67.png 330w, https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image043-400x81.png 400w\" data-orig-src=\"https:\/\/www.microsoft.com\/en-us\/industry\/blog\/wp-content\/uploads\/sites\/22\/2021\/08\/image043.png\"><\/p>\n<p>This completes the setup for the backups.<\/p>\n<p>&nbsp;<\/p>\n<h3>About the authors<\/h3>\n<p><strong>Issagha Ba<\/strong> is a Principal Cloud Solution Architect with the Microsoft Customer Success Unit and drives large scale and deep technical engagements with customers. Issagha has a wealth of experience on the Azure data platform and analytics.<\/p>\n<p><strong>Athulya Ramamoorthy<\/strong> is a Cloud Solution Architect with Microsoft, focusing on Data and Analytics, and enjoys helping customers innovate on Azure. Athulya also has a keen interest in using technology to drive sustainability.<\/p>\n<p><strong>Volkan Civelek<\/strong> has extensive experience on Data, AI and Cloud systems. He&#8217;s currently helping high priority global customers at Microsoft. Data architecture for Scalability and High Availability are his passion.<\/p>\n<p><strong>Abiodun Olatunji<\/strong> is a Senior Cloud Solution Architect with the Microsoft Customer Success Unit. He focuses on Big Data &amp; Analytics workloads and drives large scale technical engagements with various global customers. He has deep experience in various Azure Data Services including Azure Synapse, SQL, Purview, Stream Analytics, Data Factory, and Data Lake.<\/p>\n<p>&nbsp;<\/p>\n<h3>Learn more<\/h3>\n<ul>\n<li><a href=\"https:\/\/docs.microsoft.com\/en-us\/learn\/modules\/intro-to-azure-data-factory?ocid=AID3038246\" target=\"_blank\" rel=\"noopener\">Introduction to Azure Data Factory<\/a><\/li>\n<li><a href=\"https:\/\/docs.microsoft.com\/en-us\/learn\/modules\/introduction-to-azure-data-lake-storage?ocid=AID3038246\" target=\"_blank\" rel=\"noopener\">Introduction to Azure Data Lake storage<\/a><\/li>\n<li><a href=\"https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/technetuk\/2021\/04\/15\/creating-a-metadata-driven-processing-framework-for-azure-data-factory?ocid=AID3038246\" target=\"_blank\" rel=\"noopener\">Creating a Metadata-Driven Processing Framework For Azure Data Factory<\/a><\/li>\n<\/ul>\n","protected":false},"excerpt":{"rendered":"<p>In this blog post, we\u2019ll walk you through how to leverage ADF pipelines for full and incremental backups of your data lake on Azure.<\/p>\n","protected":false},"author":430,"featured_media":30924,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"ep_exclude_from_search":false,"_classifai_error":"","_classifai_text_to_speech_error":"","footnotes":""},"categories":[594],"post_tag":[128,636,519],"content-type":[],"coauthors":[1761],"class_list":["post-51555","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-technetuk","tag-azure","tag-data","tag-technet-uk"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v27.2 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>Backup your data lake using Azure Data Factory \u2013 Metadata Copy activity - Microsoft Industry Blogs - United Kingdom<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/technetuk\/2021\/08\/17\/backup-your-data-lake-using-azure-data-factory-metadata-copy-activity\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Backup your data lake using Azure Data Factory \u2013 Metadata Copy activity - Microsoft Industry Blogs - United Kingdom\" \/>\n<meta property=\"og:description\" content=\"In this blog post, we\u2019ll walk you through how to leverage ADF pipelines for full and incremental backups of your data lake on Azure.\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/technetuk\/2021\/08\/17\/backup-your-data-lake-using-azure-data-factory-metadata-copy-activity\/\" \/>\n<meta property=\"og:site_name\" content=\"Microsoft Industry Blogs - United Kingdom\" \/>\n<meta property=\"article:published_time\" content=\"2021-08-17T16:30:48+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2022-02-10T19:53:37+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/wp-content\/uploads\/sites\/22\/2020\/03\/datafactorythumb.png\" \/>\n\t<meta property=\"og:image:width\" content=\"800\" \/>\n\t<meta property=\"og:image:height\" content=\"450\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/png\" \/>\n<meta name=\"author\" content=\"Microsoft Customer Success Unit\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Microsoft Customer Success Unit\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"8 min read\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/technetuk\/2021\/08\/17\/backup-your-data-lake-using-azure-data-factory-metadata-copy-activity\/#article\",\"isPartOf\":{\"@id\":\"https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/technetuk\/2021\/08\/17\/backup-your-data-lake-using-azure-data-factory-metadata-copy-activity\/\"},\"author\":[{\"@id\":\"https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/author\/microsoft-customer-success-unit\/\",\"@type\":\"Person\",\"@name\":\"Microsoft Customer Success Unit\"}],\"headline\":\"Backup your data lake using Azure Data Factory \u2013 Metadata Copy activity\",\"datePublished\":\"2021-08-17T16:30:48+00:00\",\"dateModified\":\"2022-02-10T19:53:37+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/technetuk\/2021\/08\/17\/backup-your-data-lake-using-azure-data-factory-metadata-copy-activity\/\"},\"wordCount\":1852,\"commentCount\":0,\"publisher\":{\"@id\":\"https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/#organization\"},\"image\":{\"@id\":\"https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/technetuk\/2021\/08\/17\/backup-your-data-lake-using-azure-data-factory-metadata-copy-activity\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/wp-content\/uploads\/sites\/22\/2020\/03\/datafactorythumb.png\",\"keywords\":[\"Azure\",\"Data\",\"TechNet UK\"],\"articleSection\":[\"TechNet UK\"],\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/technetuk\/2021\/08\/17\/backup-your-data-lake-using-azure-data-factory-metadata-copy-activity\/#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/technetuk\/2021\/08\/17\/backup-your-data-lake-using-azure-data-factory-metadata-copy-activity\/\",\"url\":\"https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/technetuk\/2021\/08\/17\/backup-your-data-lake-using-azure-data-factory-metadata-copy-activity\/\",\"name\":\"Backup your data lake using Azure Data Factory \u2013 Metadata Copy activity - Microsoft Industry Blogs - United Kingdom\",\"isPartOf\":{\"@id\":\"https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/technetuk\/2021\/08\/17\/backup-your-data-lake-using-azure-data-factory-metadata-copy-activity\/#primaryimage\"},\"image\":{\"@id\":\"https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/technetuk\/2021\/08\/17\/backup-your-data-lake-using-azure-data-factory-metadata-copy-activity\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/wp-content\/uploads\/sites\/22\/2020\/03\/datafactorythumb.png\",\"datePublished\":\"2021-08-17T16:30:48+00:00\",\"dateModified\":\"2022-02-10T19:53:37+00:00\",\"breadcrumb\":{\"@id\":\"https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/technetuk\/2021\/08\/17\/backup-your-data-lake-using-azure-data-factory-metadata-copy-activity\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/technetuk\/2021\/08\/17\/backup-your-data-lake-using-azure-data-factory-metadata-copy-activity\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/technetuk\/2021\/08\/17\/backup-your-data-lake-using-azure-data-factory-metadata-copy-activity\/#primaryimage\",\"url\":\"https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/wp-content\/uploads\/sites\/22\/2020\/03\/datafactorythumb.png\",\"contentUrl\":\"https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/wp-content\/uploads\/sites\/22\/2020\/03\/datafactorythumb.png\",\"width\":800,\"height\":450,\"caption\":\"An illustration depicting Azure Data Factory, next to a picture of Bit the Raccoon.\"},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/technetuk\/2021\/08\/17\/backup-your-data-lake-using-azure-data-factory-metadata-copy-activity\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Backup your data lake using Azure Data Factory \u2013 Metadata Copy activity\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/#website\",\"url\":\"https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/\",\"name\":\"Microsoft Industry Blogs - United Kingdom\",\"description\":\"\",\"publisher\":{\"@id\":\"https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Organization\",\"@id\":\"https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/#organization\",\"name\":\"Microsoft Industry Blogs - United Kingdom\",\"url\":\"https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/#\/schema\/logo\/image\/\",\"url\":\"https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/wp-content\/uploads\/sites\/22\/2019\/08\/Microsoft-Logo.png\",\"contentUrl\":\"https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/wp-content\/uploads\/sites\/22\/2019\/08\/Microsoft-Logo.png\",\"width\":259,\"height\":194,\"caption\":\"Microsoft Industry Blogs - United Kingdom\"},\"image\":{\"@id\":\"https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/#\/schema\/logo\/image\/\"}}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"Backup your data lake using Azure Data Factory \u2013 Metadata Copy activity - Microsoft Industry Blogs - United Kingdom","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/technetuk\/2021\/08\/17\/backup-your-data-lake-using-azure-data-factory-metadata-copy-activity\/","og_locale":"en_US","og_type":"article","og_title":"Backup your data lake using Azure Data Factory \u2013 Metadata Copy activity - Microsoft Industry Blogs - United Kingdom","og_description":"In this blog post, we\u2019ll walk you through how to leverage ADF pipelines for full and incremental backups of your data lake on Azure.","og_url":"https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/technetuk\/2021\/08\/17\/backup-your-data-lake-using-azure-data-factory-metadata-copy-activity\/","og_site_name":"Microsoft Industry Blogs - United Kingdom","article_published_time":"2021-08-17T16:30:48+00:00","article_modified_time":"2022-02-10T19:53:37+00:00","og_image":[{"width":800,"height":450,"url":"https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/wp-content\/uploads\/sites\/22\/2020\/03\/datafactorythumb.png","type":"image\/png"}],"author":"Microsoft Customer Success Unit","twitter_card":"summary_large_image","twitter_misc":{"Written by":"Microsoft Customer Success Unit","Est. reading time":"8 min read"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/technetuk\/2021\/08\/17\/backup-your-data-lake-using-azure-data-factory-metadata-copy-activity\/#article","isPartOf":{"@id":"https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/technetuk\/2021\/08\/17\/backup-your-data-lake-using-azure-data-factory-metadata-copy-activity\/"},"author":[{"@id":"https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/author\/microsoft-customer-success-unit\/","@type":"Person","@name":"Microsoft Customer Success Unit"}],"headline":"Backup your data lake using Azure Data Factory \u2013 Metadata Copy activity","datePublished":"2021-08-17T16:30:48+00:00","dateModified":"2022-02-10T19:53:37+00:00","mainEntityOfPage":{"@id":"https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/technetuk\/2021\/08\/17\/backup-your-data-lake-using-azure-data-factory-metadata-copy-activity\/"},"wordCount":1852,"commentCount":0,"publisher":{"@id":"https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/#organization"},"image":{"@id":"https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/technetuk\/2021\/08\/17\/backup-your-data-lake-using-azure-data-factory-metadata-copy-activity\/#primaryimage"},"thumbnailUrl":"https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/wp-content\/uploads\/sites\/22\/2020\/03\/datafactorythumb.png","keywords":["Azure","Data","TechNet UK"],"articleSection":["TechNet UK"],"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/technetuk\/2021\/08\/17\/backup-your-data-lake-using-azure-data-factory-metadata-copy-activity\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/technetuk\/2021\/08\/17\/backup-your-data-lake-using-azure-data-factory-metadata-copy-activity\/","url":"https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/technetuk\/2021\/08\/17\/backup-your-data-lake-using-azure-data-factory-metadata-copy-activity\/","name":"Backup your data lake using Azure Data Factory \u2013 Metadata Copy activity - Microsoft Industry Blogs - United Kingdom","isPartOf":{"@id":"https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/#website"},"primaryImageOfPage":{"@id":"https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/technetuk\/2021\/08\/17\/backup-your-data-lake-using-azure-data-factory-metadata-copy-activity\/#primaryimage"},"image":{"@id":"https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/technetuk\/2021\/08\/17\/backup-your-data-lake-using-azure-data-factory-metadata-copy-activity\/#primaryimage"},"thumbnailUrl":"https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/wp-content\/uploads\/sites\/22\/2020\/03\/datafactorythumb.png","datePublished":"2021-08-17T16:30:48+00:00","dateModified":"2022-02-10T19:53:37+00:00","breadcrumb":{"@id":"https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/technetuk\/2021\/08\/17\/backup-your-data-lake-using-azure-data-factory-metadata-copy-activity\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/technetuk\/2021\/08\/17\/backup-your-data-lake-using-azure-data-factory-metadata-copy-activity\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/technetuk\/2021\/08\/17\/backup-your-data-lake-using-azure-data-factory-metadata-copy-activity\/#primaryimage","url":"https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/wp-content\/uploads\/sites\/22\/2020\/03\/datafactorythumb.png","contentUrl":"https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/wp-content\/uploads\/sites\/22\/2020\/03\/datafactorythumb.png","width":800,"height":450,"caption":"An illustration depicting Azure Data Factory, next to a picture of Bit the Raccoon."},{"@type":"BreadcrumbList","@id":"https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/technetuk\/2021\/08\/17\/backup-your-data-lake-using-azure-data-factory-metadata-copy-activity\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/"},{"@type":"ListItem","position":2,"name":"Backup your data lake using Azure Data Factory \u2013 Metadata Copy activity"}]},{"@type":"WebSite","@id":"https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/#website","url":"https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/","name":"Microsoft Industry Blogs - United Kingdom","description":"","publisher":{"@id":"https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Organization","@id":"https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/#organization","name":"Microsoft Industry Blogs - United Kingdom","url":"https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/","logo":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/#\/schema\/logo\/image\/","url":"https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/wp-content\/uploads\/sites\/22\/2019\/08\/Microsoft-Logo.png","contentUrl":"https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/wp-content\/uploads\/sites\/22\/2019\/08\/Microsoft-Logo.png","width":259,"height":194,"caption":"Microsoft Industry Blogs - United Kingdom"},"image":{"@id":"https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/#\/schema\/logo\/image\/"}}]}},"_links":{"self":[{"href":"https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/wp-json\/wp\/v2\/posts\/51555","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/wp-json\/wp\/v2\/users\/430"}],"replies":[{"embeddable":true,"href":"https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/wp-json\/wp\/v2\/comments?post=51555"}],"version-history":[{"count":0,"href":"https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/wp-json\/wp\/v2\/posts\/51555\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/wp-json\/wp\/v2\/media\/30924"}],"wp:attachment":[{"href":"https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/wp-json\/wp\/v2\/media?parent=51555"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/wp-json\/wp\/v2\/categories?post=51555"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/wp-json\/wp\/v2\/post_tag?post=51555"},{"taxonomy":"content-type","embeddable":true,"href":"https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/wp-json\/wp\/v2\/content-type?post=51555"},{"taxonomy":"author","embeddable":true,"href":"https:\/\/www.microsoft.com\/en-gb\/industry\/blog\/wp-json\/wp\/v2\/coauthors?post=51555"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}