Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
SQL Select Union Syntax
Message
De
24/08/2005 11:45:11
 
 
À
Tous
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Titre:
SQL Select Union Syntax
Versions des environnements
Visual FoxPro:
VFP 6 SP5
OS:
Windows 2000 SP4
Divers
Thread ID:
01043414
Message ID:
01043414
Vues:
53
I am trying to combine into on table after collecting addition info, but I keep getting:
Command contains unrecognized phase / keyword.
sql order by invaild - when I remove the first order by line.

But when I run the two select statements seperately, I get the correct info.
SELECT qmf_temp.*, stops.stp_desc__ AS schl_desc FROM stops, stptrn, qmf_temp ; 
  WHERE stops.stop_id___ == stptrn.stop_id___ AND ;
        qmf_temp.fstop____2 = stptrn.fstop_id__ ;
        and inlist(qmf_temp.triptype__,1,3) ;
        order by studnt_id_, qmf_temp.stp_desc__, triptype__, program___ ;
union ;
SELECT qmf_temp.*, stops.stp_desc__ AS schl_desc FROM stops, stptrn, qmf_temp ; 
  WHERE stops.stop_id___ == stptrn.stop_id___ AND ;
        qmf_temp.fstop_____ = stptrn.fstop_id__ ;
        and inlist(qmf_temp.triptype__,2,4) ;
        order by studnt_id_, qmf_temp.stp_desc__, triptype__, program___ ;
into cursor qmf_all
TIA
Beth
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform