Formula with CHOOSE functio in three table same size

GerryZ

Well-known Member
Joined
Jul 4, 2014
Messages
1,224
Office Version
  1. 365
Platform
  1. Windows
hello Everbody
in H2 I made a formula with INDIRECT that gives me back the right result choosing in different tables with the same size.
But now I'm stuck because I'd like to make a similar formula with CHOOSE function
I know is possible but I'm really stuck
Thank you for yor Help!

Book1
ABCDEFGH
1Tabella1ABCDcriteria1Tabella1
21zacfuxtorzorriga2
32macdaxmelrozcolonnaD
43fraannmarrasresultroz
54joeluitinaff
6
7
8Tabella2ABCD
91nonnikchisas
102nulminperfeb
113progiusbachi
124niepocmantet
13
14
15Tabella3ABCD
161arrbraitasfi
172incnercomuna
183besforpermia
194rotcogecasoc
Sheet1
Cell Formulas
RangeFormula
H4=INDEX(INDIRECT(H1),MATCH(H2,righe,0),MATCH(H3,colonne,0))
Named Ranges
NameRefers ToCells
colonne=Sheet1!$B$1:$E$1
righe=Sheet1!$A$2:$A$5
 

Excel Facts

Best way to learn Power Query?
Read M is for (Data) Monkey book by Ken Puls and Miguel Escobar. It is the complete guide to Power Query.
Try...

Code:
=INDEX(CHOOSE(MATCH(H$1,{"Tabella1","Tabella2","Tabella3"},0),$B$2:$E$5,$B$9:$E$12,$B$16:$E$19),MATCH(H$2,CHOOSE(MATCH(H$1,{"Tabella1","Tabella2","Tabella3"},0),$A$2:$A$5,$A$9:$A$12,$A$16:$A$19),0),MATCH(H$3,CHOOSE(MATCH(H$1,{"Tabella1","Tabella2","Tabella3"},0),$B$1:$E$1,$B$8:$E$8,$B$15:$E$15),0))

If the row and column headers are the same for each table, as per your example, try...

Code:
=INDEX(CHOOSE(MATCH(H$1,{"Tabella1","Tabella2","Tabella3"},0),$B$2:$E$5,$B$9:$E$12,$B$16:$E$19),MATCH(H$2,$A$2:$A$5,0),MATCH(H$3,$B$1:$E$1,0))

Hope this helps!
 
Upvote 0
Try...

Code:
=INDEX(CHOOSE(MATCH(H$1,{"Tabella1","Tabella2","Tabella3"},0),$B$2:$E$5,$B$9:$E$12,$B$16:$E$19),MATCH(H$2,CHOOSE(MATCH(H$1,{"Tabella1","Tabella2","Tabella3"},0),$A$2:$A$5,$A$9:$A$12,$A$16:$A$19),0),MATCH(H$3,CHOOSE(MATCH(H$1,{"Tabella1","Tabella2","Tabella3"},0),$B$1:$E$1,$B$8:$E$8,$B$15:$E$15),0))

If the row and column headers are the same for each table, as per your example, try...

Code:
=INDEX(CHOOSE(MATCH(H$1,{"Tabella1","Tabella2","Tabella3"},0),$B$2:$E$5,$B$9:$E$12,$B$16:$E$19),MATCH(H$2,$A$2:$A$5,0),MATCH(H$3,$B$1:$E$1,0))

Hope this helps!
Excelent Domenic!!
I will use the second formula
Anyway next thread i'll need the same formula with INDIRECT function and with CHOOSE function, but with tables with DIFFERENT size
 
Upvote 0
Hi GerryZ,

If you check this thread started by you a while back
http://www.mrexcel.com/forum/excel-questions/842957-lookup-3-tables-different-size.html

On my latest post I came up with a solution that will lookup any size tables and any quantity of tables for this.
Yesss!!
Thank you Chicagocomp...I Knew i did it before but I was lost in my 100s of file a 100s of old threads, but now I cannot forget this formula anymore
Now i'm prepering a new Thread and I will compare your formula with CHOOSE with a formula with INDIRECT function
because this time I'm really interested to learn how to search a value in different Tables with differents formulas
Thank You
 
Upvote 0
Worksheet Formulas
CellFormula
H4=INDEX(INDIRECT(H1),MATCH(H2,righe,0),MATCH(H3,colonne,0))

<thead>
</thead><tbody>
</tbody>

<tbody>
</tbody>
I know you asked for a function using CHOOSE, but I wanted to point out this formula, which appears to work, might be better than the above one given that INDIRECT is a Volatile function (not sure what the equivalent function names would be in Italian)...

=INDEX(A:E,MATCH(H1,A:A,0)+H2,CODE(H3)-63)
 
Upvote 0
@Rick
I just tried your formula but doesn't work error #RIF
Any way is difficult to understand your formula even if is short one
for the moment I'will use Domenic Formulaùthank you!
 
Upvote 0
@Rick
I just tried your formula but doesn't work error #RIF
Did you type the letter in cell H3 in lower case by any chance? As written, the code is expecting the letter to be upper case... if you need to accept lower case letters, then the formula would need to be this...

=INDEX(A:E,MATCH(H1,A:A,0)+H2,CODE(UPPER(H3))-63)
 
Upvote 0
Rick Rothstein ,

GerryZ always tricks you with his sample data by including numbers and letters in columns, but his real data is actual data, not just incremental numbers and letters as he has in his sample table. :) I've fallen into that trap before.
 
Upvote 0
Rick Rothstein ,

GerryZ always tricks you with his sample data by including numbers and letters in columns, but his real data is actual data, not just incremental numbers and letters as he has in his sample table. :) I've fallen into that trap before.
I don't think that is the case here... I am pretty sure "riga" means row, and "colonna" means column. I believe the problem is as I described in Message #8.
 
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