Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Create record counter by group
Message
 
 
À
16/11/2011 06:07:05
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Versions des environnements
Visual FoxPro:
VFP 8
Divers
Thread ID:
01529015
Message ID:
01529085
Vues:
53
What is the sort order and PK?

>
>May I know how to use the sql to count a record by grouping.
>example:
>
>Table A
>======
>Receipt DiscountDesc DiscountAmt
>1000 10% discount 10
>1000 20% discount 20
>1001 10% discount 10
>1002 50% discount 50
>1002 10% dsicount 10
>
>
>How to include the running number /counter in record by receipt group such as the output is:
>
>Receipt DiscountDesc DiscountAmt Counter
>1000 10% discount 10 1
>1000 20% discount 20 2
>1001 10% discount 10 1
>1002 50% discount 50 1
>1002 10% dsicount 10 2
>
>Thanks for your help in advance.
--sb--
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform