Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Received / Outgoing Product
Message
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Environment versions
Visual FoxPro:
VFP 9 SP1
OS:
Windows XP SP2
Network:
Windows 2003 Server
Database:
Visual FoxPro
Miscellaneous
Thread ID:
01210081
Message ID:
01211348
Views:
15
Yes, Naomi, you certainly did and I just had to try it anyway. I would often tell my children to not do something, but they would do it anyway. I guess I still have that problem. Thanks for your help in spite of my stubbornness. :)

>Cecil,

>I told you already that this code will produce wrong result. Please review the thread I pointed you to and revise your SQL accordingly.

>UPDATE. I see that Sergey provided you with the solution in his last reply to you.

>>This came out way off on the resulting Quantity for "QtyIn". It is in reality 221 for a specific customer, but the SQL statement made it come out as 4 times that value, meaning 884.
>>
>>Perhaps you are correct in your statement that 3 tables will give the wrong values in a SQL Statement. The statement seems logical, but it came out wrong in its sum of the QtyIn value. Here's the code I ended up using which is a summation of several of those who contributed here:
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform