Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Setting multiple realtions between SQL tables
Message
From
27/08/1999 11:08:59
Jeff Lovin
Dewitt & Company Inc
Houston, Texas, United States
 
 
To
26/08/1999 11:38:15
Cetin Basoz
Engineerica Inc.
Izmir, Turkey
General information
Forum:
Visual FoxPro
Category:
Client/server
Miscellaneous
Thread ID:
00257938
Message ID:
00258436
Views:
17
Dear Cetin,

Thank you very much for the advice. I have included a snippet of code, so that you can actually see what I have done. This code DOES work, of which I am very happy with.

SELECT product.productname, country.countryname, company.compname, ;
city.cityname, Capacity.year, Capacity.npcapacity, ;
Capacity.tempplant ;
FROM dcidatabase!capacity ;
INNER JOIN dcidatabase!product;
ON capacity.productcode = product.productcode ;
INNER JOIN dcidatabase!country ;
ON Country.countrycode = val(left(capacity.tempplant,2)) ;
INNER JOIN dcidatabase!company ;
ON company.compcode = val(substr(capacity.tempplant,3,3)) ;
INNER JOIN dcidatabase!city ;
ON city.citycode=val(right(capacity.tempplant,3)) ;
WHERE country.countrycode=80 AND;
product.productcode=3

However, there is a slight problem - I have two more tables that must be included. These tables (region & state) need to be joined with country. Is this possible? Thank you again for your help.

Jeff
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform