Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
How to use standard SQL statement
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Versions des environnements
Visual FoxPro:
VFP 9 SP1
Database:
Visual FoxPro
Divers
Thread ID:
01175780
Message ID:
01176631
Vues:
7
This does not work.

SELECT left(rida,2) + MAX(month) FROM t2 ;
group by 1

causes error

Cannot GROUP by aggregate field.



>You cannot compare multiple columns that way. Instead concatenate the rida and month columns together and compare them in your WHERE statement such as:
>
>DELETE FROM t1 ;
>  WHERE ( left(rida,2) + month ) NOT IN ;
>   (SELECT left(rida,2) +  MAX(month) FROM  t2 ;
>   group by 1)
>
Andrus
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform