Return "yes" or "no" matching multiple criteria

MG137

New Member
Joined
Nov 15, 2023
Messages
3
Office Version
  1. 2016
Platform
  1. Windows
Good Afternoon,

I am trying to find a formula, function, anything really that can take the ID and Amount columns on the submissions list and return a "yes" or "no" if a row matching both criteria are found on the results list. The original lists have over 7 thousand rows so a side by side comparison would be time consuming and it is a task that will need to be completed on a weekly basis so I am looking for something that will help me find the items missing from the results list more efficiently. Any help would be appreciated.

1700092314391.png

1700092396168.png
 

Excel Facts

What does custom number format of ;;; mean?
Three semi-colons will hide the value in the cell. Although most people use white font instead.
Are you looking for something like this

PERSONAL.xlsm
ABCD
1 ID AMT
2 TD11 1,000.00
3 HK55 500.00
4 JK12 450.00
Submission List


PERSONAL.xlsm
ABCDEF
1 ID Current Period Result
2 TD11 1,000.00Yes
3 HK55 650.00No
4 JK12 450.00Yes
Result List
Cell Formulas
RangeFormula
F2:F4F2=IF(XLOOKUP(A2,'Submission List'!$A$2:$A$4,'Submission List'!$D$2:$D$4)='Result List'!E2,"Yes","No")
 
Upvote 0
Thank you for that response but it turns out I have a different version of excel than I thought so this will not work for me. Is there an alternative to XLookUp for Excel 2016?
 
Upvote 0
Maybe this:

VBA Code:
=IF(VLOOKUP(A2,'Submission List'!A1:D4,4,FALSE)=E2,"Yes","No")


PERSONAL.xlsm
ABCDEF
1 ID Name Type AMT
2 TD11 A B 1,000.00
3 HK55 A B 500.00
4 JK12 A B 450.00
5
6
Submission List


PERSONAL.xlsm
ABCDEFG
1 ID Name Type Data Current Period Result Match Found
2 TD11 A B C 1,000.00Yes
3 TD11 A B C 999.00No
4 JK12 A B C 450.00Yes
5
Result List
Cell Formulas
RangeFormula
F2:F4F2=IF(VLOOKUP(A2,'Submission List'!A1:D4,4,FALSE)=E2,"Yes","No")


You will need to adjust the lookup range since you mentioned having about 7k rows.
 
Upvote 0
Amount is generally not an ideal way of looking something up. In your data, you have IDs appearing multiple times.
If those multiple IDs then also have the same amount then the lookup will not necessarily give you the right result.
An additional complication is that you have numbers as text, this adds risk of the number being text on one sheet but a number on the other sheet.
Countifs (Sumifs etc) tend to be more forgiving on text-number mismatches.
I have included an option of doing 2 Countifs so that there are multiple ID/Amt lines it also matches how many on each sheet.

Here are some options, if they slow your spreadsheet down too much you might need to consider using VBA or Power Query.

20231116 Lookup 2 fields 2016 MG137.xlsx
ABCDEFGHIJ
1 ID AMT FileSourceCountifsLookupCountifs x2 Matching CountComment
2 TD11 1000YesYesYes
3 HK55 500NoNoNo
4 JK12 450YesYesYes
5XXXX100YesYesYes
6AAA200YesYesCheckResults has AAA/200 twice
7005950YesNoYesCountifs is more forgiving with data types ie Text here but Number in Result List
8BBB99YesYesCheckResults has BBB/99 once but it is here twice
9BBB99YesYesCheckResults has BBB/99 once but it is here twice
Submission List
Cell Formulas
RangeFormula
G2:G9G2=IF(COUNTIFS('Result List'!$A$2:$A$9,$A2,'Result List'!$E$2:$E$9,$D2),"Yes","No")
H2:H9H2=IF(ISNA(LOOKUP(2,1/(('Result List'!$A$2:$A$10=$A2)*('Result List'!$E$2:$E$10=$D2)),'Result List'!$A$2:$A$10)),"No","Yes")
I2:I9I2=IF(COUNTIFS('Result List'!$A$2:$A$9,$A2,'Result List'!$E$2:$E$9,$D2),IF(COUNTIFS('Result List'!$A$2:$A$9,$A2,'Result List'!$E$2:$E$9,$D2)=COUNTIFS($A$2:$A$10,$A2,$D$2:$D$10,$D2),"Yes","Check"),"No")



20231116 Lookup 2 fields 2016 MG137.xlsx
ABCDE
1 ID Current Period Result
2 TD11 1000
3 HK55 650
4 JK12 450
5XXXX100
6AAA200
7AAA200
85950
9BBB99
Result List
 
Upvote 0
Thank you both. I agree about using the amount and ID fields but my lists are combined data from about 12 other sheets and the ID and amount fields are the only consistent fields across all reports, leaving them to be the only fields I can use for this task.

I will try both suggestions.
 
Upvote 0

Forum statistics

Threads
1,215,087
Messages
6,123,050
Members
449,092
Latest member
ikke

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