Rational Developer for System z
Enterprise PL/I for z/OS, Version 3.8, Programming Guide

Using the SQL preprocessor with the compiler user exit (IBMUEXIT)

You can use the IBM supplied compiler user exit (IBMUEXIT) to suppress a message or to change the severity of a message. Because the SQL preprocess handles messages for both itself and the DB2 coprocessor, you need to be aware of the following information.

The SQL preprocessor generates messages in the range IBM7021 - IBM7999. A small subset of these messages, IBM7040, IBM7041, IBM7042, IBM7043 and IBM7044, are 'special' messages that relay message information that was returned from the DB2 coprocessor. These 'special' messages contain two message numbers; the SQL preprocessor assigned IBM704x number (x according to the severity of the DB2 message), and the DB2 message with the DB2 message text. You can not use the user exit to change or suppress this small subset of special SQL preprocessor messages because each of them is used for many separate and individual DB2 coprocessor messages. However, you can use the compiler user exit to change or suppress any of the other 'regular' SQL preprocessor messages.

Here are some examples of how you would change the severity of these two types of SQL preprocessor messages.

Let's consider a 'regular' SQL preprocessor message such as IBM7028 first:

IBM7028I W Reference var-name is ambiguous.

If you wished to change the severity of a 'regular' SQL preprocessor message like IBM7028 from 4 (warning) to 12 (severe) your modified SYSUEXIT DD card would look like this:

  Fac Id   Msg No   Severity   Suppress   Comment
+--------+--------+----------+----------+------------------------
  'SQL'     7028       12          0      Ambiguous reference

For more information on the fields and values of this example you can refer to Using user exits.

Next, let's consider one of the 'special' SQL preprocessor messages, IBM7041:

IBM7041I W     DSNH527I DSNHOPTS  THE PRECOMPILER ATTEMPTED TO USE
               THE DB2-SUPPLIED DSNHDECP MODULE

Notice that it contains two message numbers: 'IBM7041' is assigned by the SQL preprocessor and 'DSNH527' is assigned by the DB2 coprocessor. If you wished to change the severity of a 'special' SQL preprocessor message like IBM7021 from 4 (warning) to 12 (severe) your modified SYSUEXIT DD card would look like this:

  Fac Id   Msg No   Severity   Suppress   Comment
+--------+--------+----------+----------+------------------------
  'SQL'      527       12          0      DB2 coprocessor message

Notice that the Facility ID is the same for both kinds of SQL preprocessor messages. However, for the 'special' SQL preprocessor message you would use the message number provided by the DB2 coprocessor, in this case '527', as the message number you want to modify.


Terms of use | Feedback

This information center is powered by Eclipse technology. (http://www.eclipse.org)