Gossamer Forum
Home : Products : DBMan SQL : Discussion :

Rounding Calculations

Quote Reply
Rounding Calculations
How would I round a calculation in a template in DBManSQL?

My calculation is as follows:
<%MSRP - $Price%>

This takes "Retail Price" minus "Sales Price" and returns "YOU SAVE" value.
It does the calculation correctly, but occasionally produces a long value.
ex. $8.72000000000001

See an example here:

I want to round to the nearest currency decimal.
ex. $8.72

Any help would be appreciated!


Pro-Line Direct Electronics Superstore

Last edited by:

rcaudio: Nov 6, 2003, 12:06 AM
Subject Author Views Date
Thread Rounding Calculations rcaudio 3144 Nov 6, 2003, 12:02 AM
Thread Re: [rcaudio] Rounding Calculations
604 3070 Nov 6, 2003, 9:38 AM
Thread Re: [TheStone] Rounding Calculations
rcaudio 3076 Nov 6, 2003, 10:36 AM
Thread Re: [rcaudio] Rounding Calculations
rcaudio 3060 Nov 6, 2003, 10:55 AM
Post Re: [rcaudio] Rounding Calculations
rcaudio 3058 Nov 6, 2003, 2:45 PM