Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Select-sql statement
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
00614246
Message ID:
00614274
Vues:
26
>>>Hi All,
>>> Is there a way to craft a select statement to list what is in a field and how many times what is in the field repeat?
>>>Thanks,
>>
SELECT field1, COUNT(*) FROM mytable GROUP BY 1
>
>Thanks Sergey, you are the greatest.

Note, that starting with VFP3, COUNT(myField) tells you the number of records in your group with a non-NULL value for myField, while COUNT(*) will bring the number of records in the group. YMMV.
Nick Neklioudov
Universal Thread Consultant
3 times Microsoft MVP - Visual FoxPro

"I have not failed. I've just found 10,000 ways that don't work." - Thomas Edison
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform