Title: RE: [cfaussie] Re: Budget CF Server
 
sgn() = Returns 1 if number is pos, 0 if number is 0 and -1 if number is neg
 
if you want to convert all neg numbers to 0, then I guess you could do something like
 
<cfscript>
number = -10;
number = MAX(number,0)
writeOutput(number);
</cfscript>

Regards

Steve Onnis
Domain Concept Designs
+61 422 337 685
+61 3 9431 4249

http://www.domainconceptdesigns.com
[EMAIL PROTECTED]
http://www.cfcentral.com.au
[EMAIL PROTECTED]

("If you think it can't be done, you haven't asked me!") - Steve Onnis

 

-----Original Message-----
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]On Behalf Of Phil Evans
Sent: Friday, February 28, 2003 2:52 PM
To: CFAussie Mailing List
Subject: [cfaussie] Zero suppression

Hi All,
 
The other day we had some very clever methods for converting negatives to zero.
Any one care to have a crack at converting zero to null, prior to displaying on a form?
(Aside from using an IF statement).
 
Thanks,
Phil.
 
 
---
You are currently subscribed to cfaussie as: [EMAIL PROTECTED]
To unsubscribe send a blank email to [EMAIL PROTECTED]

MX Downunder AsiaPac DevCon - http://mxdu.com/
---
You are currently subscribed to cfaussie as: [EMAIL PROTECTED]
To unsubscribe send a blank email to [EMAIL PROTECTED]

MX Downunder AsiaPac DevCon - http://mxdu.com/

Reply via email to