What formula can I use?

fafo1182

New Member
Joined
Mar 19, 2024
Messages
1
Office Version
  1. 365
Platform
  1. Windows
If I have two sheets with lists of names and want to create a third sheet with a list of duplicate names on the first two sheets. Is there a way to do it?
 

Excel Facts

What is the fastest way to copy a formula?
If A2:A50000 contain data. Enter a formula in B2. Select B2. Double-click the Fill Handle and Excel will shoot the formula down to B50000.
I'm sure there is probably a shorter formula that gets your desired result. But, this is what I've come up with:

Book1
ABCDE
1Sheet1Sheet2more than once
2Name1Name3Name3
3Name2Name4Name4
4Name3Name5
5Name4Name6
Sheet1
Cell Formulas
RangeFormula
E2:E3E2=LET(a,A2:A5,b,C2:C5,c,VSTACK(a,b),d,UNIQUE(c,,TRUE),e,UNIQUE(c,,FALSE), f,--(TRANSPOSE(d)=e),g,(--(BYROW(f,LAMBDA(f,SUM(f)))=0)),FILTER(e,g,""))
Dynamic array formulas.
 
Upvote 0
I'm sure there is probably a shorter formula ...
=FILTER(A2:A5,ISNUMBER(MATCH(A2:A5,C2:C5,)),"n/a")

(I've interpreted the question the same way, i.e. "duplicate names" means names appearing on Sheet 1 and Sheet 2)
 
Upvote 0

Forum statistics

Threads
1,215,110
Messages
6,123,149
Members
449,098
Latest member
Doanvanhieu

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
Back
Top