Important Content Update Message
We are currently updating the OP Help Center content for the release of OP 20. OP 20 (official version 20.0.x) is the certified, 2015 Edition, version of the Office Practicum software. This is displayed in your software (Help tab > About) and in the Help Center tab labeled Version 20.0. We appreciate your patience as we continue to update all of our content.

SQL: Simple Charges, Payments, and Adjustments


This report shows the chart number, DOB, claim (invoice) number, date of service, CPT code, insurance code, charge, place of service, diagnosis code(s), payment, and adjustment amounts for the date range you specify.

A sample image of this SQL report run in the Database Viewer is shown below:


  • Voided charges and payments do not appear.
  • “Paid” includes both patient and insurance side payments. The adjustments are split out into insurance and patient side.
  • “Pending” refers to amounts that are still considered receivable. It is computed by subtracting the paid and adjusted amounts from the charge amount.


To highlight and copy the code below to your clipboard, simply click the Copy button.

select at1.patno, birthdat, at1.invoiceno, at1.date1, at1.cptcode, at1.ins_carrier_code, at1.charge, at1.units, at1.trnsxno, at1.pos, at1.dxcode1, at1.dxcode2, at1.dxcode3, at1.dxcode4, at2.paid, at2.ins_adj, at2.pt_adj, round(charge-paid-ins_adj-pt_adj,2) as pending from
(select date1, patno, invoiceno, cptcode, ins_carrier_code, charge, trnsxno, pos, units, dxcode1, dxcode2, dxcode3, dxcode4 from archive_transactions where archive_flag = 1 and date1 between :Start_date and :enddate and cptcode not in ('1','2','3','4','PLA')) at1
inner join register on register.patno = at1.patno
left outer join
(select round(sum(p),2) as paid, sum(adjustment) as ins_adj, sum(copayadjustment) as pt_adj, txnopaid from
(select copayrecd, payment, copayrecd+payment as p, adjustment, copayadjustment, txnopaid from archive_transactions where archive_flag =1 )
group by txnopaid) at2
on at2.txnopaid = at1.trnsxno
order by patno, invoiceno