duplicates query

G

Guest

I have a find duplicate query which selects matches on 3 fields. How can I
add the ability to exclude matching pairs (or triplets, quadruplets, etc.)
which have all matching values in a 4th field?

Example: select all records which have matches on invoice #, vendor #, and
amount with different "status".

Keep it simple, since I am not SQL savvy.

Thanks.

JW


JW
 
M

Michel Walsh

Hi,


Bring the table in a new query, bring the 3 fields that defines "uniqueness"
in the grid. Click on the summation button on the toolbar, a new line,
Total, would appear in the grid. Keep the proposed GROUP BY for the 3 fields
already in place. In a new column of the grid, first line, type:

COUNT(*)

change the line Total from the proposed GROUP BY to EXPRESSION


uncheck the SHOW,

add the criteria : > 1



That's all.


If 4 fields defined uniqueness, bring the fourth field in the grid, and keep
the proposed GROUP BY. That's all, again.




Hoping it may help,
Vanderghast, Access MVP
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top