ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   New Users to Excel (https://www.excelbanter.com/new-users-excel/)
-   -   Adding rows of data based on first column (https://www.excelbanter.com/new-users-excel/185822-adding-rows-data-based-first-column.html)

Dewaynep

Adding rows of data based on first column
 
Not sure if I worded that correctly. Here's what I need to do: I have sales
data for a month that is listed individually by date and item number. I need
to go through the entire workbook and find each occurance of each item and
add together the number of items ordered. Here is an example:
Item TotalOrdered
119 1
121 1
121 1
121 1
182 1
182 1
206 1
206 1
223 1
589 1
589 1
As you can see, item 121 had 3 ordered, 589 had 2 ordered. Is there a
formula I can use to do this automatically? Thanks.
--
Excel Noobie

Don Guillett

Adding rows of data based on first column
 

Look in the help index for COUNTIF
--
Don Guillett
Microsoft MVP Excel
SalesAid Software

"Dewaynep" wrote in message
...
Not sure if I worded that correctly. Here's what I need to do: I have
sales
data for a month that is listed individually by date and item number. I
need
to go through the entire workbook and find each occurance of each item and
add together the number of items ordered. Here is an example:
Item TotalOrdered
119 1
121 1
121 1
121 1
182 1
182 1
206 1
206 1
223 1
589 1
589 1
As you can see, item 121 had 3 ordered, 589 had 2 ordered. Is there a
formula I can use to do this automatically? Thanks.
--
Excel Noobie



Dewaynep

Adding rows of data based on first column
 
Thanks Don. I checked Countif, and it looks like would work if "total
ordered" was always 1, but that is not the case. I have to be able to look up
the item number and add the number(s) in column "b" together. Would I still
use countif?
--
Excel Noobie


"Don Guillett" wrote:


Look in the help index for COUNTIF
--
Don Guillett
Microsoft MVP Excel
SalesAid Software

"Dewaynep" wrote in message
...
Not sure if I worded that correctly. Here's what I need to do: I have
sales
data for a month that is listed individually by date and item number. I
need
to go through the entire workbook and find each occurance of each item and
add together the number of items ordered. Here is an example:
Item TotalOrdered
119 1
121 1
121 1
121 1
182 1
182 1
206 1
206 1
223 1
589 1
589 1
As you can see, item 121 had 3 ordered, 589 had 2 ordered. Is there a
formula I can use to do this automatically? Thanks.
--
Excel Noobie




Don Guillett

Adding rows of data based on first column
 
Your OP said COUNT. If you want to count use countif. If you want to
"add the number(s) in column "b" together" use
=SUMIF(H2:H22,589,I2:I22)
--
Don Guillett
Microsoft MVP Excel
SalesAid Software

"Dewaynep" wrote in message
...
Thanks Don. I checked Countif, and it looks like would work if "total
ordered" was always 1, but that is not the case. I have to be able to look
up
the item number and add the number(s) in column "b" together. Would I
still
use countif?
--
Excel Noobie


"Don Guillett" wrote:


Look in the help index for COUNTIF
--
Don Guillett
Microsoft MVP Excel
SalesAid Software

"Dewaynep" wrote in message
...
Not sure if I worded that correctly. Here's what I need to do: I have
sales
data for a month that is listed individually by date and item number. I
need
to go through the entire workbook and find each occurance of each item
and
add together the number of items ordered. Here is an example:
Item TotalOrdered
119 1
121 1
121 1
121 1
182 1
182 1
206 1
206 1
223 1
589 1
589 1
As you can see, item 121 had 3 ordered, 589 had 2 ordered. Is there a
formula I can use to do this automatically? Thanks.
--
Excel Noobie






All times are GMT +1. The time now is 06:20 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com