Index/match multiple criteria not working - HELP please

dmj120

Active Member
Joined
Jan 5, 2010
Messages
308
Office Version
  1. 365
  2. 2019
  3. 2010
I am trying to extract pricing based on an ID# and device code. I've tried a couple variations of what I read online, to no avail.

INDEX('Sheet A'!$F$2:$K$36310,MATCH($A4,'Sheet A'!$A$2:$A$36310, 0),3) works, but when I add the second 'row criteria' it all goes south.... example below

INDEX('Sheet A'!$F$2:$K$36310, MATCH(1,('Sheet A'!$A$2:$A$36310=$A4) * ('Sheet A'!$B$2:$B$36310=$E$1), 0) ,3)


Sheet A (original data)
1719419605864.png




New sheet
1719419800969.png
 

Excel Facts

Create a Pivot Table on a Map
If your data has zip codes, postal codes, or city names, select the data and use Insert, 3D Map. (Found to right of chart icons).
Column B code and G1 were different formats.... one text and the other general
 
Upvote 0
Solution
Hello - not sure if this will help but you can try this out. Firstly, I would do a countifs to get unique count and lay it out like this;

Model ID. Code. Count
Result of count

From the original data;

=COUNTIFS(Original Data $A$2:$A$36310, Selected Model ID No, Original Data $B$2:$B$36310, Selected Code)

You can use Data validation on both Original data tab to get Model ID & Code respectively as part of the above COUNTIFS formula.

Once done, them run the following on the new sheet in cell A4 and copy across;

{=IF(ROWS(A$4:A4)>COUNT, RESULT,"",INDEX(Original Data A$2:A$36310, SMALL(IF(Original Data $A$2:$A$36310=Model ID Selection, IF(Original Data $B$36310=Code Selection, ROW(Original Data $A$2:$A$36310)-ROW(Original Data $A$2)+1)), ROWS($A$4:A4)} and copy this across the columns;

Model ID. Code Mfg. Device. Mdl. Pricing

You will need to insert a pricing on the original data in order to pull over into the new data starting as mentioned in cell A4.

As you start to populate the original data list with more lines, this will update on the new tab when you start to add more data.

Hope this helps
 
Upvote 0
Hello - just thinking, you could also try this with FILTER;

So in cell A4 on new data;

=FILTER(Original Data $A$2:$A$36310, (Original Data $A$2:$A$A36310=Model ID)*(Original Data $B$2:$B$36310=Code)
 
Upvote 1
Hello - just thinking, you could also try this with FILTER;

So in cell A4 on new data;

=FILTER(Original Data $A$2:$A$36310, (Original Data $A$2:$A$A36310=Model ID)*(Original Data $B$2:$B$36310=Code)
Didn't think about filter. Thanks for the input! 🥃🥃
 
Upvote 0

Forum statistics

Threads
1,222,091
Messages
6,163,855
Members
451,861
Latest member
Lurch65

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