Stuck for working out which formula i need

Tucker92

Board Regular
Joined
Jun 7, 2018
Messages
53
I have multiple columns with alot of data in them. I want to know how many i need of specific items. my table currently looks like this

[TABLE="width: 500"]
<tbody>[TR]
[TD]Week number[/TD]
[TD]Container type[/TD]
[TD]Times appeared[/TD]
[/TR]
[TR]
[TD]1[/TD]
[TD]Grey Tray[/TD]
[TD]10[/TD]
[/TR]
[TR]
[TD][/TD]
[TD]Black box[/TD]
[TD]5[/TD]
[/TR]
</tbody>[/TABLE]

The times appeared column is calculated using countifs but it only counts the instances that grey tray appears in week 1 or 2 or whatever. In my database next to each container type i have an amount needed of each one and i was wondering how i could count the amount needed based on the week and container not just the amount it appears.

Thank you
 

Excel Facts

Why does 9 mean SUM in SUBTOTAL?
It is because Sum is the 9th alphabetically in Average, Count, CountA, Max, Min, Product, StDev.S, StDev.P, Sum, VAR.S, VAR.P.
Hey,

So you have a column between Container Type and Times Appeared that contains the amount needed (of the container type)?

Try:
=SUMPRODUCT((B2:B10="Grey Tray")*(C2:C10))

Where B2:B10 contains container types and C2:C10 contains the amount needed.

Change the ranges to see fit - if this is on the right lines it should work! Assuming amount needed is a scalar value e.g. 5
 
Upvote 0
This is how my database looks. So on my other sheet i can count the amount of times during week 1 the grey tray appears and the same for week two but i cant take into account the separate number needs
[TABLE="width: 400"]
<tbody>[TR]
[TD]Week No[/TD]
[TD]Container Type[/TD]
[TD]Number needed[/TD]
[/TR]
[TR]
[TD]1[/TD]
[TD]Motor Box[/TD]
[TD]1[/TD]
[/TR]
[TR]
[TD]1[/TD]
[TD]Grey Tray[/TD]
[TD]2[/TD]
[/TR]
[TR]
[TD]1[/TD]
[TD]Grey Tray[/TD]
[TD]1[/TD]
[/TR]
[TR]
[TD]1[/TD]
[TD]Motor box[/TD]
[TD]1[/TD]
[/TR]
[TR]
[TD]1[/TD]
[TD]Grey Tray[/TD]
[TD]3[/TD]
[/TR]
[TR]
[TD]1[/TD]
[TD]Grey Tray[/TD]
[TD]2[/TD]
[/TR]
</tbody>[/TABLE]

So i need to return a total need of the grey trays throughout the week. Can i sum the total grey trays based on two lookup values and get a total found
 
Last edited:
Upvote 0
Thank you i have found a way to do it using SumIFs

Thank you for your help and sorry for not being very good at explaining my problem
 
Upvote 0

Forum statistics

Threads
1,224,823
Messages
6,181,176
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