OK, where to start?????
The top two lines of EVERY code page should be
Code:
Option Compare Database
Option Explicit
"Option Explicit" requires variable declaration. This is good because you won't inadvertently type when "rs11" when you mean (ie "Fat Finger") "rs1". There were several undeclared variables.
You had the declaration for "Dim rs1 As DAO.Recordset" inside of a While Loop. I put all of my declarations at the top of the subroutine. Much easier to debug...
The recordset "rs1" was never explicitly closed.
--------------
I'm not sure I really understand your process, so here is what I did when I re-wrote your code. (the basics were there... just needed tweaking )
It sounds like you want to match positive and negative dollar amounts that are equal by the earliest (oldest) date. The "ID" doesn't matter. (poor choice for a field name, BTW)
As long as the dollar amounts match exactly, the "Matched" fields should be set to "Y".
Is this closer to what you want? (see dB)