INDEX AND MATCH #REF ERROR

Mina Persona

New Member
Joined
Feb 21, 2024
Messages
5
Office Version
  1. 365
  2. 2016
Platform
  1. Windows
Hello,

I am having error on some cells only when i try to use the below function and please see the below image:
=INDEX($A$2:$A$13,MATCH(I3,$B$2:$B$13,0),MATCH(1,IF(J3>=$C$2:$C$13,IF(J3<=$D$2:$D$13,1)),0))
 

Attachments

  • Book10 - Excel 21_02_2024 07_42_02.png
    Book10 - Excel 21_02_2024 07_42_02.png
    107 KB · Views: 6

Excel Facts

Which came first: VisiCalc or Lotus 1-2-3?
Dan Bricklin and Bob Frankston debuted VisiCalc in 1979 as a Visible Calculator. Lotus 1-2-3 debuted in the early 1980's, from Mitch Kapor.
Welcome to the MrExcel board!

For the future: You will get faster and better responses if you can give us sample data in a form we can copy & test with.

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.

Try this formula in cell H2 and copy down
Excel Formula:
=FILTER(A$2:A$13,(B$2:B$13=I2)*(C$2:C$13<=J2)*(D$2:D$13>=J2),"")
 
Upvote 0
Hi,

Thank you for the guidance and support, the filter function is not available in my ms office could you please help with another alternative.
 
Upvote 0
Welcome to the MrExcel board!

For the future: You will get faster and better responses if you can give us sample data in a form we can copy & test with.

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.

Try this formula in cell H2 and copy down
Excel Formula:
=FILTER(A$2:A$13,(B$2:B$13=I2)*(C$2:C$13<=J2)*(D$2:D$13>=J2),"")
Book10.xlsx
ABCDEFGHIJ
1POLICY NOCLIENT NAMESTART DATEEND DATEPOLICY NOCLIENT NAMECLAIM DATE
2AMI/CMED/00076/2023/1Client 101-Jul-2330-Jun-24AMI/CMED/00059/2022/1Client 24-Jul-23
3AMI/CMED/00059/2022/1Client 201-Oct-2230-Sep-23#REF!Client 226-Nov-22
4AMI/CMED/00059/2022/2Client 201-Oct-2330-Sep-24#REF!Client 220-Feb-23
5AMI/CMED/00030/2021/1Client 301-Aug-2131-Jul-22#REF!Client 221-Feb-23
6AMI/CMED/00030/2021/2Client 301-Aug-2231-Jul-23#REF!Client 21-Apr-23
7AMI/CMED/00030/2021/3Client 301-Aug-2331-Jul-24AMI/CMED/00059/2022/1Client 23-Sep-23
8AMI/CMED/00076/2023/1Client 118-Oct-23
9AMI/CMED/00076/2023/1Client 118-Oct-23
10#REF!Client 33-Jul-22
11#REF!Client 319-Jan-22
12#REF!Client 314-Apr-22
13#REF!Client 325-Apr-22
Sheet1
Cell Formulas
RangeFormula
H2:H13H2=INDEX($A$2:$A$13,MATCH(I2,$B$2:$B$13,0),MATCH(1,IF(J2>=$C$2:$C$13,IF(J2<=$D$2:$D$13,1)),0))
Press CTRL+SHIFT+ENTER to enter array formulas.
Cells with Conditional Formatting
CellConditionCell FormatStop If True
A:ACell ValueduplicatestextNO
 
Upvote 0
try this, you may need to enter the formula with the CNTL-SHFT-ENTR (CSE) Keystroke:
Excel Formula:
=INDEX($A$2:$A$13,
SUM(($C$2:$C$13<=J2)*($D$2:$D$13>=J2)*(I2=$B$2:$B$13)*(ROW($B$2:$G$13)-ROW($B$2)+1)))
 
Upvote 0
try this, you may need to enter the formula with the CNTL-SHFT-ENTR (CSE) Keystroke:
Excel Formula:
=INDEX($A$2:$A$13,
SUM(($C$2:$C$13<=J2)*($D$2:$D$13>=J2)*(I2=$B$2:$B$13)*(ROW($B$2:$G$13)-ROW($B$2)+1)))
Thanks for the contribution but i think this just work on the first argument ($C$3:$C$8=I2), i think it is not checking if the date is between two dates.
 
Upvote 0
Try:

Excel Formula:
=IFERROR(LOOKUP(2,1/($B$2:$B$7=I2)/(J2>=$C$2:$C$7)/(J2<=$D$2:$D$7),$A$2:$A$7),"No policy match")
 
Upvote 1
Solution
Glad we could help. :)
 
Upvote 0
Did you test it out? I find it does. The formula I suggested returns the same results as RoryA's. It just isn't an array formula.
But you have an answer which was you came for. Best Wishes.
 
Upvote 0

Forum statistics

Threads
1,215,078
Messages
6,122,996
Members
449,093
Latest member
masterms

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