How to identify inconsistent data?

TomC4

New Member
Joined
Nov 27, 2016
Messages
4
Imagine I have a spreadsheet with three columns: Property ID, Property Owner, Contract Type. Multiple properties can have the same owner. Each property belonging to a single owner should have the same Contract Type. I have a big spreadsheet with data like this. Is there a way I can identify Property Owners that do not have the same Contract Type associated with each of their properties?

Here is an example to help clarify. Property Owner B's data looks good because each of her two properties have the same Contract Type. But Property Owner A's data should be flagged for review because she has properties with different Contract Types.

Mr Excel Example.png
 

Excel Facts

Did you know Excel offers Filter by Selection?
Add the AutoFilter icon to the Quick Access Toolbar. Select a cell containing Apple, click AutoFilter, and you will get all rows with Apple
What version of Excel are you using? (Would be good to update your profile) The answer for Excel 365 might be different than older versions.
 
Upvote 0
Here is one way. Add a column and use this starting in row 2

Excel Formula:
=IF(COUNTIFS(B:B,B2,C:C,C2)<>COUNTIF(B:B,B2),"Review","")
The row will show REVIEW if the owner in that row has more than one type of contract. This assumes the columns you showed us are A, B, C.
 
Upvote 0
Solution
Here is one way. Add a column and use this starting in row 2

Excel Formula:
=IF(COUNTIFS(B:B,B2,C:C,C2)<>COUNTIF(B:B,B2),"Review","")
The row will show REVIEW if the owner in that row has more than one type of contract. This assumes the columns you showed us are A, B, C.
This code worked fabulously. Sorry for the late reply. Thank you!
 
Upvote 0

Forum statistics

Threads
1,223,952
Messages
6,175,596
Members
452,657
Latest member
giadungthienduyen

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