Auto Fill cell with information from Table

BPN1993

New Member
Joined
Jun 28, 2019
Messages
1
Hey,

I'm working on a job cost form to price things for my business. On the job cost form I have it set up as follows:

SizeShapeColorQtyUnit Cost
5"RoundRed5$0.07
11"RoundRed10$0.15

<tbody>
</tbody>

I also have a sheet that has the pricing data from my main supplier. it looks as follows:
Color+/-Base ColorSizeQtyBase
Price
CostCost
Per Unit
Red$0.00Red5"100$5.10$5.10$0.05
Red$0.00Red11"10012.1512.15$0.12

<tbody>
</tbody>

I am wanting to get excel to take the values in the Size, Shape, and Color columns of the costing form and look them up in the database table and then grab the Cost per unit and return it in the unit cost column.
 

Excel Facts

Excel Can Read to You
Customize Quick Access Toolbar. From All Commands, add Speak Cells or Speak Cells on Enter to QAT. Select cells. Press Speak Cells.
Your data does not include Shape column, so I added it in to help illustrate

I find it easiest to use a helper column in the Data sheet to concatenate all the values that need to match
You could also add a helper column in sheet1 and simplify the formula - but I have not done that here
All that matters is that the string that is being matched is identicalt to what is in the helper column
I use " | " in the concatenation to make it easier to see
But the objective is to match string of Size&Shape&Color in sheet1 with same string in helper column in "Data"

Excel 2016 (Windows) 32 bit
A
B
C
D
E
F
1
SizeShapeColorQtyUnit Cost formula in E2 copied down
2
5"RoundRed
5​
$0.05 =INDEX(Data!H:H,MATCH(A2&" | " &B2&" | " &C2,Data!J:J,0))
3
11"RoundRed
10​
$0.12
Sheet: Sheet1

Excel 2016 (Windows) 32 bit
A
B
C
D
E
F
G
H
I
J
K
1
Color+/-Base ColorSizeQtyBase
Price
CostCost
per unit
ShapeHelper ColumnFormula in J2 copied down
2
Red$0.00Red5"
100​
$5.10$5.10$0.05Round5" | Round | Red =D2&" | " &I2&" | " &A2
3
Red$0.00Red11"
100​
12.15​
12.15​
$0.12Round11" | Round | Red
Sheet: Data
 
Last edited:
Upvote 0

Forum statistics

Threads
1,214,585
Messages
6,120,399
Members
448,958
Latest member
Hat4Life

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