I have a database related question. When a customer charges a sale, the transaction information gets written to the AccountReceivable table, and the original amount and the balance at that point are the same amount. However when the customer pays the balance off, does this affect the record that was originally written to the AR table. Shouldn't it change the balance to 0.00 in the database table? If not, where does it get recorded in the database that this particular charge sale has been paid?
I need to know because I am putting together a commission table and want to mark the charge sales as either paid or unpaid, and thought I could do it this way:
CASE WHEN AccountReceivable.Balance > 0 THEN 'Unpaid' ELSE 'Paid' END
However, there is an invoice showing up as 'Unpaid', but when we go into the customer properties and look at the account information for this customer, it shows that this invoice was paid over two weeks ago
thank you, kevin