Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Need help with Select SQL
Message
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00096128
Message ID:
00096188
Views:
20
>Michelle,
>
>Actually, I think Bob's is the best:
>
>select distinct a.id from a,b,c where a.id = b.id or a.id = c.id
>
>You should add DISTINCT after SELECT if you don't want to get duplicate ID's for records in a that are in both b and c. My original suggestion will return the same results, but I think Bob's will be the fastest.

This is what I did, based on the first one. I haven't run it yet, so I don't know if it works.

select a.client_num, a.client_src, a.fname, a.lname;
from clients a;
where (a.client_num IN (select b.client_num from bal b);
and a.client_src IN (select b.client_src from bal b));
or (a.client_num IN (select c.client_num from ver c);
and a.client_src IN (select c.client_src from ver c));
into cursor bc && Billed Clients

Thanks!
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform