Voilà la requête SQL que j'ai :
select m.mp_l, count(*), sum(c.cde_tot_ttc)
from e_cde c, e_mode_paiement m
where c.cde_ty_se_c = 'WV2'
and c.cde_mp_c in ('KM','KI','KW','KT', 'KA','KC', 'CA')
and c.cde_mp_c = m.mp_c
--and c.cde_d between to_date('&date', 'dd/mm/yyyy hh24:mi:ss') -6
--and to_date('&date', 'dd/mm/yyyy hh24:mi:ss')
and c.cde_d between to_date('01/06/2009 00:00:01', 'dd/mm/yyyy hh24:mi:ss')
and to_date('07/06/2009 23:59:59', 'dd/mm/yyyy hh24:mi:ss')
group by m.mp_l
order by 1
Je me connecte à PL/SQL Developer. La date sera a automatiser aussi.
Mais mon problème principal reste d'interroger cette requête via Excel.
Cordialement,
Clément.