Unique Filter Code / Advanced Filter

  • Thread starter Thread starter Fester
  • Start date Start date
F

Fester

I have a database of information. I want to remove all duplicate
entries for each patient. For some reason, the advanced filter -
uniques only, still shows duplicate names. I've checked with =A2=B2
and it comes back True.

Any suggestions on how to fix or is there VBA code that will give me
the same result?

Brendon
 
Does your table that you are using in the advanced filter only have one
column?

If not you need to look at the whole table. If you for instance have


Names Numbers
Mr X 1
Mr X 2
Mr Y 3
Mr Z 4

and use that table and select unique records only, then all those entries
are unique.

Is that what you did?

If it is you need to use a criteria range

Use a 2 cell criteria, assume the names start in A4 with the header so the
data starts in A5 and that H1:H2 is the criteria range, leave H1 blank in H2
put

=COUNTIF($A$5:A5,A5)=1


select the table, do data>filter>advanced filter, DON'T select
unique records, put $H$1:$H$2 in the criteria range and select copy
to another location

That will give you this list


Names Numbers
Mr X 1
Mr Y 3
Mr Z 4






--


Regards,


Peo Sjoblom
 

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

Back
Top