Reputation: 57
We have Azure SQL database , we need build data archival solution to manage data more than 2 years old.
Requirement:
Please recommend an azure solution to achieve this.
Upvotes: 5
Views: 4130
Reputation: 4544
Here are the approaches you can try:
bacpac
directly from Azure Portal. This bacpac
file will be stored in existing Azure Storage account. Once done, you can delete the data from database. Refer Export to a BACPAC file - Azure SQL Database.If you need to only archive 2 years of data, you can create a Stored Procedure for each table in your database. You can run that SP using Stored Procedure activity in Azure Data Factory.
The cheapest (free) option to store archive data is by creating bacpac
file and store it in local machine. Or else you can use Blob Storage cold storage service for archiving data.
To restore data from bacpac
, just simply import the bacpac file in your database. To restore from Blob Storage, update the container from cool to hot and use ADF to copy from that file into destination database.
If you are using SP activity in ADF as mentioned in point 1, you can trigger the ADF pipeline to run your SP weekly/monthly or whenever as per your requirement. Refer Schedule Trigger in ADF.
Upvotes: 4