Caps db üzerindeki çeklere ait mrequest sorgusu için aşağıdaki sql sorgusu kullanılabilir.
select reqstate, count(*) as Mrequests from mrequests group by reqstate order by reqstate
select
CONVERT (date ,ReqTime) BusinessDate,
case when MREQUESTS.ReqState='0' then 'Pending to Post'
when MREQUESTS.ReqState='1' then 'Posted'
when MREQUESTS.ReqState='2' then 'Failed Retry Later'
when MREQUESTS.ReqState='3' then 'Failed Rejected'
end as Enterprise_Posting_Status,
ReqState,count (reqstate) as Mrequest_Count from dbo.MREQUESTS
group by ReqState,CONVERT (date ,ReqTime)
order by CONVERT (date ,ReqTime),ReqState