Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
SQuery
Message
De
09/05/2008 09:25:25
 
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Stonefield
Titre:
Re: SQuery
Versions des environnements
Visual FoxPro:
VFP 8 SP1
OS:
Windows XP
Database:
Visual FoxPro
Divers
Thread ID:
01308261
Message ID:
01316056
Vues:
20
Hi Naomi.

>I've created SubTables for all various kinds of phones. My question is - can I use several subtables of the same table in the same report? It's essentially the same field (Phone), so somehow I need to have it aliased differently.
>
>Is it possible?

Yes. A subtable essentially becomes an aliased name for another instance of the same table. For example, suppose you have subtables of Phones called HomePhone (with a subtable filter of HomePhone.PhoneType = 'Home') and CellPhone (with a subtable filter of CellPhone.PhoneType = 'Cell'). Including both of these in a report would result in a SQL statement similar to this:
select Contacts.Name, HomePhone.PhoneNumber, CellPhone.PhoneNumber
  from Contacts join Phones HomePhone on (whatever)
  join Phones CellPhone on (whatever)
Doug
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform