Getting Data from two sheets.

pjkaphlen

Board Regular
Joined
Aug 3, 2015
Messages
85
Office Version
  1. 365
  2. 2013
Platform
  1. Windows
Hello Guys!

Can you help me in solving this excel problem?
I have a data in one sheet and I need to reference this data into another sheet.

Sheet 1
Weight per shipment5.1960
Zone6
Cost$--------

<tbody>
</tbody>


Sheet 2
WeightZone1Zone2Zone3Zone4Zone5Zone6
4$0.1$0.2$0.3$0.4$0.5$0.6
4.5$1.1$1.2$1.3$1.4$1.5$1.6
5$2.5$2.6$2.7$2.8$2.9$3.0
5.5$3.5$3.6$3.7$3.8$3.9$4.0

<tbody>
</tbody>


So let's say, on sheet 1, I have data for the weight and Zone. However the zone is not the exact value as was found in sheet 2. In this case, I will have to select 5.5 since the weight is already greater than 5.

Also, the zone is 6. Thus if i take the intersection of zone 6 and the weight of 5.5 I should be able to get $4.0 as cost. How should I input my formula in sheet 1 (Cost row) so that I will be able to get the correct cost for every ZOne and weight input?

Please help me with this guys. Thank you very much!
 

Excel Facts

Did you know Excel offers Filter by Selection?
Add the AutoFilter icon to the Quick Access Toolbar. Select a cell containing Apple, click AutoFilter, and you will get all rows with Apple
=INDEX(Sheet2!B2:G5,MATCH(Sheet1!B1,Sheet2!A2:A5,1)+1,MATCH("Zone"&Sheet1!B2,Sheet2!B1:G1,0))
 
Upvote 0
Thanks! I was trying to use INDEX-MATCH but i just couldn't figure out how.
 
Upvote 0
Zone1Zone2Zone3Zone4Zone5Zone6
5$2.5$2.6$2.7$2.8$2.93.0
5.5$3.5$3.6$4.7$3.8$3.9$4.0
15$10$11$12$13$14$15
16$16$16$18$19$20$21
17$23$24$25$26$27$28
18$29$30$31$32$33$34

<tbody>
</tbody>


Ha! the programs works! However I tried to increase the range of sheet 2. Now, if I have weight in 16kg and Zone 1, then this means that the formula will always return the value of $23 dollars instead of $16, right? In which case, the value returned now will be incorrect.

Does it have something to do with the difference in columns A's incremental value?

I tried using the -1 match type, but unfortunately it doesn't return any value.
 
Upvote 0

Forum statistics

Threads
1,215,681
Messages
6,126,194
Members
449,298
Latest member
Jest

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