Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Select SUM and calculate sum() different values
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
00382827
Message ID:
00383105
Vues:
18
>The SQl select doesn't need a group by because it is returning one record for the sum for one employee. If i was doing multiple employees and reporting back then i would need the group by.

Try it first and let us see the result:

SELECT SUM(hrs_driving+hrs_onduty) AS 'results1' ;
FROM logs!logs INTO CURSOR 'test1' ;
WHERE logs.employee_code = THISFORM.EMPLOYEE_CODE1.Text1.VALUE ;
AND BETWEEN(logs.txdate,rdates(2),rdates(1)) GROUP BY logs.employee_code ORDER BY logs.employee_code
JESS S. BANAGA
Project Leader - SDD division
...shifting from VFP to C#.Net

CHARISMA simply means: "Be more concerned about making others feel good about themselves than you are in making them feel good about you."
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform