Server.Restore メソッド (String, String, Boolean, array<RestoreLocation , RestoreSecurity, String)

パスワード、上書きフラグ、複数のリモート サーバー、およびセキュリティ設定を指定して、Analysis Services データベースをバックアップ ファイルから指定したデータベースに復元します。

名前空間:  Microsoft.AnalysisServices
アセンブリ:  Microsoft.AnalysisServices (Microsoft.AnalysisServices.dll)

構文

'宣言
Public Sub Restore ( _
    file As String, _
    databaseName As String, _
    allowOverwrite As Boolean, _
    locations As RestoreLocation(), _
    security As RestoreSecurity, _
    password As String _
)
'使用
Dim instance As Server 
Dim file As String 
Dim databaseName As String 
Dim allowOverwrite As Boolean 
Dim locations As RestoreLocation()
Dim security As RestoreSecurity 
Dim password As String

instance.Restore(file, databaseName, allowOverwrite, _
    locations, security, password)
public void Restore(
    string file,
    string databaseName,
    bool allowOverwrite,
    RestoreLocation[] locations,
    RestoreSecurity security,
    string password
)
public:
void Restore(
    String^ file, 
    String^ databaseName, 
    bool allowOverwrite, 
    array<RestoreLocation^>^ locations, 
    RestoreSecurity security, 
    String^ password
)
member Restore : 
        file:string * 
        databaseName:string * 
        allowOverwrite:bool * 
        locations:RestoreLocation[] * 
        security:RestoreSecurity * 
        password:string -> unit
public function Restore(
    file : String, 
    databaseName : String, 
    allowOverwrite : boolean, 
    locations : RestoreLocation[], 
    security : RestoreSecurity, 
    password : String
)

パラメーター

  • file
    型: System.String
    復元するファイルの名前と格納場所です。
  • databaseName
    型: System.String
    復元先のデータベースです。
  • allowOverwrite
    型: System.Boolean
    データベースが存在するときに上書きするように指定する場合は true、それ以外の場合は false です。
  • password
    型: System.String
    復元ファイルを復号化するために使用するパスワードです。

説明

セキュリティに関する注意セキュリティに関する注意

バックアップ ファイルごとに、バックアップ コマンドを実行するユーザーは、各ファイルに指定されたバックアップ場所から読み取る権限を持っている必要があります。 サーバーにインストールされていない Analysis Services データベースを復元する場合、ユーザーは、その Analysis Services インスタンスのサーバー ロールのメンバーであることも必要です。 Analysis Services データベースを上書きするには、ユーザーは、Analysis Services インスタンスのサーバー ロールのメンバーか、復元するデータベースに対してフル コントロール (管理者) 権限を持つデータベース ロールのメンバーのいずれかである必要があります。

注意

既存のデータベースを復元すると、データベースを復元したユーザーは、復元されたデータベースにアクセスできなくなる可能性があります。 バックアップの実行時に、ユーザーがサーバー ロールのメンバー、またはフル コントロール (管理者) 権限を持つデータベース ロールのメンバーではなかった場合、このようにアクセスできなくなることがあります。

関連項目

参照

Server クラス

Restore オーバーロード

Microsoft.AnalysisServices 名前空間