Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Four Table Join using same table twice.
Message
De
04/06/2002 13:57:44
 
 
À
04/06/2002 13:15:23
Dragan Nedeljkovich (En ligne)
Now officially retired
Zrenjanin, Serbia
Information générale
Forum:
Visual FoxPro
Catégorie:
Base de données, Tables, Vues, Index et syntaxe SQL
Divers
Thread ID:
00664572
Message ID:
00664629
Vues:
22
>If you're using the same twice as if it was two tables, you should give this second instance of the table a different alias. If I understood well,
>
>select * from leads ;
> {left/full/right} join leads on Leads.iSourceKey=Source.iSourcePrimaryKey;
> ... join NOTES on Leads.iNoteKey = Notes.iNotePrimaryKey ;
> ... join source s2 on S2.iNoteKey = Notes.iNotePrimaryKey

Notes rather than Source, but yes, that's the problem and the solution. I guess VFP is clobbering the two instances of Notes.iNotePrimarykey. *Sigh* I overlooked something so simple(aliasing) that I've done before. Thanks.
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform