Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Grouping in reports
Message
De
18/08/1999 12:48:47
 
 
À
18/08/1999 09:53:17
Information générale
Forum:
Visual FoxPro
Catégorie:
Gestionnaire de rapports & Rapports
Divers
Thread ID:
00254954
Message ID:
00255072
Vues:
20
>DATE, HOURS, CODE, ACCOUNT
>1/1/99, 10, A, 123456
>1/2/99, 15, B, 789123
>1/3/99, 8, A, 123456
>1/4/99, 5, B, 951753
>
>TOTALS:
> 18, A, 123456
> 15, B, 789123
> 5, B, 951753
>
>How do I acheive to get the TOTALS: grouped as they are in the above example? To complicate it even futher the user selects a date range.
>For example 1/1/99 to 1/2/99 OR 1/1/99 to 1/4/99.
>
>Thanks in advance for any help.
>
>Sanjay

For your date ranges, (adding to Nick's reply):
<B>ldBegin = {^1999/01/01}
ldEnd = {^1999/01/04}</B>
SELECT sum(hours), code, account ;
       FROM myTable ;
       <B>WHERE BETWEEN(date,ldBegin,ldEnd)</B> ;
       GROUP BY account
BTW, you really shouldn't use the reserved word DATE as a field name.
Fred
Microsoft Visual FoxPro MVP

foxcentral.net
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform