IBM i Application Programming Reference (ILE/RPG)

Application programming for IBM i.

Use this information to help you develop applications for IBM i.


Deprecation of compatibility mode for RPG and COBOL applications on IBM i

From Version 9.0, IBM MQ no longer provides support for RPG or COBOL applications that use dynamic linkage known as compatibility mode. This mode of operation was needed for applications that are written before MQSeries Version 5.1, and subsequent versions of the product provided a compatible runtime environment for these applications, even though the copybooks needed for compiling them were removed in IBM WebSphere MQ Version 6.0. Dynamic linkage (compatibility mode) was provided by the following programs in library QMQM, which are removed at IBM MQ Version 9.0:

From Version 9.0, applications that use this compatibility mode of operation need to be recompiled to use the static bound MQ calls that are provided by the LIBMQM and LIBMQM_R service programs. Sample programs, such as AMQ3PUT4 and AMQ3GET4, show you how to use this programming model. For more information about using these MQ calls, see IBM i Application Programming Reference (ILE/RPG).Notes:

  • We need to recode applications, currently using the CALL 'QMQM' interface, to use the LIBMQM service program instead.

    The program objects and service programs in the preceding list, for example, QMQM, MQCONN, MQPUT, AMQVSTUB, and AMQZSTUB, are removed in Version 9.0, and applications that were coded to use compatibility mode cease to work.

  • If applications are bound to the LIBMQM service program at Version 8.0, we should not need to recompile or relink those applications at Version 9.0 or later.
  • It is not possible to install more than one version of IBM MQ for IBM i on the same partition.

To find out whether your RPG or COBOL program uses compatibility mode, use the DSPPGMREF (Display Program References) command to display the external programs called by the application program. If there are references to the programs listed in this section, the program will not run at Version 9.0 or later. The following example of DSPPGMREF output shows three program objects that are deprecated, MQCONN, MQOPEN, MQCLOSE:

Program . . . . . . . . . . . . . . . . . . . :  MYAPPPGM
Library . . . . . . . . . . . . . . . . . . :    MYLIB
Text 'description'. . . . . . . . . . . . . :     ILE/COBOL SAMPLE PUT TO QUEUE (MQPUT)
Number of objects referenced  . . . . . . . :        5
Object  . . . . . . . . . . . . . . . . . . :    MQCONN
Library . . . . . . . . . . . . . . . . . :      *LIBL 
Object type . . . . . . . . . . . . . . . :        *PGM
Object  . . . . . . . . . . . . . . . . . . :    MQOPEN
Library . . . . . . . . . . . . . . . . . :      *LIBL 
Object type . . . . . . . . . . . . . . . :        *PGM
Object  . . . . . . . . . . . . . . . . . . :    MQCLOSE
Library . . . . . . . . . . . . . . . . . :      *LIBL 
Object type . . . . . . . . . . . . . . . :        *PGM                     
Such programs must be recompiled using the Bound Procedural Call method described in Preparing COBOL programs in IBM i.

If you attempt to run an application program at Version 9.0 or later that uses compatibility mode, the most commonly seen first error is an MCH3401 trying to call program MQCONN or QMQM.

Parent topic: Developing applications reference


Related information