Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Counting records using select-sql
Message
De
26/08/2004 11:30:41
Hilmar Zonneveld
Independent Consultant
Cochabamba, Bolivie
 
 
À
26/08/2004 05:19:00
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
00936513
Message ID:
00936644
Vues:
20
>hi mike, thanks for your reply but it only gives me one column- count. i'd like my cursor to have 3 fields each for value status.
>
>any more help?

How about this:
select;
    sum(iif(status=1, 1, 0) as Cnt1;
    sum(iif(status=2, 1, 0) as Cnt2;
    sum(iif(status=3, 1, 0) as Cnt3;
  from MyTable;
  into cursor Temp
Difference in opinions hath cost many millions of lives: for instance, whether flesh be bread, or bread be flesh; whether whistling be a vice or a virtue; whether it be better to kiss a post, or throw it into the fire... (from Gulliver's Travels)
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform