Finding Duplicates across Multiple Tabs

mmac723

New Member
Joined
Jun 18, 2019
Messages
12
I'm trying to label rows as "Duplicate" in Column Q if i have a duplicate phone number in Column G across multiple tabs. I'm struggling with the formula.
So far, I have:
=IF(COUNTIFS($G$8:$G$2020, G8, 'FW 4'!$G$8:$G$2020, G8),>1,"Duplicated","")

But it's not recognizing the second Criteria Range from another tab.
What am I doing wrong?

Thanks y'all!
 

Excel Facts

Save Often
If you start asking yourself if now is a good time to save your Excel workbook, the answer is Yes

JLGWhiz

Well-known Member
Joined
Feb 7, 2012
Messages
12,979
Office Version
  1. 2013
Platform
  1. Windows
Code:
=IF( COUNTIFS($G$8:$G$2020,G8,'FW 4'!$G$8:$G$2020,'FW 4'!G8)>1,"Duplicated","")
plus remove the comma after the last parentesis.
 

JLGWhiz

Well-known Member
Joined
Feb 7, 2012
Messages
12,979
Office Version
  1. 2013
Platform
  1. Windows
If you are trying to evaluate G8 of the first sheet against both sheets, then in the second part of the CountIfs, use the first Sheet name with the G8:
Code:
=IF( COUNTIFS($G$8:$G$2020,G8,'FW 4'!$G$8:$G$2020,Sheet1!G8)>1,"Duplicated","")
But with no sheet specified, Excel gets confused about which G8 you really want to evaluate.
 

mmac723

New Member
Joined
Jun 18, 2019
Messages
12
If you are trying to evaluate G8 of the first sheet against both sheets, then in the second part of the CountIfs, use the first Sheet name with the G8:
Code:
=IF( COUNTIFS($G$8:$G$2020,G8,'FW 4'!$G$8:$G$2020,Sheet1!G8)>1,"Duplicated","")
But with no sheet specified, Excel gets confused about which G8 you really want to evaluate.


Thank you for your response!
I've tried it, and it doesn't seem to be working. The 'FW 4'! Range is what's not being recognized.... So it's not reading that G8 in FW 5 is a duplicate on that sheet now. (Does that make sense?)
 

JLGWhiz

Well-known Member
Joined
Feb 7, 2012
Messages
12,979
Office Version
  1. 2013
Platform
  1. Windows

ADVERTISEMENT

Read Post #3 also. it gives further explanation about using a sheet name with the second G8 reference. Note in my example that it is completely different than that in your post #4. If you post the sheet name for your active sheet, I will write the correct formula for you to copy and paste into the cell.
 

mmac723

New Member
Joined
Jun 18, 2019
Messages
12
Read Post #3 also. it gives further explanation about using a sheet name with the second G8 reference. Note in my example that it is completely different than that in your post #4. If you post the sheet name for your active sheet, I will write the correct formula for you to copy and paste into the cell.

I tried both, and neither gave me the correct answer, or an error code for that matter. The cell is just blank (And I have duplicates in the field to test the formula.)

Is there a better formula to work, like MATCH?
 

JLGWhiz

Well-known Member
Joined
Feb 7, 2012
Messages
12,979
Office Version
  1. 2013
Platform
  1. Windows

ADVERTISEMENT

They worked for me, so I don't know what else to offer at this point.
Regards, JLG
 

Peter_SSs

MrExcel MVP, Moderator
Joined
May 28, 2005
Messages
49,397
Office Version
  1. 365
Platform
  1. Windows
If you want to know if the phone number appears on the same row in each sheet (that is 'FW 4' and the sheet the formula is on) then all you should need is
=IF(AND('FW 4'!G8=G8,G8<>""),"Duplicated","")

If you want to know if the same phone number appears anywhere in column G of both sheets (that is 'FW 4' and the sheet the formula is on) then
=IF(COUNTIF('FW 4'!$G$8:$G$2020,G8),"Duplicated","")
 

Forum statistics

Threads
1,136,210
Messages
5,674,420
Members
419,508
Latest member
trinstrick

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