Information générale
Catégorie:
Codage, syntaxe et commandes
>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!
Précédent
Suivant
Répondre
Voir le fil de ce thread
Voir le fil de ce thread à partir de ce message seulement
Voir tous les messages de ce thread
Voir tous les messages de ce thread à partir de ce message seulement