Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Problem with count(*) in sql select
Message
 
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Base de données, Tables, Vues, Index et syntaxe SQL
Versions des environnements
Visual FoxPro:
VFP 9 SP1
Divers
Thread ID:
01224704
Message ID:
01224705
Vues:
13
This message has been marked as the solution to the initial question of the thread.
The column MYCNT does not exist, it's created by aggregate function. As such it should be checked in HAVING clause.
...
HAVING MYCNT > 1
...
>Can someone please explain why the following sql select gives error "column MYCNT not found"?
>
>
>select MYFLD, COUNT(*) as MYCNT from MYTABLE where MYCNT > 1 group by MYFLD
>
>
>Thank you.
--sb--
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform