Author: Stephen Russell
Posted: 2009-05-01 at 09:23:10
On Thu, Apr 30, 2009 at 7:24 PM, Rafael Copquin <rcopquin@ciudad.com.ar> wr=
ote:
> Another issue I have with SQLExpress is this:
>
> A SQLSE table has a =A0price field with a numeric(10,2) type.
>
> When it comes to VFP through an SPT call it comes with the correct struct=
ure
> (apparently)
> But after transforming it with the cursortoxml function to produce a cXML
> variable, the opposite function, xmltocursor fails in particularly that
> field: the error message is that it is getting the incorrect data type
>
> If I browse the cursor, it shows =A023,50 ( not 23.50 as should be)
-----------------------------------
What are the language settings on that workstation? that may be why
you see the comma instead of the decimal.
> I solved it with the cast function in a select statement:
>
> select cast(price as N(10,2)) as price from mycursor into ......
>
> However, the price is 23.50 but I only get 23.00. No matter what I do, th=
e
> cents are discarded.
> ?????
-----------
Where are you doing the cast? In VFP or back on the server?
--=20
Stephen Russell
Sr. Production Systems Programmer
Web and Windows Development
Independent Contractor
Memphis TN
901.246-0159