Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Code Sql
Message
 
À
Tous
Information générale
Forum:
Visual FoxPro
Catégorie:
Base de données, Tables, Vues, Index et syntaxe SQL
Titre:
Code Sql
Divers
Thread ID:
00876997
Message ID:
00876997
Vues:
45
Hi All,


I have

PRESTATION.DBF
Ifonctionid I && 1 Infirmière A1 - 2 Infirmière A2 - 3 Garde malade etc....( ne > 4 )
nHeures N(8,2)
ddate D

I Would like to know the total of the hours by function for one precise period.
This syntax do'nt Functions
  SELECT IIF( Ifonctionid = 1 , SUM( nheures ) , .T. ) AS "Infirmères",;
       IIF( Ifonctionid = 2 , SUM( nheures ) , .T. ) AS "Garde",;
       IIF( Ifonctionid = 3 , SUM( nheures ) , .T. ) AS "Para";
  	    FROM amline!prestation;
    WHERE  date  BETW  D_debut AND  D_Fin GROUP By ifonctionId INTO CURSOR Temp3
    
    SELECT temp3
Thanks in advance for help.
VFP 8 Pack1

bernhart
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform