Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Monthwise Total
Message
 
 
À
07/10/2004 23:59:30
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Titre:
Divers
Thread ID:
00949792
Message ID:
00949793
Vues:
25
>Dear Sir,
>
>I have a table entitled Weights with following fields
>
>date	d(8)
>weight	n(4)
>cash	n(4)
>
>the data in dbf is as
>
>01/12/2003	2345	40
>01/12/2003	4587	80
>15/01/2004	6547	20
>16/02/2004	6584	40
>20/02/2004	1475	40
>
>I wnat to create a query who display following result
>
>Dec	6932	120
>Jan	6547	20
>Feb	8068	80
>
>It would be month wise total of weight and cash filed
>
>What should I write to make query?

Hi Tariq,
select left(cmonth(Date),3) as MonthName, sum(weight) as WeightTotal, sum(cash) as CashTotal ;
group by 1 into cursor curTotal
If it's not broken, fix it until it is.


My Blog
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform