informix
Informix DataBlade API Programmer's Manual
DataBlade API Function Descriptions

mi_tracelevel_set()

The mi_tracelevel_set() function sets the trace level for specified trace classes.

Syntax

Usage

The mi_tracelevel_set() function sets the tracing levels for the trace classes that you specify in the set_commands argument. This argument specifies trace classes and their associated trace levels in the following format:

The following example sets the current trace level of trace class funcEntry to 50 and the level for trace class outData to 35:

Important: A trace-class name must be defined in the systraceclasses system catalog table before you run mi_tracelevel_set().

By default, tracing is off; that is, the current trace level is set to zero (0) for all trace classes. Any nonzero value for a trace level turns tracing on for the specified trace class. A trace level can be any integer from zero (0) to the maximum long integer value for the development platform.

If the trace level for the funcEntry trace class was currently 50, the following tracepoint would execute, because the value (10) in the argument to DPRINT is not greater than the current level (50) of funcEntry:

The trace message from this DPRINTF call would be written to the current trace-output file. For information on how to set the trace-output file, see the description of the mi_tracefile_set() function.

Return Values

MI_OK indicates that the function was successful.
MI_ERROR indicates that the function was not successful.

Related Topics

See the description of the mi_tracefile_set() function.

For more information, see Turning Tracing On.


Informix DataBlade API Programmer's Manual, Version 9.2
Copyright © 1999, Informix Software, Inc. All rights reserved