Finding duplicate values in the same column

cwilliams96

Board Regular
Joined
Jul 27, 2003
Messages
186
I have 2 columns A & B

in column B there are hundreds of values but some of them potentially may be the same.

I wanted to have in say column A a flag that tells me if the value in column B exists elsewhere in the column B

i.e
A B
26548
15487
14789
45789
EXISTS 26548
72628
 

Excel Facts

Wildcard in VLOOKUP
Use =VLOOKUP("Apple*" to find apple, Apple, or applesauce

wob

Board Regular
Joined
May 21, 2002
Messages
105
in cell C1 put in the formula

=countif(B:B,B1)

and copy the formula down.

Any values greater than 1 are have been duplicated.
 

cwilliams96

Board Regular
Joined
Jul 27, 2003
Messages
186
Sorry I may have not expained correctly, the values in col B are letters and numbers

eg

JSC-34-352729

I wanted to put a phrase in the column a next to the duplicate value
 

pagrender

Well-known Member
Joined
Sep 3, 2008
Messages
652
Using Wob's formula:
=IF(COUNTIF($B$1:B1,B1)>1,"EXISTS","")

Paste this formula into cell A1 and drag it down. If your data starts in a different cell (A2, for example), change the cell references.

Pete
 

wilcowoods

Active Member
Joined
May 29, 2008
Messages
275
I have 2 columns A & B

in column B there are hundreds of values but some of them potentially may be the same.

I wanted to have in say column A a flag that tells me if the value in column B exists elsewhere in the column B

i.e
A B
26548
15487
14789
45789
EXISTS 26548
72628

Or you could use conditional formatting / highlight cell rules / duplicates if you just want to highlight the duplicate number!
 
Master Excel Bundle

Excel contains over 450 functions, with more added every year. That’s a huge number, so where should you start? Right here with this bundle.

Forum statistics

Threads
1,168,111
Messages
5,857,448
Members
431,880
Latest member
kar2rost

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Top