共用方式為


ServiceMasterKey.Recover 方法

Recovers a service master key, in case the service master key has been changed external to SQL Server.

命名空間:  Microsoft.SqlServer.Management.Smo
組件:  Microsoft.SqlServer.Smo (在 Microsoft.SqlServer.Smo.dll 中)

語法

'宣告
Public Sub Recover ( _
    oldAccount As String, _
    oldPassword As String _
)
'用途
Dim instance As ServiceMasterKey 
Dim oldAccount As String 
Dim oldPassword As String

instance.Recover(oldAccount, oldPassword)
public void Recover(
    string oldAccount,
    string oldPassword
)
public:
void Recover(
    String^ oldAccount, 
    String^ oldPassword
)
member Recover : 
        oldAccount:string * 
        oldPassword:string -> unit
public function Recover(
    oldAccount : String, 
    oldPassword : String
)

參數

  • oldAccount
    型別:System.String
    A String value that specifies the old account that was used to open the service master key.
  • oldPassword
    型別:System.String
    A String value that specifies the associated password for the account that was used to open the service master key.

範例

使用加密

請參閱

參考

ServiceMasterKey 類別

Microsoft.SqlServer.Management.Smo 命名空間

其他資源

加密階層

ALTER SERVICE MASTER KEY (Transact-SQL)