IBM Support

PM14369: IF IN check does not work as expected with textLiteralDefaultIsString = no

Subscribe

You can track all active APARs for this component.

 

APAR status

  • Closed as program error.

Error description

  • Rational Business Developer V7.5.1.4:
    
    IF IN check does not work as expected with
    textLiteralDefaultIsString = no.
    
    Using the following program as an example:
    
    program MYPROG02 type basicProgram {
      textLiteralDefaultIsString = no }
    
       function main()
          x char(10) = "DELETE";
    
          if(x in["GET", "INSERT", "UPDATE", "DELETE"])
             syslib.writeStdout("true");
          else
             syslib.writeStdout("false");
          end
    
          if(x in["INSERT", "UPDATE", "DELETE", "GET"])
             syslib.writeStdout("true");
          else
             syslib.writeStdout("false");
          end
    
          if(x in["GET   ", "INSERT", "UPDATE", "DELETE"])
             syslib.writeStdout("true");
          else
             syslib.writeStdout("false");
          end
       end
    
    end
    
    The first IF check is incorrectly evaluating to false while the
    other IF checks provides the correct results.
    
    The incorrect behavior is seen using the EGL debugger, running
    EGL generated Java and running EGL generated COBOL.
    

Local fix

  • Choose one of the following options to workaround this issue:
    
    1) Change:
    
         textLiteralDefaultIsString = no
    
       to:
    
         textLiteralDefaultIsString = yes
    
    2) Code the IF check where the longest string is in the first
       element of the array.  For example:
    
         if(x in["INSERT", "UPDATE", "DELETE", "GET"])
    
    3) Pad the first element with blanks to make the length the same
       as the longest array value.  For example:
    
         if(x in["GET   ", "INSERT", "UPDATE", "DELETE"])
    
    A temp fix is also available from support.  This fixtest
    requires Rational Business Developer 7.6.1.5 to be applied
    first.
    

Problem summary

  • ****************************************************************
    * USERS AFFECTED:                                              *
    ****************************************************************
    * PROBLEM DESCRIPTION:                                         *
    ****************************************************************
    * RECOMMENDATION:                                              *
    ****************************************************************
    The type of the array literal was being set the the type of
    the first element of the array. This caused longer elements
    in the array to be truncated.
    

Problem conclusion

  • The alogrithm was changed to set the type of the literal
    array based on the longest elemet
    

Temporary fix

Comments

APAR Information

  • APAR number

    PM14369

  • Reported component name

    RATL BUS DEV

  • Reported component ID

    5724S5000

  • Reported release

    751

  • Status

    CLOSED PER

  • PE

    NoPE

  • HIPER

    NoHIPER

  • Special Attention

    NoSpecatt

  • Submitted date

    2010-05-12

  • Closed date

    2010-10-13

  • Last modified date

    2010-10-13

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

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

Fix information

  • Fixed component name

    RATL BUS DEV

  • Fixed component ID

    5724S5000

Applicable component levels

  • R751 PSN

       UP

[{"Business Unit":{"code":"BU058","label":"IBM Infrastructure w\/TPS"},"Product":{"code":"SSMQ79","label":"Rational Business Developer"},"Component":"","ARM Category":[],"Platform":[{"code":"PF025","label":"Platform Independent"}],"Version":"7.5.1","Edition":"","Line of Business":{"code":"LOB35","label":"Mainframe SW"}}]

Document Information

Modified date:
13 October 2010