Identifying Accounts with Unapplied “Balance Forward” Amounts

During the conversion of data from the old DOS software to the Windows version of SOS, one option was to create a dummy payor called “Balance Forward” and initialize it with the total balance from the old software. Years later, some customers have had difficulties determining accurate account balances because of credit amounts that linger as unapplied payments attributed to the Balance Forward payor. The following query lists the accounts showing this issue.

SELECT 
  fullnameid, 
  licnum AS dataset, 
  (IF flag = 0 THEN 'active' ELSE 'inactive' ENDIF) AS PtList,
  SUM(crsplamt) AS Tot_Unapplied
FROM 
  sos.rv_creditsplits
WHERE 
  payornum = 2
AND 
  (chgsplnum = 0 OR chgsplnum IS NULL)
GROUP BY 
  fullnameid, licnum, ptlist
ORDER BY 
  fullnameid

Leave a Reply

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes:

<a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>

This site uses Akismet to reduce spam. Learn how your comment data is processed.