Vlookup multiple criteria

brandon16

Board Regular
Joined
Sep 29, 2014
Messages
133
Hi,
I am trying to create a vlookup based on multiple criteria but not quite sure how best to do this. I tried this formula but doesn't output how I want it to.

=VLOOKUP(G1055&B1055,'App Lookup'!$G$23:$J$36,3)

Below is my lookup table, tab called App Lookup.

My App_Data tab needs to be something like:

if app_no = 78 regardless of app_name then App Declined
if app_no = 85 regardless of app_name then App Declined
if app_no = 85 AND app_name = MOR then App Comp
else ignore app_no and where it matches the APP_NAME value then Output_Description

App_NameApp_NoOutput_Description
78App Declined
85App Declined
MOR85App Comp
MORApp Comp
PUPApp Processing
ETSApp Withdrawn
 

Excel Facts

How to total the visible cells?
From the first blank cell below a filtered data set, press Alt+=. Instead of SUM, you will get SUBTOTAL(9,)
What version of Excel are you using? The version often dictates which approach(s) need to be taken for the solution to work for you. Please update your account details with that information.

Can you explain what information is found in the cells/ranges referenced in:
Excel Formula:
=VLOOKUP(G1055&B1055,'App Lookup'!$G$23:$J$36,3)
I'm assuming 'App Lookup'!$G$23:$J$36 refers to the table you've described, but that table consists of three columns and the range referenced refers to four columns (G:J), and you appear to want the third column returned. I am confused about the lookup range referenced, which covers 14 rows (23:36), while the lookup table you've shown has 6 rows. Could you clarify what information is where and whether you are showing only a small example of a larger set of lookup criteria. Also, what is G1055&B1055 intended to do?

It is likely that VLOOKUP is not suitable for this task, as it requires the lookup table to be sorted in ascending order.
 
Upvote 0
I'm not clear about what you really want to do, but I think it might be easier to construct a formula that handles the exceptions with IF statements, and then after confirming that none of those apply, revert to a simple INDEX/MATCH formula. Then it would be better to restructure the lookup table (for the INDEX/MATCH) to eliminate those combinations that are already handled by the IF statements. So the lookup table looks like this:
MrExcel_20230706.xlsx
GHI
22App_NameApp_NoOutput_Description
23MORApp Comp
24PUPApp Processing
25ETSApp Withdrawn
26
27
28
App Lookup

...and the main table like this:
MrExcel_20230706.xlsx
BGH
1054App #App NameOutput
105578App Declined
105685MORApp Comp
1057PUPApp Processing
1058MORApp Comp
1059ETSApp Withdrawn
10606MORApp Comp
10611PUPApp Processing
106285ETSApp Declined
App_Data
Cell Formulas
RangeFormula
H1055:H1062H1055=IF(AND(B1055=85,G1055="MOR"),"App Comp",IF(OR(B1055=78,B1055=85),"App Declined",INDEX('App Lookup'!$I$23:$I$30,MATCH(G1055,'App Lookup'!$G$23:$G$30,0))))
 
Upvote 0

Forum statistics

Threads
1,223,888
Messages
6,175,215
Members
452,618
Latest member
Tam84

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