I am calculating GPA to print on a report and store in a secondary file via RPG on an AS400. When I print the GPA on the report, there is no low-order truncation; however, when I store this same field in my secondary file, low-order truncation occurs. How do I prevent this??
Code as follows:
TOTQTY DIV TOTATT GPA 54
TOTQTY is defined as 41.
TOTATT is defined as 31.
GPA is defined as 54 on the report and in the secondary fle.
67.0/18.0 = 3.722[strong]2[/strong] (prints on report)
3.722[strong]0[/strong] is stored in the secondary file (HEX values of F3 F7 F2 F2 F[strong]0[/strong]).
Free Guide: Managing storage for virtual environments
Complete a brief survey to get a complimentary 70-page whitepaper featuring the best methods and solutions for your virtual environment, as well as hypervisor-specific management advice from TechTarget experts. Don’t miss out on this exclusive content!