select distinct a.data,
b.status,
--listagg(count(b.status)),
sum(c.vlrtotal)
from tb_documento a, tb_documentocupom b, tb_documentoitem c
where a.empresa = b.empresa
and a.empresa = c.empresa
and a.pdv = b.pdv
and a.pdv = c.pdv
and a.documento = b.documento
and a.documento = c.documento
and a.empresa = 2
and a.pdv = 13
and a.data between '25-nov-2015' and '25-nov-2015'
and a.documento in (2531429, 2531180)
group by a.data, b.status;
DATA...........STATUS......COUNT(B.STATUS)......SUM(C.VLRTOTAL)
25/11/2015......V....................11.......................71,59
25/11/2015......C....................8........................28,13