Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
SQL on Two Tables where All Fields Match
Message
From
05/07/2001 11:13:56
 
 
To
05/07/2001 11:10:05
Jay Johengen
Altamahaw-Ossipee, North Carolina, United States
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Miscellaneous
Thread ID:
00526958
Message ID:
00526983
Views:
29
Hi,

Sorry for the uncomplete message.

You can loop all the fields in the table and generate a where staement.

e.g

FOR n = 1 to FCOUNT(TableB)
cWhere = cWhere + 'TableB.' + FIELD(n) + '= TableA.' + FIELD(n)
ENDFOR

cStatement = 'SELECT B.* FROM TableB B, TableA A WHERE ' + cWhere

&cStatement

Wilson
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform