select SELECT client.commonname asAS "Client",
c.claimtype asAS "Claim Type",
c.reasontype asAS "Claim Category",
c.reason asAS "Claim Reason",
d.claimid asAS "Claim ID",
d.disputeid asAS "Dispute ID",
c.customercontactdate asAS "Contact Date",
d.acquirernetwork asAS "Network",
d.status asAS "Dispute Status",
d.disputeamount asAS "Dispute Amount",
toTo_date(cb.performedondatetime) asAS "Chargeback Date",
cb.amount asAS "Chargeback Amount",
fromFROM dispute asAS d
joinJOIN claim asAS c onON d.tenantid = c.tenantid andAND d.claimid = c.claimid
joinJOIN client asAS client onON d.tenantid = client.tenantid andAND d.clientid = client.clientid
joinJOIN recoveryaction asAS cb onON d.tenantid = cb.tenantid andAND d.disputeid = cb.disputeid andAND cb.actionname inIN ( 'Dispute Submitted', 'Rapid Dispute Resolution' ) andAND cb.cycle = '1'
where
cb.performedondatetime is not null -- only disputes with chargebacks
where
WHERE d.tenantid = 'YOURTENANTIDHERE' AND cb.performedondatetime = AND chargebackdate=:daterange
|