Skip to Content
Learning Microsoft Azure Storage
book

Learning Microsoft Azure Storage

by Mohamed Waly
November 2017
Intermediate to advanced
276 pages
7h 6m
English
Packt Publishing
Content preview from Learning Microsoft Azure Storage

Restoring a deleted database using PowerShell

Using the same method that we used to restore a point-in-time database, a deleted database is restored with only a few minor changes, as shown in the following cmdlets:

$DeletedDatabase = Get-AzureRmSqlDeletedDatabaseBackup -ResourceGroupName PacktPub -ServerName packtpubsqlps -DatabaseName PacktPubDBPS$Date = Get-Date – Date “The date you want to restore to”$Date = $Date.ToUniversalTime()Restore-AzureRmSqlDatabase -FromDeletedDatabaseBackup -DeletionDate $DeletedDatabase.DeletionDate -ResourceGroupName $DeletedDatabase.ResourceGroupName -ServerName packtpubsqlps -TargetDatabaseName "RestoredDatabase-Deleted" -ResourceId $DeletedDatabase.ResourceID -ServiceObjectiveName "S3" -PointInTime $Date ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

Microsoft Azure Storage - The Complete Guide

Microsoft Azure Storage - The Complete Guide

Vijay Saini
Learning Microsoft Azure

Learning Microsoft Azure

Jonah Carrio Andersson

Publisher Resources

ISBN: 9781785884917Other