Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Why Two Different Return Counts
Message
De
11/09/2007 14:49:09
Erick Miranda
Formata Data Business - Grupo Linx
Contagem, Brésil
 
 
À
11/09/2007 14:24:46
Steven Dyke
Safran Seats USA
Texas, États-Unis
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
OS:
Windows XP SP2
Network:
Windows 2000 Server
Database:
Visual FoxPro
Divers
Thread ID:
01253728
Message ID:
01253752
Vues:
23
This message has been marked as the solution to the initial question of the thread.
Steven,

>I think my first sql ststement is where I have went wrong. I have a table with a cono field. Many records can have the same cono. I need a count of distinct cono's that have the archivef field set to '0'.
>
>What I think my current sql is giving is the total number of records with the same cono.
>
>SELECT Count(*) As rCount, cono FROM webprddt6.tsotagtbl Where archivef = '0' Group By cono

So, you can to try this:
Select count(*);
   From (SELECT Count(*) As rCount, cono FROM webprddt6.tsotagtbl;
            Where archivef = '0' Group By cono;
        ) myAlias
With this you will have the number of cono that has archivef field set to 0.
I hope this help.
Erick
Força Sempre!
Strength Always!
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform