EnumMiscellaneousAgentViews Method (SQL-DMO)

The EnumMiscellaneousAgentViews method returns a QueryResults object enumerating historical data for all replication agents not otherwise classified.

Applies To

Distributor Object

Syntax

object.EnumMiscellaneousAgentViews() as QueryResults

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

Returns

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.

Remarks

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.

Prototype (C/C++)

HRESULT EnumMiscellaneousAgentViews(
LPSQLDMOQUERYRESULTS* ppResults);

  


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