Command Property (SQL-DMO)

The Command property specifies the task of a job step.

Applies To

JobStep Object

Syntax

object.Command [= value]

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

Remarks

The Command property specifies the execution string for SQL Server Agent. Failure or success of execution determines failure or success of the job step.

The text specified by the Command property is run by SQL Server Agent using the executable subsystem indicated by the JobStep object Subsystem property. Job step subsystem selection determines valid syntax for Command Property text.

Data Type

String

Modifiable

Read/write

Prototype (C/C++)

HRESULT GetCommand(SQLDMO_LPBSTR pRetVal);

HRESULT SetCommand(SQLDMO_LPCSTR NewValue);


Note SQL-DMO strings are always returned as OLE BSTR objects. A C/C++ application obtains a reference to the string. The application must release the reference by using SysFreeString.


See Also

SubSystem Property

  


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