> I tried Integer, but when, for example, 100.50 gets entered into a > formfield, > then inserted into the db, it gets truncated to 100. How do I set up > Integer > to retain 2 decimal places?
Multiply the number by 100. > Also, I'm trying to setup the mySQL db fieldtype and CF processing > such that > if a user inputs $100.50, which is not a number, mySQL won't > reject it. > I tried setting up the CF input line with various combinations of > functions,such as: > > <cfqueryparam cfsqltype="CF_SQL_INTEGER" > Value="#LSCurrentFormat(LSParseNumber(Form.UCPaymentAmount))#"> > > but I haven't been able to find the right combo to allow users to > inputeither 100.50, 100.5, or $100.50 > and still get the right number into the db without rounding or > truncatingand back out for display on the CF page. > > Clues? Don't let them enter $100.50 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~| Archives: http://www.houseoffusion.com/cf_lists/index.cfm?forumid=4 Subscription: http://www.houseoffusion.com/cf_lists/index.cfm?method=subscribe&forumid=4 FAQ: http://www.thenetprofits.co.uk/coldfusion/faq Structure your ColdFusion code with Fusebox. Get the official book at http://www.fusionauthority.com/bkinfo.cfm