You need to set the scale attribute in the cfqueryparam tag.

http://cfquickdocs.com/cf9/?getDoc=cfqueryparam

--
WSS4CF - WS-Security framework for CF
http://wss4cf.riaforge.org/



On 1 March 2011 10:43, Pete Ruckelshaus <pruckelsh...@gmail.com> wrote:
>
> Primarily because it's easier and more accurate to sort on a single overall
> value (inches).
>
> Of course, if it were up to me, we'd be using metric :)
>
> On Mon, Feb 28, 2011 at 7:12 PM, Roger Austin <raust...@nc.rr.com> wrote:
>
>>
>> On 2/26/2011 10:08 PM, Pete Ruckelshaus wrote:
>> >
>> > OK, just not my night with decimal values.
>> >
>> > Trying to store distances (for throwing and jumping events), which are
>> > measured in feet and inches.  In order to maintain proper sort order, I
>> > decided to convert feet and inches (with fractions of an inch as decimal
>> > value) to inches with fractions of an inch as decimal values.
>> >
>> > Again, database is SQL Server 2008, and I'm using cfqueryparam.  Data
>> type
>> > for the column in question is decimal(18, 4), and I'm using
>> CF_SQL_DECIMAL
>> > as the cfsqltype value.  I can see in the debug output that the decimal
>> > portion of the value is part of the value to be inserted, for instance,
>> > 825.25, but looking at the database table, the stored value is  825.0000
>>
>> Why not store two fields; one for feet and one for inches. That seems
>> like the easiest way to do it other than just use one float for both.
>> The decimal issue is probably more a database issue than a CF issue.
>>
>>
>
> 

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:342631
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm

Reply via email to