I have been banging my head on the wall over this one. I know there must be a solution. I have tried subqueries, inner joins, table aliases.....there is ALWAYS something wrong with my syntax!!
I have attached a sample from my table named 201299 ALL RECORDS.
ID is my primary key column and it autonumbers the records. EEID is a person, and there are many records per one person. DR is a debit entry for that person, CR is a credit entry for that person.
Is it possible to run one or both of the following queries?
1) A query that returns to me matching records(matching means where the debit equals the credit for a person). If the query ran on attached table, it should return to me records (beginning with ID number): 1, 3, 5, and 6. "First come first match(if there are two matching CR values it should return to me the earlier date CR match").....
2)A query that returns to me the opposite of what I defined in 1). A query that returns to me UNMATCHED records. If run on the attached table, the query should return to me records 2, 4, and 7.