We recommend using Visual Studio 2017

RestorePlan Class

Represents a sequence of Database Restore operations which will recover a database to a particular state in a point in time.


Namespace:  Microsoft.SqlServer.Management.Smo
Assembly:  Microsoft.SqlServer.SmoExtended (in Microsoft.SqlServer.SmoExtended.dll)

public class RestorePlan

The RestorePlan type exposes the following members.

Public methodRestorePlan(Database)Initializes a new instance of the RestorePlan class with specified database.
Public methodRestorePlan(Server)Initializes a new instance of the RestorePlan class with specified server.
Public methodRestorePlan(Server, String)Initializes a new instance of the RestorePlan class with specified server and database name.

Public propertyAsyncStatusGets the status of most recent asynchronous operation including possible errors.
Public propertyCloseExistingConnectionsGets or sets a value indicating whether to close existing connections.
Public propertyDatabaseNameGets or sets the name of the database.
Public propertyRestoreActionGets and sets the type of the Restore action: Database,File,Log,Page.
Public propertyRestoreOperationsGets or sets the restore operations.
Public propertyServerGets or sets the erver where the Restore plan executes.
Public propertyTailLogBackupOperationGets or sets the tail log backup operation.

Public methodAddRestoreOperation(BackupSet)Adds the restore operation with specified backup set to be restored.
Public methodAddRestoreOperation(List<BackupSet>)Adds the restore operations with specified backup sets..
Public methodEquals (Inherited from Object.)
Public methodExecuteVerifies and executes the Restore Plan.
Public methodExecuteAsyncVerifies and executes the Restore Plan async.
Protected methodFinalize (Inherited from Object.)
Public methodGetHashCode (Inherited from Object.)
Public methodGetType (Inherited from Object.)
Protected methodMemberwiseClone (Inherited from Object.)
Public methodScriptVerifies the Restore plan and scripts the operation.
Public methodSetRestoreOptionsSets the restore options.
Public methodToString (Inherited from Object.)
Public methodVerifyVerifies the restore plan.

Public eventCompleteOccurs when the restore plan is completed.
Public eventInformationOccurs when the server sends information.
Public eventNextMediaOccurs when the next media needs to be loaded.
Public eventNextRestoreOccurs when the next restore occurs.
Public eventPercentCompleteOccurs when the server sends percent complete information.

Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.