CURRENT APPLICATION COMPATIBILITY special register
CURRENT APPLICATION COMPATIBILITY specifies the application compatibility level support for dynamic SQL statements in packages.
The data type is VARCHAR(10).
Set the value with the SET CURRENT APPLICATION COMPATIBILITY statement.
The abbreviation APPLCOMPAT can be used instead of spelling out APPLICATION COMPATIBILITY when setting or referencing this special register in SQL statements.
For packages, the initial value is determined by the value of the APPLCOMPAT bind option. For a user-defined functions or stored procedures, the initial value is inherited according to the rules in Special registers in a user-defined function or a stored procedure. For advanced triggers, the initial value is V12R1.
The following CURRENT APPLICATION COMPATIBILITY values are supported to specify the application compatibility behavior of dynamic SQL statements:
VvvRrMmmm
-
Compatibility with the behavior of the identified Db2 function level. For example,
V13R1M506
specifies compatibility with the highest available Db2 13 function level. The equivalent function level or higher must be activated.For the new capabilities that become available in each application compatibility level, see:
- SQL changes in Db2 13 application compatibility levels
- SQL changes in Db2 12 application compatibility levels
Tip:Extra program preparation steps might be required to increase the application compatibility level for applications that use data server clients or drivers to access Db2 for z/OS®. For more information, see Setting application compatibility levels for data server clients and drivers.
- V12R1
- Compatibility with the behavior of Db2 12 function level 500. This value has the same result as specifying
V12R1M500
. - V11R1
- Compatibility with the behavior of Db2 11 new-function mode.
- V10R1
- Compatibility with the behavior of DB2® 10 new-function mode. For more information, see V10R1 application compatibility level.
Example
The following statement sets the host variable CS to the compatibility level.
EXEC SQL SET :CS = CURRENT APPLICATION COMPATIBILITY;