Condividi tramite


RemoveAllJobSteps Method

Questa funzionalità verrà rimossa in una delle prossime versioni di Microsoft SQL Server. Evitare di utilizzare questa funzionalità in un nuovo progetto di sviluppo e prevedere interventi di modifica nelle applicazioni in cui è attualmente implementata.

The RemoveAllJobSteps method removes all system records maintaining steps executed by the referenced SQL Server Agent job.

Sintassi

object
.RemoveAllJobSteps(
)

Parts

  • object
    Expression that evaluates to an object in the Applies To list.

Prototype (C/C++)

HRESULT RemoveAllJobSteps();

Osservazioni

A SQL Server Agent job is enabled once it has at least one step and an execution target. Successful execution of the RemoveAllJobSteps method disables the referenced SQL Server Agent job, and SQL Distributed Management Objects (SQL-DMO) empties the JobSteps collection of the Job object used. To re-enable the referenced job using SQL-DMO, create JobStep objects and add them to the JobSteps collection of the Job object. For more information, see JobStep Object.

Applies To:

Job Object