Formula to identify if a range does not match other ranges

Stuepef

Board Regular
Joined
Oct 23, 2017
Messages
128
Office Version
  1. 2021
Platform
  1. Windows
I have a spreadsheet (6 sheets) that allows users to manually enter information within the same range for each sheet. The user can enter the information in any of the specified ranges $K$33:$M$49 on sheets 1-6. I am looking to establish a formula that does two things:
  1. Analyze whether all of the ranges are an exact match or not
  2. If they do not match exact, then the formula will provide a numeric value of the mismatched range (for instance, if range 3 on sheet 3 does not match then the formula will provide a 3)
The range to compare whether the ranges on sheets 1-6 are a match is Sheet1$G$33:$!$49. The other ranges are the same, but just on separate sheets. The other ranges to compare are:
  1. Sheet1$K$33:$M$49
  2. Sheet2$K$33:$M$49
  3. Sheet3$K$33:$M$49
  4. Sheet4$K$33:$M$49
  5. Sheet5$K$33:$M$49
  6. Sheet6$K$33:$M$49
I have tried many different formulas. I thought a simple nest IF statement would be a solution, but I ran into #SPILL errors. Here are a couple alternative formulas I tried:
IFERROR(INDEX({"RANGE 1","RANGE 2","RANGE 3","RANGE 4","RANGE 5","RANGE 6","MATCH"},MATCH(TRUE,('Sheet1'!$G$33:$I$49<>'Sheet1'!$K$33:$M$49)+('Sheet1'!$G$33:$I$49<>'Sheet2'!$K$33:$M$49)+('Sheet1'!$G$33:$I$49<>'Sheet3'!$K$33:$M$49)+('Sheet1'!$G$33:$I$49<>'Sheet4'!$K$33:$M$49)+('Sheet1'!$G$33:$I$49<>'Sheet5'!$K$33:$M$49)+('Sheet1'!$G$33:$I$49<>'Sheet6'!$K$33:$M$49)>0,0)),"MATCH")
CHOOSE(SUMPRODUCT(--('Sheet1'!$G$33:$I$49<>'Sheet1'!$K$33:$M$49), --('Sheet1'!$G$33:$I$49<>'Sheet2'!$K$33:$M$49), --('Sheet1'!$G$33:$I$49<>'Sheet3'!$K$33:$M$49), --('Sheet1'!$G$33:$I$49<>'Sheet4'!$K$33:$M$49), --('Sheet1'!$G$33:$I$49<>'Sheet5'!$K$33:$M$49), --('Sheet1'!$G$33:$I$49<>'Sheet6'!$K$33:$M$49)), "RANGE 1", "RANGE 2", "RANGE 3", "RANGE 4", "RANGE 5", "RANGE 6", "MATCH")
IF(OR('Sheet1'!$G$33:$I$49<>'Sheet1'!$K$33:$M$49,'Sheet1'!$G$33:$I$49<>'Sheet2'!$K$33:$M$49,'Sheet1'!$G$33:$I$49<>'Sheet3'!$K$33:$M$49,'Sheet1'!$G$33:$I$49<>'Sheet4'!$K$33:$M$49,'Sheet1'!$G$33:$I$49<>'Sheet5'!$K$33:$M$49,'Sheet1'!$G$33:$I$49<>'Sheet6'!$K$33:$M$49),CHOOSE(MAX(('Sheet1'!$G$33:$I$49<>'Sheet1'!$K$33:$M$49)+('Sheet1'!$G$33:$I$49<>'Sheet2'!$K$33:$M$49)+('Sheet1'!$G$33:$I$49<>'Sheet3'!$K$33:$M$49)+('Sheet1'!$G$33:$I$49<>'Sheet4'!$K$33:$M$49)+('Sheet1'!$G$33:$I$49<>'Sheet5'!$K$33:$M$49)+('Sheet1'!$G$33:$I$49<>'Sheet6'!$K$33:$M$49)*1), "RANGE 1","RANGE 2","RANGE 3","RANGE 4","RANGE 5","RANGE 6"),"MATCH")

Even if one cell is different in Sheet1-Sheet6 compared to Sheet1$G$33:$I$49, then I would like the formula to provide a 1-6 to signify which range is the mismatch. Below, cell M38 on Sheet1 does not match so the formula would provide a 1 signfying the first range is not a match.

1695240862963.png
 

Excel Facts

Highlight Duplicates
Home, Conditional Formatting, Highlight Cells, Duplicate records, OK to add pink formatting to any duplicates in selected range.

Forum statistics

Threads
1,223,903
Messages
6,175,284
Members
452,630
Latest member
OdubiYouth

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