SQL invoice balances without double counting by Jasper AddymanSQL invoice balances without double counting by Jasper Addyman

SQL invoice balances without double counting

Portfolio project
Jasper Addyman
Original studio demonstration using fictional data. I built a sample invoice report that reproduced inflated totals when invoice lines and payments were joined directly. I fixed the query by aggregating each table before joining, and tested that unpaid invoices still appeared. The reconciled report showed GBP 350 billed, GBP 180 paid and GBP 170 outstanding. The handover includes a reproducible SQLite fixture, a read-only query and checks against the expected totals.

0 likes · 0 views · Nov 10, 2026

SQL demo correcting duplicated invoice totals and retaining unpaid invoices, with reconciled balances.

Tags