|
Hi, there is also an easy way to use embedded SQL to directly round up/down to nearest 1000. By specifying a negative number in second parameter of the scalar function round, rounding to 10, 100 and so on can be done. In the following example rounding to the nearest 1000 is performed. D MyNumResult S 15P 5 D MyNumValue S 9P 3 Inz(444555.666) C/EXEC SQL :MyNumResult = ROUND(:MyNumValue, -3) C/END-EXEC /Free Dsply MyNumResult *INLR = *ON; /EndIf Birgitta
As an Amazon Associate we earn from qualifying purchases.
This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].
Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.