My last post was directly translated from the same one in Spanish sent 
to a local users group, and I missed translating the subject

Here it goes again, please help me

Rafael

quote

I have an app built in VFP9SP2 as a front end and SQLServer Express 2008
RS2 as backend. The connection is made by ODBC and the network is a LAN
(no internet involved)

Using SQL PassThrough I bring records from a table with a numeric data
field of size 14 with 4 decimals.

If I run the sql sentence in TSQL , using the Management Studio,like so:

select code,descrip,qty from stock where code = 'XD-98789' I get the
correct result, namely:

code             descrip           qty

XD-98789   WIDGET    3585256,1234


But, running the same sentence in SPT, like so:

cCode ='XD-98789'

sqlexec(nHandle,[select code,descrip,qty from stock where code 
=]+[']+cCode+['],'curStock')

I get the following result

code      descrip           qty

XD-98789   WIDGET    3585256,12  (it shows 2, not 4 decimals)

SET DECIMALS TO 4 is useless.

But the worst is if I use SET FIXED ON and then SET DECIMALS TO 4


code      descrip    qty

XD-98789   WIDGET    3,585

It truncates the integer part of the quantity and shows the result with 4 
decimals, which are the following digits
   of the integer part.

What the heck is going on here?

unquote


Rafael Copquin



_______________________________________________
Post Messages to: ProFox@leafe.com
Subscription Maintenance: http://leafe.com/mailman/listinfo/profox
OT-free version of this list: http://leafe.com/mailman/listinfo/profoxtech
Searchable Archive: http://leafe.com/archives/search/profox
This message: 
http://leafe.com/archives/byMID/profox/4f32969e.2040...@fibertel.com.ar
** All postings, unless explicitly stated otherwise, are the opinions of the 
author, and do not constitute legal or medical advice. This statement is added 
to the messages for those lawyers who are too stupid to see the obvious.

Reply via email to