Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 2
Default Sum within a column, according to another column

I have two columns. One column contains the prices of each item sold. The
other column is called a line number and begins with one for new
transactions. So if a customer bought 4 items, it will go up to 4. Is there
any way to sum just those in a transaction, and then do it for hundreds of
other transactions?
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 11,501
Default Sum within a column, according to another column

Hi,

This isn't clear, post some sample data and the desired result.

Mike

"Auditor" wrote:

I have two columns. One column contains the prices of each item sold. The
other column is called a line number and begins with one for new
transactions. So if a customer bought 4 items, it will go up to 4. Is there
any way to sum just those in a transaction, and then do it for hundreds of
other transactions?

  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 3,346
Default Sum within a column, according to another column

I second Mike comment.

If your data looks like this in the transaction column:

1
2
1
2
3
4

Then if you want to sum the first 1 and 2 then the second 1, 2, 3, 4 and so
on. It would be much better if you had a customer column so you could easily
destinguish which items below to which customer. If not then here is a
formula to put in column C and copy down. I'm assuming the first row is
titles so your first data is in A2:B2 and this formula goes into C2:

=IF(A2<A3,"",SUM(OFFSET(B2,0,0,-A2)))

Copy this formula down as far as needed.

--
If this helps, please click the Yes button

Cheers,
Shane Devenshire


"Auditor" wrote:

I have two columns. One column contains the prices of each item sold. The
other column is called a line number and begins with one for new
transactions. So if a customer bought 4 items, it will go up to 4. Is there
any way to sum just those in a transaction, and then do it for hundreds of
other transactions?

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
divide column(x) by column(y) to give column(x/y) in excel? James New Users to Excel 2 April 24th 23 11:46 AM
Referencing date column A & time column B to get info from column TVGuy29 Excel Discussion (Misc queries) 1 January 24th 08 09:50 PM
Return text in Column A if Column B and Column K match jeannie v Excel Worksheet Functions 4 December 13th 07 07:36 PM
Based on a condition in one column, search for a year in another column, and display data from another column in the same row look [email protected] Excel Discussion (Misc queries) 1 December 27th 06 05:47 PM
Divide Column A by Column B multiply Column C Stumped Excel Worksheet Functions 3 December 28th 05 05:51 AM


All times are GMT +1. The time now is 05:28 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"