TSSetTraceLevel function

The TSSetTraceLevel function sets the trace level of a trace class.

Syntax

TSSetTraceLevel(traceLevelSpec  lvarchar)
returns integer;
traceLevelSpec
A character string specifying the trace level for a specific trace class. The format is TS_VTI_DEBUG traceLevel.

Description

TSSetTraceLevel sets the trace level of a trace class. The trace level determines what information is recorded for a given trace class. The trace class for virtual table information is TS_VTI_DEBUG. The level to enable tracing for the TS_VTI_DEBUG trace class is 1001. You must set the tracing level to 1001 or greater to enable tracing. By default, the trace level is below 1001.

TSSetTraceLevel calls the mi_set_trace_level() DataBlade® API function. For more information about mi_set_trace_level(), see the HCL OneDB™ DataBlade API Programmer's Guide.

Returns

Returns 0 on success, -1 on failure.

Example

The following example turns tracing on:
execute function TSSetTraceLevel('TS_VTI_DEBUG 1001');