(IFGT(MOD((`Price Each` * 100),1),0,FORMAT(`Price 
Each`,'990.0000'),FORMAT(`Price Each`,'990.00')))

Dennis McGrath
Software Developer
QMI Security Solutions
1661 Glenlake Ave
Itasca IL 60143
630-980-8461
[email protected]
________________________________________
From: [email protected] [mailto:[email protected]] On Behalf Of 
[email protected]
Sent: Monday, December 19, 2011 1:04 PM
To: RBASE-L Mailing List
Subject: [RBASE-L] - Decimal places in a report

The column is a "Price Each" value, but its datatype is
Double.   There can be values with no decimal places, and
up to 4 decimal places.   In the report, I want to show the 
price with 2 decimal places if there are < 2 decimal places,
yet be able to retain all decimal places if >2.  Anyone think
of a set of report expressions or a stored procedure call to
easily do that?

Examples (hope this formats):

Data      Report shows
25        25.00
25.1      25.10
25.2015   25.2015

Thanks!  

Karen


Reply via email to