Status Property (TargetServer) (SQL-DMO)

The Status property returns component execution or integrity state information.

Applies To

TargetServer Object

Syntax

object.Status

Part Description
object Expression that evaluates to an object in the Applies To list

Returns

The Status property is returned as a bit-packed long. One or more of the following values can be returned.

Constant Value Description
SQLDMOTargetServerStatus_Blocked 4 Server running Microsoft® SQL Server™ is visible. SQL Server Agent is blocked.
SQLDMOTargetServerStatus_Normal 1 Server running SQL Server is visible. SQL Server Agent is known to be running.
SQLDMOTargetServerStatus_
SuspectedOffline
2 Server running SQL Server is visible. SQL Server Agent execution state cannot be determined.
SQLDMOTargetServerStatus_
Unknown
0 Network error prevents determination of referenced server and SQL Server Agent state.

Data Type

Long

Modifiable

Read-only

Prototype (C/C++)

HRESULT GetStatus(LPLONG pRetVal);

  


(c) 1988-98 Microsoft Corporation. All Rights Reserved.