共用方式為


CommandSent Event

未來的 Microsoft SQL Server 版本將移除這項功能。請避免在新的開發工作中使用這項功能,並規劃修改目前使用這項功能的應用程式。

The CommandSent event occurs when SQL Distributed Management Objects (SQL-DMO) submits a Transact-SQL command batch to the connected instance of Microsoft SQL Server.

語法

Private Subobject_CommandSent(SQLCommand as String)

Parts

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

  • SQLCommand
    String that contains the Transact-SQL command batch submitted.

Prototype (C/C++)

HRESULT CommandSent(SQLDMO_LPCSTR szSQL);

備註

The CommandSent event occurs only after the SQLServer object has connected successfully to an instance of SQL Server. SQL-DMO raises the event for every command batch sent, including Transact-SQL submitted for SQL-DMO processes such as collection enumeration and object property value determination.

Applies To: