共用方式為


JobServer.MsxDefect 方法 (Boolean)

Ends SQL Server Agent participation in a multiserver administration group with the option to force defection.

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

語法

'宣告
Public Sub MsxDefect ( _
    forceDefection As Boolean _
)
'用途
Dim instance As JobServer 
Dim forceDefection As Boolean

instance.MsxDefect(forceDefection)
public void MsxDefect(
    bool forceDefection
)
public:
void MsxDefect(
    bool forceDefection
)
member MsxDefect : 
        forceDefection:bool -> unit
public function MsxDefect(
    forceDefection : boolean
)

參數

  • forceDefection
    型別:System.Boolean
    A Boolean value that specifies whether to allow for a forceful removal of the target server when the master server connection has been permanently lost. If True, the forceful removal of the target server is allowed.If False, the removal of the target server is not forced.

備註

Use the forceDetection parameter with caution, because if the master server still has the target server registered, the target server must be manually removed from the master server.

範例

使用 SQL Server Agent 排程自動管理工作

請參閱

參考

JobServer 類別

MsxDefect 多載

Microsoft.SqlServer.Management.Smo.Agent 命名空間

其他資源

自動化管理工作 (SQL Server Agent)

sp_msx_defect (Transact-SQL)