Both money and smallmoney in SQL Server have a scle of 4. Please check the precision and scale of your data in the table. This gives you a clue as to what it *might* get rendered as on a client. Globalization settings affect this, as does your machine's regional settings.

For the most part, if you want to guarantee that a value (any value - date/time/decimal/etc...) is a specific format always, then provice in your code that exact format.

Remember:

  visible data format != data storage

 - dave

Ray Hughes wrote:
Hi Tony,

I am not an expert by any means. My thought is that
the fields in question are defined as datatype "Money" in sql.

In sql I believe when it is defined as Money it is returned as you described "370.000" .

I believe that if it were defined as varchar then the return value would be "370".

Now again I am not any type of expert.

Regards
Ray


From: Tony Gray <[EMAIL PROTECTED]>
Reply-To: Dallas/Fort Worth ColdFusion User Group Mailing List<[email protected]>
To: [email protected]
Subject: [DFW CFUG] Strong Data Typing in MX7
Date: Thu, 16 Feb 2006 11:28:55 -0600

Has anyone noticed this issue in CFMX7?


When quering an Oracle table directly with TOAD results are return like
this.
query - Rows: 1 INVTY_FCST LKM_MILL LKM_MONTH LKM_YEAR SALES_FCST 1 4550 GU
2 2006 370

The same SQL inside CF returns data in this format (adding the decimal point
and the zeros as the fields are defined in the DB)

INVTY_FCST LKM_MILL LKM_MONTH LKM_YEAR SALES_FCST 1 4550.000 GU 2 2006
370.000

CF did not use to do that. Is that something new with MX7? Are there any
work arounds? I now have ".00" showing up all over my site since upgrading
to CFMX7 recently.

--
Tony Gray
901-419-1775 (w)
901-412-4641 (c)
662-796-1928 (h)

_______________________________________________
Reply to DFWCFUG: [email protected] Subscribe/Unsubscribe: http://lists1.safesecureweb.com/mailman/listinfo/list List Archives: http://www.mail-archive.com/list%40list.dfwcfug.org/ http://www.mail-archive.com/list%40dfwcfug.org/ DFWCFUG Sponsors: www.HostMySite.com www.teksystems.com/

Reply via email to