Index or Xlookup 2 criteria, but 1 of them includes >=

amyj22x3

New Member
Joined
Jul 24, 2018
Messages
14
Office Version
  1. 365
Platform
  1. Windows
I need to find a way to match the Agent Type and ACHIEVED goal in a different sheet, but the payouts are as follows:

The problem is most of the time an agent hits their goal, but their achieved goal falls between 2 target goal tiers. So the problem is their achieved goal is 6,600 I need the returned incentive to be 100 since they didn't make it to the 2nd tier of 7,000

I've tried all combinations of index(match, vlookup, xlookup and so on, but because I have to match the Agent Type exactly, but the Goal approximately I can't get the right answer.

Agent TypeGoal TargetIncentive
1 MO6,500100
1 MO7,000110
Agent26,000200
Agent29,000300
Sr. Agent27,000250
Sr. Agent29,000300
 
try this:
Book1
ABCDEF
1Agent TypeTarget GoalIncentiveAgent Type:1 MO
21 MO6,500100Sales6,600
31 MO7,000110Incentive:100
4Agent26,000200
5Agent29,000300
6Sr. Agent27,000250
7Sr. Agent29,000300
Sheet2
Cell Formulas
RangeFormula
F3F3=LET(vl,FILTER($A$2:$C$7,$A$2:$A$7=$F$1,""),s,CHOOSECOLS(vl,2),I,CHOOSECOLS(vl,3), XLOOKUP($F$2,s,I,"",-1))
Cells with Data Validation
CellAllowCriteria
F1List=$A$2:$A$7
OMG, this worked brilliantly! Thank you SO MUCH!
 
Upvote 0

Excel Facts

How to find 2nd largest value in a column?
MAX finds the largest value. =LARGE(A:A,2) will find the second largest. =SMALL(A:A,3) will find the third smallest
OMG, this worked brilliantly! Thank you SO MUCH!
You're welcome.
Best Wishes!

PS you may need to fine tune the XLOOKUP function with a 0 instead of "" for the 'if not found' argument. Otherwise you'll get blanks for folks that do not make the bottom threshold of sales amount.
 
Upvote 0
You're welcome.
Best Wishes!

PS you may need to fine tune the XLOOKUP function with a 0 instead of "" for the 'if not found' argument. Otherwise you'll get blanks for folks that do not make the bottom threshold of sales amount.
And that's my desired outcome. You either hit goal, or you don't. You have no idea how great I feel right now! I've been struggling for hours today and yesterday. Never, would I have thought that formula on my own.
 
Upvote 0

Forum statistics

Threads
1,221,618
Messages
6,160,847
Members
451,674
Latest member
TJPsmt

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