The EnumMiscellaneousAgentViews method returns a QueryResults object enumerating historical data for all replication agents not otherwise classified.
object.EnumMiscellaneousAgentViews() as QueryResults
| Part | Description |
|---|---|
| object | Expression that evaluates to an object in the Applies To list |
A QueryResults object containing one result set defined by these columns.
| Column | Data type | Description |
|---|---|---|
| name | nvarchar(129) | Name of the agent. |
| agent_type | nvarchar(129) | Descriptive text. |
| status | integer | Agent status. Interpret by using SQLDMO_TASKSTATUS_TYPE. |
| message | nvarchar(1025) | Descriptive text. |
| start_time | nvarchar(22) | Date and time of most recent scheduled execution. |
| run_duration | integer | Cumulative run time. |
| job_id | binary(22) | System-assigned, unique identifier of the SQL Server Agent job responsible for launching the agent. |
| local_timestamp | binary(14) | Timestamp. |
Use the EnumMiscellaneousAgentViews method to monitor replication agent sessions.
In the result set, date and time data returned in start_time is formatted as YYYYMMDD hh:mm:ss.fff where: YYYY represents the year in four digits; MM represents the month in two digits (zero padded); DD represents the day of the month in two digits; hh represents the hour using two digits, a twenty-four hour clock and zero padding; mm represents the minute in two digits (zero padded); ss represents the second in two digits (zero padded); and fff represents the fractional part of the second in three digits.
HRESULT EnumMiscellaneousAgentViews(
LPSQLDMOQUERYRESULTS* ppResults);