Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
SQL difference in FP 2.6 and VFP 6.0
Message
From
09/03/2001 09:42:09
Shane Gilbert
Oklahoma State Department of Education
Norman, Oklahoma, United States
 
 
To
08/03/2001 23:16:45
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Miscellaneous
Thread ID:
00483354
Message ID:
00483485
Views:
12
Thanks for the suggestions. I figured out my bonehead problem. I was accessing my backup data on one computer and it hadn't been updated with the latest numbers yet. Some days are better spent at home.

>>I have the following SQL statement:
>>
>>SELECT motodate.co, motodate.agreeno, motodate.dist,header.distname,;
>> Max(Int((fedfreelun+fedredlun+fedpaidlun)/dayslun+.5)) AS adp,;
>> Max(Int((fedfreebrk+fedredbrk+fedpaidbrk)/daysbrk+.5)) AS adpb,;
>> Max(Int((fedfreesnb+fedredsnb+fedpaidsnb)/dayssnb+.5)) AS adps;
>> FROM motodate,header;
>> WHERE Motodate.co = header.co AND Motodate.agreeno = header.agreeno;
>> AND ((motodate.month >= val("7") AND Motodate.year=2000);
>> OR (Motodate.month <= val("6") AND Motodate.year = 2001));
>> ORDER BY motodate.co, motodate.agreeno;
>> GROUP BY motodate.co,motodate.agreeno;
>> INTO CURSOR temp
>>
>>I getting different results when running this on FP 2.6 than from VFP 6.0 on a few of the resulting 584 records. Checking the detail records on one of the records that is different, VFP 6.0 appears to be giving the CORRECT result, while FP 2.6 is incorrect. Does anyone know of any bugs with FP 2.6 that would be related to this? Thanks,
>
>I don't know anything specific, but I'd look at a couple of things:
>
>- use 7 and 6 instead of VAL("7") and VAL("6")
>- be careful with your setting of SET EXACT in character string comparisons, or use the "==" operator (without the quotes) to force exact string comparison regardless of SET EXACT
--Shane
Previous
Reply
Map
View

Click here to load this message in the networking platform