Previous Topic Next topic Print topic


DB2 Compiler Directive

You can specify the DB2 Compiler directive anywhere where you can specify any other Compiler directive. For example:

Note: You cannot specify the DB2 directive more than once, so must only specify it in one of the possible places.

Compiler directives have a default value which is used if no other value is specified. This also applies to all existing DB2 directive options. Many of the options are passed straight to DB2 at compilation time and the Compiler default is used when no other value is specified. In these cases, however, the suitability of, and default values for these options is dependent on the DB2 configuration, notably whether it is connected to a DRDA server via DDCS. Because of this, the default Compiler setting of these options is "not set". This means that no value is passed to DB2 and the default value (if applicable) is determined by DB2 itself. Consult your IBM DB2 reference documentation for these values.

Note: This list assumes that you are using DB2 LUW V9.7 or later . Some directives are only valid when using DB2 Connect with DB2 LUW. If you are using a different version of DB2 LUW, consult your IBM DB2 reference documentation under PRECOMPILE or BIND to see if the DB2 directive option is supported locally (DB2) or only by DB2 Connect (DRDA). If you are in any doubt, you can specify the directive and attempt to compile the program. If it is not supported, an error message will be issued.
Previous Topic Next topic Print topic