Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 4
Default Need help creating a simple (?) SUM formula!

Here's a spreadsheet that I need to make for the sales of a sto

- Column A has all the dates of the year (January 1, January 2, January 3,
etc.) for the entire year listed one after another (so a total of 365 rows,
starting in row 1).
- Column B has the day of the week (Monday, Tuesday, Wednesday, etc.)
corresponding to the date next to it in column A.
- Column C has the sales amount (example: $125.50) corresponding to the
date/day listed in the same row of columns A and B.

Here's my question:
If I want to have the sum of all sales made ONLY on Mondays for the entire
year to appear in a cell (let's say cell F1), what would the formula have to
be?
In other words, how can I get Excel to calculate the sum of ONLY the numbers
listed in column C which have the word 'Monday' written in the same row of
column B?

I hope I explained that clearly! Thanks in advance!
  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 506
Default Need help creating a simple (?) SUM formula!

Paste this formula in F1 cell
=SUMIF(B:B,"MONDAY",C:C)

Remember to Click Yes, if this post helps!

--------------------
(Ms-Exl-Learner)
--------------------


"sandres74" wrote:

Here's a spreadsheet that I need to make for the sales of a sto

- Column A has all the dates of the year (January 1, January 2, January 3,
etc.) for the entire year listed one after another (so a total of 365 rows,
starting in row 1).
- Column B has the day of the week (Monday, Tuesday, Wednesday, etc.)
corresponding to the date next to it in column A.
- Column C has the sales amount (example: $125.50) corresponding to the
date/day listed in the same row of columns A and B.

Here's my question:
If I want to have the sum of all sales made ONLY on Mondays for the entire
year to appear in a cell (let's say cell F1), what would the formula have to
be?
In other words, how can I get Excel to calculate the sum of ONLY the numbers
listed in column C which have the word 'Monday' written in the same row of
column B?

I hope I explained that clearly! Thanks in advance!

  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 8,520
Default Need help creating a simple (?) SUM formula!

You dont need Column B to get that. Use the function WEEKDAY() with
SUMPRODUCT() to get that

=SUMPRODUCT((WEEKDAY(A1:A100)=2)*C1:C100)

--
Jacob


"sandres74" wrote:

Here's a spreadsheet that I need to make for the sales of a sto

- Column A has all the dates of the year (January 1, January 2, January 3,
etc.) for the entire year listed one after another (so a total of 365 rows,
starting in row 1).
- Column B has the day of the week (Monday, Tuesday, Wednesday, etc.)
corresponding to the date next to it in column A.
- Column C has the sales amount (example: $125.50) corresponding to the
date/day listed in the same row of columns A and B.

Here's my question:
If I want to have the sum of all sales made ONLY on Mondays for the entire
year to appear in a cell (let's say cell F1), what would the formula have to
be?
In other words, how can I get Excel to calculate the sum of ONLY the numbers
listed in column C which have the word 'Monday' written in the same row of
column B?

I hope I explained that clearly! Thanks in advance!

  #4   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 4
Default Need help creating a simple (?) SUM formula!

That worked great! Thanks!
Now what if I want to have a cell (let's say cell G1) that gives me the
average of all of those Monday sales for the year, what would the formula
have to be? (Ideally that formula would be able to ignore zeros as well as
blank cells)

Thanks again!

"Ms-Exl-Learner" wrote:

Paste this formula in F1 cell
=SUMIF(B:B,"MONDAY",C:C)

Remember to Click Yes, if this post helps!

--------------------
(Ms-Exl-Learner)
--------------------


"sandres74" wrote:

Here's a spreadsheet that I need to make for the sales of a sto

- Column A has all the dates of the year (January 1, January 2, January 3,
etc.) for the entire year listed one after another (so a total of 365 rows,
starting in row 1).
- Column B has the day of the week (Monday, Tuesday, Wednesday, etc.)
corresponding to the date next to it in column A.
- Column C has the sales amount (example: $125.50) corresponding to the
date/day listed in the same row of columns A and B.

Here's my question:
If I want to have the sum of all sales made ONLY on Mondays for the entire
year to appear in a cell (let's say cell F1), what would the formula have to
be?
In other words, how can I get Excel to calculate the sum of ONLY the numbers
listed in column C which have the word 'Monday' written in the same row of
column B?

I hope I explained that clearly! Thanks in advance!

  #5   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 506
Default Need help creating a simple (?) SUM formula!

Just now i have seen your reply and the formula you have asked is given below.

Use this below formula in G1 cell:-

=SUMIF(B:B,"MONDAY",C:C)/SUMPRODUCT((B1:B65535="MONDAY")*(C1:C65535<0)*(C1 :C65535<""))

Which will ignore the zero value and blank cells in C column when
calculating the Average for Monday.

--------------------
(Ms-Exl-Learner)
--------------------


"sandres74" wrote:

That worked great! Thanks!
Now what if I want to have a cell (let's say cell G1) that gives me the
average of all of those Monday sales for the year, what would the formula
have to be? (Ideally that formula would be able to ignore zeros as well as
blank cells)

Thanks again!

"Ms-Exl-Learner" wrote:

Paste this formula in F1 cell
=SUMIF(B:B,"MONDAY",C:C)

Remember to Click Yes, if this post helps!

--------------------
(Ms-Exl-Learner)
--------------------


"sandres74" wrote:

Here's a spreadsheet that I need to make for the sales of a sto

- Column A has all the dates of the year (January 1, January 2, January 3,
etc.) for the entire year listed one after another (so a total of 365 rows,
starting in row 1).
- Column B has the day of the week (Monday, Tuesday, Wednesday, etc.)
corresponding to the date next to it in column A.
- Column C has the sales amount (example: $125.50) corresponding to the
date/day listed in the same row of columns A and B.

Here's my question:
If I want to have the sum of all sales made ONLY on Mondays for the entire
year to appear in a cell (let's say cell F1), what would the formula have to
be?
In other words, how can I get Excel to calculate the sum of ONLY the numbers
listed in column C which have the word 'Monday' written in the same row of
column B?

I hope I explained that clearly! Thanks in advance!

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
Creating a Simple macro Gunti Excel Discussion (Misc queries) 8 December 16th 08 03:41 PM
Creating a simple chart Keith Charts and Charting in Excel 1 September 1st 08 05:43 PM
Creating a Simple Bar Chart - 2 Areas for help please BRob Charts and Charting in Excel 4 May 18th 08 02:42 AM
Creating what should be a simple macro Dwight Excel Discussion (Misc queries) 6 April 13th 07 06:38 PM
creating a simple formula for a range of cells Christopher[_2_] Excel Discussion (Misc queries) 3 February 21st 07 08:04 AM


All times are GMT +1. The time now is 02:22 AM.

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

About Us

"It's about Microsoft Excel"