Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Field names after select
Message
 
À
30/10/1999 22:14:00
Ray Keys-Bramlett
Custom Business Applications
Fresno, Californie, États-Unis
Information générale
Forum:
Visual FoxPro
Catégorie:
Base de données, Tables, Vues, Index et syntaxe SQL
Divers
Thread ID:
00284431
Message ID:
00284443
Vues:
12
If you ONLY need the ID fields, then you can simply add them to the query:

select table1.*, table2.*, table1.ID AS ID1, table2.id as ID2 ;
from table1,table2 where ID1=ID2

This can be extended to any other fields that are duplicates.

HTH
Barbara


>I would like to combine all fields from two tables in an query.
>I was using a wild card to get the field names:
>
>select * from table1,table2 where table1.ID=table2.ID
>
>I may not know what all the fields are at a later date, so I don't want to list them in the query.
>
>The result of my query returns all the fields except the ID which is now stored in ID_A and ID_B. In this case ID_A and ID_B will always be the same and I would like them to be in the field ID.
>
>I know I can build a list of fields, build a string and use it in my query, but I am hoping for something elegent and simple, if it exists.
Barbara Paltiel, Paltiel Inc.
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform