Comparing Columns 1 & 2 vs. Columns 3 & 4

bondra76

New Member
Joined
May 6, 2012
Messages
14
Got two sets of data that I want to compare against each other. Here's what the data sets look like -

Contract #SupplierApproved?ServiceLookupKey
1ABC CompanyYesTrash Removal1;Trash Removal
1ABC CompanyYesLandscaping1; Landscaping
2Bobs CompanyNoLandscaping
3XYZ CompanyYesArborist3; Arborist

<tbody>
</tbody>

I created a lookupkey that's a simple if statement to check if the contract is approved; if it is then Contract # and service are combined and a lookup key is populated. I need to filter out the non-approved contracts.

In table 2, I am trying to illustrate what services the supplier is approved to do:

Contract #SupplierArboristLandscapingTrash Removal
1ABC CompanyFALSETRUETRUE
2Bobs CompanyFALSEFALSEFALSE
3XYZ CompanyTRUEFALSEFALSE

<tbody>
</tbody>

The TRUE/FALSE results are what I am after....

Right now I have the following formula in the TRUE/FALSE cells (C2:E:4) -
=SUMPRODUCT(--ISNUMBER(SEARCH(LookupKey,$A2&";"&C$1)))>0

I think the second part of my search formula is throwing everything off with the text joins, but not sure how else to do this. Maybe it's as simple as a formatting issue?

Thanks for any help in advance!!!!
 

Excel Facts

Links? Where??
If Excel says you have links but you can't find them, go to Formulas, Name Manager. Look for old links to dead workbooks & delete.
Can this be done without the lookup key (everything matched in the sample but perhaps there's more)?


Excel 2010
ABCDE
1Contract #SupplierApproved?ServiceLookupKey
21ABC CompanyYesTrash Removal1;Trash Removal
31ABC CompanyYesLandscaping1; Landscaping
42Bobs CompanyNoLandscaping
53XYZ CompanyYesArborist3; Arborist
6
7
8Contract #SupplierArboristLandscapingTrash Removal
91ABC Company011
102Bobs Company000
113XYZ Company100
Sheet30
Cell Formulas
RangeFormula
C9=SUMPRODUCT(--($B$2:$B$5=$B9),--($D$2:$D$5=C$8),--($C$2:$C$5="Yes"))
 
Upvote 0
Pasting your first table into A1 of Sheet1 and the second into A1 or Sheet2 use this formula in C2 of Sheet2 and copy down and across:

=IFERROR(IF(LOOKUP(2,1/((Sheet1!$B:$B=$B2)*(Sheet1!$A:$A=$A2)*(Sheet1!$D:$D=C$1)),Sheet1!$C:$C)="Yes",TRUE,FALSE),FALSE)
 
Upvote 0

Forum statistics

Threads
1,216,799
Messages
6,132,770
Members
449,760
Latest member
letonuslepus

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