APAR status
Closed as program error.
Error description
Client using Rational Business Developer V7.1.0.1 encounters a p roblem with the MATHLIB.ROUNT function. In the case where c = MathLib.round(c, -2); the number of decima l positions is known (5) and the function processes the result c orrectly. In the case where there is no target (your usage of MathLib.roun d(a * b / 100, -2) as an argument to a function), the preprocess or is not correctly calculating the number of decimal positions for the value of a * b / 100 for the temporary variable, but is instead using the maximum number defined based on the variables being used in the expression (in this example 3). What the error is, is that when multiplication, division, exponentiation, etc are used, this should affect the number of decimal digits to be used for the temporary variable, as the number should be increas ing based upon a formula. Because the number of decimals is too few in the temporary variable, some of the result for the tempor ary variable is lost, and the round function comes up short. This problem would only happen when an expression is used as the function argument, instead of a specific variable. In the case where c = MathLib.round(c, -2); the number of decima l positions is known (5) and the function processes the result c orrectly. In the case where there is no target (your usage of MathLib.roun d(a * b / 100, -2) as an argument to a function), the preprocess or is not correctly calculating the number of decimal positions for the value of a * b / 100 for the temporary variable, but is instead using the maximum number defined based on the variables being used in the expression (in this example 3). What the error is, is that when multiplication, division, exponentiation, etc are used, this should affect the number of decimal digits to be used for the temporary variable, as the number should be increas ing based upon a formula. Because the number of decimals is too few in the temporary variable, some of the result for the tempor ary variable is lost, and the round function comes up short. This problem would only happen when an expression is used as the function argument, instead of a specific variable. LOCAL FIX:
Local fix
Problem summary
The problem resulted because the temporary variable used to hold the argument to the round function was created with a type that was not sufficient to hold the value of the operations.
Problem conclusion
The algorithm for computing the type of the temporary variable has been changed (in both the IRs and in Cobol generation).
Temporary fix
Comments
APAR Information
APAR number
PK77800
Reported component name
RATL BUS DEV
Reported component ID
5724S5000
Reported release
710
Status
CLOSED PER
PE
NoPE
HIPER
NoHIPER
Special Attention
NoSpecatt
Submitted date
2008-12-19
Closed date
2009-03-20
Last modified date
2009-03-20
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
R710 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.1","Edition":"","Line of Business":{"code":"LOB35","label":"Mainframe SW"}}]
Document Information
Modified date:
20 March 2009