Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
What parameter to use fo this COUNT()
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:
01259476
Message ID:
01259482
Vues:
17
Hi Dmitry,

char "*" or any field. It's depends what you need.

If you use * or any field which dont' support NULL value, then COUNT() return all "records". If you use any field which support NULL value, then COUNT() don't compute NULL values.

MartinaJ

>Can someone suggest the right parameter to pass to COUNT() function of SQL Select to accomplish the following:
>
>Table fields
>ID, C
>WEEK, N
>HRS, N
>
>
>select week, id, sum(hrs) as week_hrs, count(???) as week_cnt from
>mytable group by week, id
>
>
>I want the week_cnt in the above SQL Select to count how many records found for a given WEEK and given ID. I tried using count(*) but it gives me total of all records.
>
>I would appreciate any suggestions.
"Navision is evil that needs to be erazed... to the ground"

Jabber: gorila@dione.zcu.cz
Jabber? Jabbim
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform