Excel date function

  • Thread starter Excel date range function
  • Start date
E

Excel date range function

I have created the function SUMIF(A2:A25,"1/10/05",D2:D25) where the entries
of the A column are dates and the D column are amounts. For every entry on
1/10/05, it totals the amount. How can I apply this function with a date
range criteria of one month instead of just one day?
 
Q

QC Coug

You could set up a column that will give you the month of the data in column
A. (e.g. =month(A2)). If the data is "1/10/05" it will return the result of
"1". Then you can change your sumif formula to reference the new column with
the months.
 
B

Bob Phillips

=SUMPRODUCT(--(TEXT(A2:A25,"yyyymmm")="2005Jan"),D2:D25)

--
HTH

Bob Phillips

"Excel date range function" <Excel date range
(e-mail address removed)> wrote in message
news:[email protected]...
 
E

Excel date function

Thanks, it works great.

Bob Phillips said:
=SUMPRODUCT(--(TEXT(A2:A25,"yyyymmm")="2005Jan"),D2:D25)

--
HTH

Bob Phillips

"Excel date range function" <Excel date range
(e-mail address removed)> wrote in message
 
E

Excel date function

How could this formula be modified to include a second group of text (in
M2:M25 called Operators) so I could group by date and Operators and then add
the amounts in D2:D25?
 
B

Bob Phillips

=SUMPRODUCT(--(TEXT(A2:A25,"yyyymmm")="2005Jan"),--(M2:M25="Operators"),D2:D
25)

--

HTH

RP
(remove nothere from the email address if mailing direct)
 
E

Excel date function

Thank you for your help.

Bob Phillips said:
=SUMPRODUCT(--(TEXT(A2:A25,"yyyymmm")="2005Jan"),--(M2:M25="Operators"),D2:D
25)

--

HTH

RP
(remove nothere from the email address if mailing direct)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top