Index and Match on multiple similar tables

infinia

New Member
Joined
Aug 6, 2020
Messages
2
Office Version
  1. 365
Platform
  1. Windows
  2. Mobile
  3. Web
Hello,

I need to use Index and Match function for this problem.
Need to select the specific table using the first parameter and then a value inside the table by using two other parameters.

eg
1596695501060.png

Need to find Shipping per unit using the tables below

1596695278687.png
 

Excel Facts

Whats the difference between CONCAT and CONCATENATE?
The newer CONCAT function can reference a range of cells. =CONCATENATE(A1,A2,A3,A4,A5) becomes =CONCAT(A1:A5)
*Need to select the specific table using the "customer type" parameter and then a value inside that table by using "region" and "shipping method"
 
Upvote 0
welcome to the board.
I've had this same problem fixed for me as follows:
It's easier to understand if you name some ranges.
Name B37:B41 as customer10region
Name C36:F36 as customer10method
Name C37:F41 as customer10rate

do the same for the other 2 customer types substituting the number as required (customer20region etc)

I made your input options as lists in data validation so they are pull down menus, but I made customer type 10, customer10.
I copied your input table starting at A24 and the shipping rate result is in A31

then the formula under "shipping per unit" is:
=INDEX(INDIRECT(A29&"rate"),MATCH(A25,INDIRECT(A29&"region"),0),MATCH(A27,INDIRECT(A29&"method"),0))

I tested it and it works. Hope for the same for you.
 
Upvote 0
Here it is using xl2BB
shipping rate with index match.xlsx
ABCDEFG
23
24region
25WEST
26shipping method
27PLANE
28customer type
29customer20
30shipping per unit
31 $ 1.83
32
33
34customer type 10
35std
36regionrailtruckplaneship
37NW$0.13$0.14$1.53$0.23
38WEST$0.21$0.15$2.03$0.25
39SW$0.27$0.17$2.13$0.23
40MIDWEST$0.31$0.19$2.28$0.23
41EAST$0.48$0.43$3.53$0.38
42
43customer type 20
44preferred
45regionrailtruckplaneship
46NW$0.12$0.13$1.38$0.21
47WEST$0.19$0.14$1.83$0.22
48SW$0.25$0.16$1.92$0.21
49MIDWEST$0.28$0.17$2.06$0.21
50EAST$0.44$0.39$3.18$0.35
51
52customer type 30
53most preferred
54regionrailtruckplaneship
55NW$0.11$0.12$1.25$0.18
56WEST$0.18$0.13$1.65$0.17
57SW$0.22$0.14$1.73$0.19
58MIDWEST$0.26$0.16$1.85$0.19
59EAST$0.39$0.35$2.87$0.31
Sheet1
Cell Formulas
RangeFormula
A31A31=INDEX(INDIRECT(A29&"rate"),MATCH(A25,INDIRECT(A29&"region"),0),MATCH(A27,INDIRECT(A29&"method"),0))
Cells with Data Validation
CellAllowCriteria
A25ListNW,WEST,SW,MIDWEST,EAST
A27ListRAIL,TRUCK,PLANE,SHIP
A29Listcustomer10,customer20,customer30
 
Upvote 0
Welcome to the Mr Excel board!

Since your tables all appear to have an identical layout & row/column headings, you can use standard INDEX/MATCH functions without any named ranges or use of the volatile INDIRECT function.

20 08 06.xlsm
ABCDEFG
24region
25WEST
26shipping method
27PLANE
28customer type
29customer type 30
30shipping per unit
311.65
32
33
34customer type 10
35std
36regionrailtruckplaneship
37NW0.130.141.530.23
38WEST0.210.152.030.25
39SW0.270.172.130.23
40MIDWEST0.310.192.280.23
41EAST0.480.433.530.38
42
43customer type 20
44preferred
45regionrailtruckplaneship
46NW0.120.131.380.21
47WEST0.190.141.830.22
48SW0.250.161.920.21
49MIDWEST0.280.172.060.21
50EAST0.440.393.180.35
51
52customer type 30
53most preferred
54regionrailtruckplaneship
55NW0.110.121.250.18
56WEST0.180.131.650.17
57SW0.220.141.730.19
58MIDWEST0.260.161.850.19
59EAST0.390.352.870.31
60
Lookup multiple tables
Cell Formulas
RangeFormula
A31A31=INDEX(C34:F59,MATCH(A29,B34:B59,0)+MATCH(A25,B37:B41,0)+2,MATCH(A27,C36:F36,0))
 
Upvote 0
Since your tables all appear to have an identical layout & row/column headings, you can use standard INDEX/MATCH functions without any named ranges or use of the volatile INDIRECT function.
Peter, just curious, why does my formula need the "volatile indirect function"? I don't profess to understand how all the magic works, I copy and paste a lot. Is it because my tables are all different sizes and headings?
 
Upvote 0
Peter, just curious, why does my formula need the "volatile indirect function"?
Because the solution used Named Ranges for parts of each table and then the formula used the text in cell A29 as part of the range name. It just wouldn't work without INDIRECT
 
Upvote 0

Forum statistics

Threads
1,214,583
Messages
6,120,383
Members
448,956
Latest member
JPav

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