Click here to view and discuss this page in DocCommentXchange. In the future, you will be sent there automatically.

SQL Anywhere 17 » SQL Anywhere Server - SQL Reference » SQL statements » Alphabetical list of SQL statements

NOTIFY TRACE EVENT statement

Logs a user-defined trace event to a trace session.

Syntax
NOTIFY TRACE EVENT trace-event-name ( [ param1 [ ,... ] ] )
Parameters
  • trace-event-name

    The trace event name must be the name of a user-defined trace event. It cannot be a system-defined trace event.

  • param1

    The values of the trace event fields.

Remarks

This statement is used to notify any sessions that include the specified trace event. If a trace event is not being traced by any session, then this statement has no effect and the parameters are not evaluated (for example, by a call to a user-defined function).

System privileges

You must have the NOTIFY TRACE EVENT system privilege.

Side effects

None

Standards
  • ANSI/ISO SQL Standard

    Not in the standard.

Example

The following statements log events to the current (fictitious) event trace session, my_event.

NOTIFY TRACE EVENT my_event( 1, 'Hello world' ); -- trigger user-defined trace events
NOTIFY TRACE EVENT my_event( 2, 'Hello world 2' );
NOTIFY TRACE EVENT my_event( 3, 'Hello world 3' );