Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
SQL to get Result
Message
From
27/02/2010 19:11:11
 
 
To
All
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Title:
SQL to get Result
Environment versions
Visual FoxPro:
VFP 9 SP2
Database:
Visual FoxPro
Miscellaneous
Thread ID:
01451500
Message ID:
01451500
Views:
99
Hi Everyone..

I have 3 Tables


First is Prodm
---------------------------
PdID| Name |OPStock
----------------------------
1 | aaaa | 10.00
----------------------------
2 | bbbb | 20.00
----------------------------
3 | cccc | 50.00
----------------------------
4 | dddd | 30.00
----------------------------
5 | eeee | 40.00
----------------------------


Second Is Production
---------------------
PdId |Date |Production
-------------------------------
2 |01/01/2010|100.00
-------------------------------
5 |01/01/2010|200.00
-------------------------------
1 |01/01/2010|100.00
-------------------------------

Third IS Sales
-------------
PdID|Date | Sales
----------------------
1 |01/01/2010| 5.00
----------------------
1 |01/02/2010|10.00
----------------------
3 |01/02/2010|50.00
----------------------


Now SQL Should Display Result as under..

PdId |Name|OpStk|ProdQ|Sales|CLStock

1 |aaaa |10.00|100.00|15.00|095.00
2|bbbb |20.00|100.00|00.00|120.00
3|cccc |50.00|000.00|50.00|000.00
4|dddd |30.00|000.00|30.00|000.00
5|eeee |40.00|200.00|00.00|240.00



Hope I will get help from u all..

Rajesh
Next
Reply
Map
View

Click here to load this message in the networking platform