How to export the data from an Azure SQL database to blob storage . I have tried some commands but getting error . could someone help on t

Seelan, Sathiya 60 Reputation points
2024-04-04T11:41:19.1933333+00:00

User's image

Azure SQL Database
Azure Blob Storage
Azure Blob Storage
An Azure service that stores unstructured data in the cloud as blobs.
3,192 questions
Azure
Azure
A cloud computing platform and infrastructure for building, deploying and managing applications and services through a worldwide network of Microsoft-managed datacenters.
1,409 questions
{count} votes

Accepted answer
  1. Olaf Helper 47,436 Reputation points
    2024-04-04T11:45:16.67+00:00

    BCP is an older tool and don't support a direct export to Azure storage.

    You have to export the data first local and transfer it then to Azure.

    See https://learn.microsoft.com/en-us/sql/tools/bcp-utility?view=sql-server-ver16 => data_file

    0 comments No comments

1 additional answer

Sort by: Most helpful
  1. RahulRandive 10,486 Reputation points Volunteer Moderator
    2024-04-04T11:49:40.9233333+00:00

    Hi @Seelan, Sathiya

    You can export using SSMS if the size is below 200 GB. If its above, use SQLPackage, details below

    1. If you have SSMS installed in your machine, connect to database using SSMS
    2. Go to database, right click -> Task ->Export Data tier application ->
    3. Select storage account, container and file name, click next and then Export.

    User's image

    Or you can use SQLPackage to import or export SQL Server and Azure SQL DB

    Here is the details blog- https://techcommunity.microsoft.com/t5/azure-database-support-blog/using-sqlpackage-to-import-or-export-sql-server-and-azure-sql-db/ba-p/368861

    Thank You!

    0 comments No comments

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.