IBM Support

PH42230: FUNCTION FORMATTED-TIME incorrectly calculates time for Zulu time formats when a UTC offset is specified

A fix is available

Subscribe

You can track all active APARs for this component.

 

APAR status

  • Closed as program error.

Error description

  • When using one of the Zulu formats like "hhmmssZ" to format
    local time as the equivalent UTC time, FUNCTION FORMATTED-TIME
    adds the argument-3 UTC offset to the local time instead of
    subtracting it.
    
    (Unlike TZ usage, the UTC offset is positive east of the prime
    meridian, and negative west of it.)
    

Local fix

Problem summary

  • ****************************************************************
    * USERS AFFECTED: Users of Enterprise COBOL 6.3 and later      *
    *                 releases running programs that use           *
    *                 the FORMATTED-TIME intrinsic function.       *
    ****************************************************************
    * PROBLEM DESCRIPTION: FORMATTED-TIME with a UTC offset value  *
    *                      (argument-3) calculates UTC time        *
    *                      incorrectly.                            *
    ****************************************************************
    * RECOMMENDATION: Install the provided PTF.                    *
    ****************************************************************
    There is a logic error in the FORMATTED-TIME with a UTF offset
    value (argument-3) when calculating the UTC time. It currently
    adds the UTC offset to a time. The UTC offset should
    be subtracted.
    
    COB0603T/K
    

Problem conclusion

  • The error in the COBOL runtime library FORMATTED-TIME routine
    has been corrected.
    

Temporary fix

Comments

APAR Information

  • APAR number

    PH42230

  • Reported component name

    LE ENT COBOL LI

  • Reported component ID

    568819812

  • Reported release

    7D0

  • Status

    CLOSED PER

  • PE

    NoPE

  • HIPER

    NoHIPER

  • Special Attention

    NoSpecatt / Xsystem

  • Submitted date

    2021-11-19

  • Closed date

    2021-12-09

  • Last modified date

    2022-01-04

  • APAR is sysrouted FROM one or more of the following:

  • APAR is sysrouted TO one or more of the following:

    UI78474 UI78475 UI78476

Modules/Macros

  • IGZCEV4  IGZCMGEN IGZCMGUE IGZLLIBV IGZXAPI  IGZXCA31 IGZXCDA
    IGZXD24  IGZXDMR  IGZXJNI2 IGZXLPIO IGZXLPKA IGZXLPKB IGZXLPKC
    IGZXLPKD IGZXLPKE IGZXLPKF IGZXLPKG IGZXPK2
    

Fix information

  • Fixed component name

    LE ENT COBOL LI

  • Fixed component ID

    568819812

Applicable component levels

  • R7B0 PSY UI78474

       UP21/12/15 P F112

  • R7C0 PSY UI78475

       UP21/12/15 P F112

  • R7D0 PSY UI78476

       UP21/12/15 P F112

Fix is available

  • Select the PTF appropriate for your component level. You will be required to sign in. Distribution on physical media is not available in all countries.

[{"Line of Business":{"code":"LOB35","label":"Mainframe SW"},"Business Unit":{"code":"BU058","label":"IBM Infrastructure w\/TPS"},"Product":{"code":"SS6SG3","label":"Enterprise COBOL for z\/OS"},"Platform":[{"code":"PF025","label":"Platform Independent"}],"Version":"7D0"}]

Document Information

Modified date:
05 January 2022