xSession.setSysTraceActive(Boolean) Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Switches system tracing on or off.
public:
static void setSysTraceActive(bool _nValue);
public static void setSysTraceActive (bool _nValue);
static member setSysTraceActive : bool -> unit
Public Shared Sub setSysTraceActive (_nValue As Boolean)
Parameters
- _nValue
- Boolean
A Boolean value that determines whether tracing should be switched on or off. Set to true to switch tracing on.
Remarks
The following example uses the setSysTraceActive method to turn system tracing off when data is imported.
server static void main(Args a)
{
SysDataImport sysDataImport;
boolean sysTraceActive = xSession::getSysTraceActive();
sysDataImport = SysDataImport::newTmpFilename('');
sysDataImport.addTmpExpImpTable(
tablenum(SysTraceTableSQL),
false);
sysDataImport.addTmpExpImpTable(
tablenum(SysTraceTableSQLExecPlan),
false);
sysDataImport.addTmpExpImpTable(
tablenum(SysTraceTableSQLTabRef),
false);
xSession::setSysTraceActive(FALSE);
if (sysDataImport.prompt())
sysDataImport.run();
xSession::setSysTraceActive(sysTraceActive);
}