Match Column Header then find cell below (offset 1 cell to right) that match another value.

Johnny J

New Member
Joined
Jul 25, 2011
Messages
6
Each Zip Code listed in row 1 has 4 data elements. I am trying to find the Miles for the Zip listed in row 1 and match it to the zip code 1 column over from it and give me the miles to the right of that. Essentially, I have two cells containing the 1st zip code and another containing the second zip code. I need a formula to find the Miles on the table. The data directly under the zip in row 1 is the format I get when I import that data so I used the 3 columns beside it to extract out the Zip, Miles and City.
[TABLE="width: 1089"]
<colgroup><col><col><col><col><col><col><col><col></colgroup><tbody>[TR]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[/TR]
</tbody>[/TABLE]
[TABLE="width: 500"]
<tbody>[TR]
[TD][TABLE="width: 1611"]
<colgroup><col><col><col><col><col><col><col><col><col><col><col><col></colgroup><tbody>[TR]
[TD]43061[/TD]
[TD] [/TD]
[TD] [/TD]
[TD] [/TD]
[TD]43065[/TD]
[TD] [/TD]
[TD] [/TD]
[TD] [/TD]
[TD]43207[/TD]
[TD] [/TD]
[TD] [/TD]
[TD] [/TD]
[/TR]
[TR]
[TD]Ostrander[/TD]
[TD]Zip[/TD]
[TD]Miles[/TD]
[TD]City[/TD]
[TD]Powell[/TD]
[TD]Zip[/TD]
[TD]Miles[/TD]
[TD]City[/TD]
[TD]Columbus[/TD]
[TD]Zip[/TD]
[TD]Miles[/TD]
[TD]City[/TD]
[/TR]
[TR]
[TD]43001 - ALEXANDRIA - 33.9908194089[/TD]
[TD]43001[/TD]
[TD]34.0[/TD]
[TD]ALEXANDRIA[/TD]
[TD]25247 - HARTFORD - 98.4784695949[/TD]
[TD]25247[/TD]
[TD]98.5[/TD]
[TD]HARTFORD[/TD]
[TD]25106 - HENDERSON - 88.323448451[/TD]
[TD]25106[/TD]
[TD]88.3[/TD]
[TD]HENDERSON[/TD]
[/TR]
[TR]
[TD]43002 - AMLIN - 15.6134302617[/TD]
[TD]43002[/TD]
[TD]15.6[/TD]
[TD]AMLIN[/TD]
[TD]25260 - MASON - 96.6050109214[/TD]
[TD]25260[/TD]
[TD]96.6[/TD]
[TD]MASON[/TD]
[TD]25123 - LEON - 98.050046313[/TD]
[TD]25123[/TD]
[TD]98.1[/TD]
[TD]LEON[/TD]
[/TR]
[TR]
[TD]43003 - ASHLEY - 15.4260415433[/TD]
[TD]43003[/TD]
[TD]15.4[/TD]
[TD]ASHLEY[/TD]
[TD]25287 - WEST COLUMBIA - 99.5222019041[/TD]
[TD]25287[/TD]
[TD]99.5[/TD]
[TD]WEST COLUMBIA[/TD]
[TD]25187 - SOUTHSIDE - 95.5612373777[/TD]
[TD]25187[/TD]
[TD]95.6[/TD]
[TD]SOUTHSIDE[/TD]
[/TR]
[TR]
[TD]43004 - BLACKLICK - 28.9490219445[/TD]
[TD]43004[/TD]
[TD]28.9[/TD]
[TD]BLACKLICK[/TD]
[TD]26181 - WASHINGTON - 99.305333734[/TD]
[TD]26181[/TD]
[TD]99.3[/TD]
[TD]WASHINGTON[/TD]
[TD]25239 - COTTAGEVILLE - 93.959697821[/TD]
[TD]25239[/TD]
[TD]94.0[/TD]
[TD]COTTAGEVILLE[/TD]
[/TR]
[TR]
[TD]43005 - BLADENSBURG - 48.5984525319[/TD]
[TD]43005[/TD]
[TD]48.6[/TD]
[TD]BLADENSBURG[/TD]
[TD]41174 - SOUTH PORTSMOUTH - 99.7218437163[/TD]
[TD]41174[/TD]
[TD]99.7[/TD]
[TD]SOUTH PORTSMOUTH[/TD]
[TD]25241 - EVANS - 98.6524527171[/TD]
[TD]25241[/TD]
[TD]98.7[/TD]
[TD]EVANS[/TD]
[/TR]
[TR]
[TD]43006 - BRINKHAVEN - 55.9552984561[/TD]
[TD]43006[/TD]
[TD]56.0[/TD]
[TD]BRINKHAVEN[/TD]
[TD]43001 - ALEXANDRIA - 25.3183893139[/TD]
[TD]43001[/TD]
[TD]25.3[/TD]
[TD]ALEXANDRIA[/TD]
[TD]25247 - HARTFORD - 80.7674023613[/TD]
[TD]25247[/TD]
[TD]80.8[/TD]
[TD]HARTFORD[/TD]
[/TR]
[TR]
[TD]43007 - BROADWAY - 11.8041452714[/TD]
[TD]43007[/TD]
[TD]11.8[/TD]
[TD]BROADWAY[/TD]
[TD]43002 - AMLIN - 8.41921323954[/TD]
[TD]43002[/TD]
[TD]8.4[/TD]
[TD]AMLIN[/TD]
[TD]25253 - LETART - 85.7527714829[/TD]
[TD]25253[/TD]
[TD]85.8[/TD]
[TD]LETART[/TD]
[/TR]
[TR]
[TD]43008 - BUCKEYE LAKE - 45.3509106625[/TD]
[TD]43008[/TD]
[TD]45.4[/TD]
[TD]BUCKEYE LAKE[/TD]
[TD]43003 - ASHLEY - 18.7339415705[/TD]
[TD]43003[/TD]
[TD]18.7[/TD]
[TD]ASHLEY[/TD]
[TD]25260 - MASON - 78.809206548[/TD]
[TD]25260[/TD]
[TD]78.8[/TD]
[TD]MASON[/TD]
[/TR]
</tbody>[/TABLE]
[/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[/TR]
</tbody>[/TABLE]
 

Excel Facts

Enter current date or time
Ctrl+: enters current time. Ctrl+; enters current date. Use Ctrl+: Ctrl+; Enter for current date & time.

Forum statistics

Threads
1,224,823
Messages
6,181,171
Members
453,021
Latest member
Justyna P

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