Index Match question

odonovanc

Board Regular
Joined
Oct 4, 2017
Messages
60
Office Version
  1. 365
I suspect I need to use a different function but I am trying to lookup data and in one tab the city name is in one column, but the tab with the data the city names are spread out over manmy columns.

LocationRevenueExpenses
Boston150000168000
Chicago99000107910
Dallas#REF!#REF!
Denver#REF!#REF!
Houston#REF!#REF!
Nw York#REF!#REF!
San Francisco#REF!#REF!


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


BostonChicagoDallasDenverHoustonNw YorkSan Francisco
Revenue 150,000 168,000 188,160 210,739 236,028 264,351 296,073
Expenses 99,000 107,910 117,622 128,208 139,747 152,324 166,033

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


I am trying this formula to no success:
=INDEX(Sample!$C$4:$I$5,MATCH(A2,Sample!$C$2:$I$2,0),MATCH(C$1,Sample!$B$4:$B$5,0))


Can someone help
 

Excel Facts

Test for Multiple Conditions in IF?
Use AND(test, test, test, test) or OR(test, test, test, ...) as the logical_test argument of IF.
Looks like all you need to do is reverse your MATCH functions.

Excel Workbook
ABC
1LocationRevenueExpenses
2Boston15000099000
3Chicago168000107910
4Dallas188160117622
5Denver210739128208
6Houston236028139747
7Nw York264351152324
8San Francisco296073166033
Sheet2
Excel Workbook
ABCDEFGHI
1
2BostonChicagoDallasDenverHoustonNw YorkSan Francisco
3
4Revenue150,000168,000188,160210,739236,028264,351296,073
5Expenses99,000107,910117,622128,208139,747152,324166,033
Sample
 
Upvote 0

Forum statistics

Threads
1,213,536
Messages
6,114,207
Members
448,554
Latest member
Gleisner2

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