Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Select and sum
Message
De
22/11/2004 10:45:00
 
 
À
22/11/2004 07:24:19
Information générale
Forum:
Visual FoxPro
Catégorie:
Gestionnaire d'écran & Écrans
Titre:
Divers
Thread ID:
00963216
Message ID:
00963485
Vues:
9
about my qustion,i mean i my customer have total for
customer1 name "aiwfisauy"
bill 1 =500
bill 2 =400
bill 3 =300
.
.
1200

customer2 name "ggg"
bill 1=100
...


You can get the totals for each customer into a separate cursor like so:
SELECT inname, SUM( bill_total ) AS customer_total FROM csrBillTotals ;
  GROUP BY inname ;
  ORDER BY inname INTO CURSOR csrCustomer_totals
You can relate the 2 cursors like this:
SELECT csrCustomer_totals
INDEX ON inname TAG inname
SELECT csrBillTotals 
SET RELATION TO inname INTO csrCustomer_totals
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform