select @rownum:=@rownum+1 AS rownum , a.date as date,
sum(case when reconciliationTypeStr='+' then a.value else 0 end) as incomeAmount,
sum(case when reconciliationTypeStr='-' then a.value else 0 end) as payAmount
from act_reconciliation a , (SELECT @rownum:=0) r where 1=1 $P!{condition}
group by a.date
order by rownum $P!{paging}
sum(case when reconciliationTypeStr='+' then a.value else 0 end) as incomeAmount,
sum(case when reconciliationTypeStr='-' then a.value else 0 end) as payAmount
from act_reconciliation a , (SELECT @rownum:=0) r where 1=1 $P!{condition}
group by a.date
order by rownum $P!{paging}