SET CURRENT DEBUG MODE statement
The SET CURRENT DEBUG MODE statement assigns a value to the CURRENT DEBUG MODE special register.
The special register sets the default value for the DEBUG MODE option for the following statements:
- CREATE FUNCTION statements that define an SQL scalar function
- ALTER FUNCTION statements that create or replace a version of an SQL scalar function
- CREATE PROCEDURE statements that define a native SQL or Java™ procedure
- ALTER PROCEDURE statements that create or replace a version of a native SQL procedure
- CREATE TRIGGER (advanced) statement that defines a trigger
- ALTER TRIGGER (advanced) statement that changes a trigger
Invocation for SET CURRENT DEBUG MODE
This statement can be embedded in an application program or issued interactively. It is an executable statement that can be dynamically prepared.
Authorization for SET CURRENT DEBUG MODE
None required.
Syntax for SET CURRENT DEBUG MODE
Description for SET CURRENT DEBUG MODE
- host-variable
- Specifies a host variable that contains the debugging option.
The host variable must conform to the following rules:
- Be a CHAR, VARCHAR, GRAPHIC, or VARGRAPHIC variable. The actual length of the contents of the host variable must not exceed the length of the special register.
- Include a keyword value of DISALLOW, ALLOW, or DISABLE that is left justified
- Be padded on the right with blanks if the host variable is a fixed length character
- Not contain lowercase letters or characters that cannot be specified in an ordinary identifier
- Not be empty or contain only blanks
- Not be the null value
- DISALLOW
- Specifies that DISALLOW DEBUG MODE is the default option for CREATE statements when defining an SQL scalar function, native SQL procedure, Java procedure, or trigger, ALTER statements that create or replace a version of an SQL scalar function or native SQL procedure, or ALTER statements that change a trigger.
- ALLOW
- Specifies that ALLOW DEBUG MODE is the default option for CREATE statements when defining an SQL scalar function, native SQL procedure, Java procedure, or trigger, ALTER statements that create or replace a version of an SQL scalar function or native SQL procedure, or ALTER statements that change a trigger.
- DISABLE
- Specifies that DISABLE DEBUG MODE is the default option for CREATE statements when defining an SQL scalar function, native SQL procedure, Java procedure, or trigger, ALTER statements that add a version of an SQL scalar function or native SQL procedure, or ALTER statements that change a trigger.
Examples for SET CURRENT DEBUG MODE
Example: The
following statement sets the CURRENT DEBUG MODE special register so
that the default option for CREATE PROCEDURE statements will be ALLOW
DEBUG MODE:
SET CURRENT DEBUG MODE = ALLOW;