Greater than less than with matching variables and maybe vlookup?

NUppal

New Member
Joined
Aug 4, 2021
Messages
8
Office Version
  1. 365
Platform
  1. Windows
Hi there! I've been struggling with this formula for a couple of days now and I keep deleting it and starting over.

This is the chart on a separate tab named "Notice Weeks" that I need to lookup. I highlighted all the information and named it severance5

1628092401382.png


This is my first tab (CA Tracker) where I will be filling column CO with the formula, I have the same entity column, and work state column as in the 2nd tab with the chart (Notice Weeks).
I'm dealing with looking up information in a chart on another tab and having that input into the first tab.

1628092443656.png


example of 1 scenario:

I basically need to say if entity is (column A), and work state is (column AN) and the years of service (column CH) is greater than (column D in "Notice Weeks") and less than (Column E in "Notice Weeks"), the notice period will be (Column C in "Notice Weeks"). That will be filed into column CO.

Would someone be able to assist me with this? Tried googling/youtubing but it's been a fail.
 

Excel Facts

Round to nearest half hour?
Use =MROUND(A2,"0:30") to round to nearest half hour. Use =CEILING(A2,"0:30") to round to next half hour.
Hi & welcome to MrExcel.
Is the dat on the Notice weeks sheet a structured table? If so what is it called?
 
Upvote 0
Ok, how about
Excel Formula:
=FILTER(severance5[Notice Period],(severance5[Entity]=A2)*(severance5[Work State]=AN2)*(severance5[Min Weeks]<=CH2)*(severance5[Max Weeks]>=CH2))
 
Upvote 0
Solution
Ok, how about
Excel Formula:
=FILTER(severance5[Notice Period],(severance5[Entity]=A2)*(severance5[Work State]=AN2)*(severance5[Min Weeks]<=CH2)*(severance5[Max Weeks]>=CH2))

I tried, but the error #CALC! shows up.
 
Upvote 0
In that case can you post the data from the severance table.

MrExcel has a tool called “XL2BB” that lets you post samples of your data that will allow us to copy/paste it to our Excel spreadsheets, so we can work with the same copy of data that you are. Instructions on using this tool can be found here: XL2BB Add-in

Note that there is also a "Test Here” forum on this board. This is a place where you can test using this tool (or any other posting techniques that you want to test) before trying to use those tools in your actual posts.
 
Upvote 0
Looking at your image again are the values in col CH text or numbers? Judging by the warning triangle they are probably text.
 
Upvote 0
Looking at your image again are the values in col CH text or numbers? Judging by the warning triangle they are probably text.
They are numbers. I have a formula in for that column
 
Upvote 0
In that case please see post#6
 
Upvote 0

Forum statistics

Threads
1,214,827
Messages
6,121,806
Members
449,048
Latest member
greyangel23

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