0

So I was using Microsoft Azure trial version and I made SQL server and database. I made a backup and got .bacpac file exported. I've just logged in and saw that I lost my database because my free trial expired. Can I somehow still open database using .bacpac file? I sent an email to their support, but still waiting for the response.

1 Answers1

0

Of course. From the docs:

$importRequest = New-AzureRmSqlDatabaseImport 
   -ResourceGroupName "<your_resource_group>" `
   -ServerName "<your_server>" `
   -DatabaseName "<your_database>" `
   -DatabaseMaxSizeBytes "<database_size_in_bytes>" `
   -StorageKeyType "StorageAccessKey" `
   -StorageKey $(Get-AzureRmStorageAccountKey -ResourceGroupName "<your_resource_group>" -StorageAccountName "<your_storage_account").Value[0] `
   -StorageUri "https://myStorageAccount.blob.core.windows.net/importsample/sample.bacpac" `
   -Edition "Standard" `
   -ServiceObjectiveName "P6" `
   -AdministratorLogin "<your_server_admin_account_user_id>" `
   -AdministratorLoginPassword $(ConvertTo-SecureString -String "<your_server_admin_account_password>" -AsPlainText -Force)
Murray Foxcroft
  • 12,785
  • 7
  • 58
  • 86