Interoperability with older levels of IBM COBOL programs

There are some restrictions for Enterprise COBOL 5 and 6 programs to call or be called by (interoperate with) programs compiled with earlier versions of COBOL.

Enterprise COBOL 5 and 6 programs interoperability

Enterprise COBOL 5 and 6 programs cannot interoperate with OS/VS COBOL or VS COBOL II NORES programs in a single application. A COBOL run unit (Language Environment® enclave) that contains an Enterprise COBOL 5 or 6 compiled program must not contain any OS/VS COBOL or VS COBOL II NORES programs.

Note: Run units that contain only COBOL programs compiled with Enterprise COBOL V4 or earlier versions can interoperate with OS/VS COBOL and VS COBOL II NORES programs.
Programs compiled with Enterprise COBOL 5 or 6 can interoperate with programs compiled with VS COBOL II or later, based on the following conditions and CALL types:
  • Static calls. Enterprise COBOL 5 or 6 compiled programs can be bound (link-edited) with the following object modules or programs to form a single program object. The programs within the program object can specify static calls to and from each other.
    • Programs that are compiled with VS COBOL II with the RES compiler option
    • Programs that are compiled with any IBM® COBOL compiler versions subsequent to VS COBOL II
    • Programs that are compiled with Enterprise COBOL V3 or V4
    Note: Programs that were compiled with VS COBOL II with the NORES compiler option in effect cannot interoperate with programs compiled with Enterprise COBOL 5 or 6.
  • Dynamic calls. Program modules that contain programs compiled with VS COBOL II with the RES option, or subsequent versions of COBOL can also interoperate with Enterprise COBOL 5 or 6 program objects by using dynamic CALL statements.
  • DLL calls. Program modules that are compiled with earlier versions of COBOL that supported DLL linkage can interoperate with Enterprise COBOL 5 or 6 program objects by using DLL linkage.

How to find if you have OS/VS COBOL programs

To find if you have OS/VS COBOL programs, you can:
  • Use IBM COBOL Upgrade Advisor for z/OS® to run an inventory scan to discover what compiler versions are used in your load libraries or applications.
  • Enable Language Environment to put out a message whenever an OS/VS COBOL program is run. To enable this warning message, set up IGZUOPT.

    The following is an example of the embedded HLASM code inside the JCL:

    IGZUOPT CSECT
    IGZUOPT AMODE 31
    IGZUOPT RMODE ANY
    *
      IGZXOPT SUPP_OSV=ON * ON: Suppress warning
           * ONCE: Only issue 1 warning
           * OFF: issue warning 
    END