Match Index array formula

vmjan02

Well-known Member
Joined
Aug 15, 2012
Messages
1,059
Office Version
  1. 365
  2. 2021
  3. 2019
  4. 2016
  5. 2013
I am not getting the desired out with this array formula (Column D is phone num, Column G is count, column H is D&C, column J is amount

{=IF((Sheet2!$D$5:$D$800000>=$B$3)*(Sheet2!$G$5:$G$800000<=$D$2)*(Sheet2!$H$2:$H$800000=$B$3&$D$2),Sheet2!$J$5:$J$80000)}

In sheet1 it should search B3 (phonenumber) and D2 (count) and should show the amount.


PhonStID Country Count Phone CR Amot
9768146004 370 US1 97681460041 XX 200
300
400
5000

<colgroup><col><col><col><col><col><col><col></colgroup><tbody>
</tbody>
 

Excel Facts

Copy a format multiple times
Select a formatted range. Double-click the Format Painter (left side of Home tab). You can paste formatting multiple times. Esc to stop
Have tried this array formula,

={INDEX(Sheet2!$J$5:$J$1041149,SMALL(IF(VALUE($B$3&$D$2)=Sheet2!$H$5:$H$1041149,ROW(Sheet2!$H$5:$H$1041149)-MIN(ROW(Sheet2!$H$5:$H$1041149))+1,""""),ROW(A1)))}

It is only giving me 200, but as I drag the formula then it is giving me [URL=https://www.mrexcel.com/forum/usertag.php?do=list&action=hash&hash=Num]#Num [/URL] error

C3 200 (array formula is working correctly)
C4 [URL=https://www.mrexcel.com/forum/usertag.php?do=list&action=hash&hash=Num]#Num [/URL] I am not sure is the error because value B3&D3 only once in column H?
C5 [URL=https://www.mrexcel.com/forum/usertag.php?do=list&action=hash&hash=Num]#Num [/URL]
C6 [URL=https://www.mrexcel.com/forum/usertag.php?do=list&action=hash&hash=Num]#Num [/URL]
C7 [URL=https://www.mrexcel.com/forum/usertag.php?do=list&action=hash&hash=Num]#Num [/URL]

Help will be great. Thanks
 
Upvote 0
Would you please provide a 5 row input and the desired output for that input without reference to any formula you might have?
 
Upvote 0
PhonStIDCountryCountPhoneCRAmot
9768146004370US197681460041XX200
300
400
5000

<tbody>
</tbody>



search from col (Phone) Output
97681460041 200 (Cell C1
300 (cell c2)
400 (Cell c3)
5000 (cell c4)


Would you please provide a 5 row input and the desired output for that input without reference to any formula you might have?
 
Last edited:
Upvote 0
I'm sorry I don't follow...



Book1
ABCDEFG
1PhonStIDCountryCountPhoneCRAmot
29768146004370US197681460041XX200
3300
4400
55000
Sheet1


What is the data (input) here and what is the output?
 
Upvote 0
Sheet2 is the data input as table given and output will be if a usr search column E then the output of column G (row 2 to 5) should be available
 
Upvote 0
Search data

DEFGHIJ
1PhonStIDCountryCountPhoneCRAmot
29768146004370US197681460041XX200
3 300
4 400
5 5000
19768149002370US19768149001XX100
2 200
19768130002370US19768130002XX600

<colgroup><col><col><col><col><col><col><col><col></colgroup><tbody>
</tbody>


Output Required from column(J) with respect to search

Search Output
User entry97681460041 200
300
400
5000


<colgroup><col><col><col span="2"></colgroup><tbody>
</tbody>

current array formula
{=IF((Sheet2!$D$5:$D$800000>=$B$3)*(Sheet2!$G$5:$G$800000<=$D$2)*(Sheet2!$H$2:$H$800000=$B$3&$D$2),Sheet2!$J$5:$J$80000)}
it gives only 1st amount output.


I hope now I am very very clear.
 
Upvote 0
B3 is the user search value (search from column D) and d3 is 1 (search from column G)
 
Upvote 0

Forum statistics

Threads
1,215,022
Messages
6,122,721
Members
449,093
Latest member
Mnur

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