Upgrading Enterprise COBOL Version 3 programs that have XML PARSE statements

Refer to this information for upgrading Enterprise COBOL Version 3 programs that have XML PARSE statements.

Enterprise COBOL Version 4 introduced new XML PARSE support compared to Enterprise COBOL Version 3. In particular, the z/OS® System Services XML parser was supported as the default alternative to the XML parser that is part of the COBOL runtime library. In 5 and 6, you can choose between the COBOL runtime library parser and the XML System Services parsers.

Originally, Enterprise COBOL V5.1 did not have an XMLPARSE compiler option and required the XMLSS parser. However, with current service applied, V5.1 is the same as V5.2 in this area, and both have the XMLPARSE compiler option so that you can choose the same parser in 5 and 6 that you used with earlier versions of Enterprise COBOL.
  • XMLPARSE(COMPAT) specifies that the compiled code will use the COBOL runtime library parser.

    In most cases, you do not have to change your Enterprise COBOL Version 3 programs that have XML PARSE statements to upgrade to Enterprise COBOL 5 or 6. You can have the compatible behavior by specifying the XMLPARSE(COMPAT) compiler option. However, the COMPAT XML parser implementation in Enterprise COBOL V5.2 and later is different in rare cases from that in Version 3. The change does not affect most existing programs, but you should review the unusual cases where the differences could occur. For details, see COMPAT XML parser considerations.

  • XMLPARSE(XMLSS) specifies that the compiled code will use the z/OS System Services XML parser.

    You must change your Enterprise COBOL Version 3 programs that use XML PARSE statements if you want to change to use XMLPARSE(XMLSS).

    The z/OS System Services XML parser provides the following benefits:
    • The latest IBM® parsing technology
    • Offload of COBOL XML parsing to zAAP specialty processors
    • Improved support for parsing XML documents that use XML namespaces
    • Direct support for parsing XML documents encoded in UTF-8 Unicode
    • Support for parsing large XML documents, a buffer at a time

    To optionally modify your Enterprise COBOL Version 3 programs to use XMLPARSE(XMLSS) with Enterprise COBOL 5 or 6, change the programs to reflect the new, changed, and discontinued XML parsing events. For details, see Migrating from XMLPARSE(COMPAT) to XMLPARSE(XMLSS).