Payments posted to invoice prior to invoice date (both AP and AR)

Good Morning!
Years ago, Sage support helped guide me with this problem when I had it once before, and in reaching out recently, they keep sending me info for transactions for prior year adjustments (no help).

As we all know, if a payment is posted prior to the invoice date, whether in AP or AR, it throws our GL Out-of-Balance. There is a way to do an inquiry in both AP and AR to help identify and find these issues so they can be fixed.  Unfortunately, I don't remember how.  When I search in the knowledgebase, it sends me to yearend procedures, and I can't find the answer in those guides.  Any assistance you can provide I would be forever appreciative.