Excel (Need a formula)

  • Thread starter Thread starter HeatherV
  • Start date Start date
H

HeatherV

I need a formula that will enable me to count how many of each product there
is. For example in one column there could be five different products appear
several times and in the column next to it I have the amount of product. I
want the formula to look up the two columns and give me the total of each
product.
 
Hi,

Suppose your data is in A1:B1000

Then in column D list each product once starting in D1. You can use the
Advanced Filter, Unique Records command to do that for you.
In cell E1 enter the formula
=COUNTIF(A$1:A$1000,D1)
and fill it down as far as necessary
In cell F1 enter the formula
=SUIF(A$1:A$1000,D1,B$1:B$1000)
 
Back
Top