ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   date range additions (https://www.excelbanter.com/excel-worksheet-functions/189169-date-range-additions.html)

ann

date range additions
 
if column A "text" and column A "more text" and column B date 5/18 and less
than 5/22 (***date is the current week) then sum number in column C.

basically looking for: based what's in column A, the dates in column B
should be the current week, then add whats in column C

Peo Sjoblom

date range additions
 
One way

=SUMPRODUCT(--(A1:A30="a"),--(B1:B30=TODAY()-7),--(B1:B30<=TODAY()),C1:C30)



adapt to fit your data



--


Regards,


Peo Sjoblom


"Ann" wrote in message
...
if column A "text" and column A "more text" and column B date 5/18 and
less
than 5/22 (***date is the current week) then sum number in column C.

basically looking for: based what's in column A, the dates in column B
should be the current week, then add whats in column C




ann

date range additions
 
close...i need to put in a date, rather than -7. for example i need it to be
=SUMPRODUCT(--(A1:A30="a"),--(B1:B30=5/18/2008),--(B1:B30<=5/22/2008),C1:C30)

what's the correct syntax for the dates?


ND Pard

date range additions
 
In lieu of the 5/18/2008, use the Date(2008,5,18) function, etc.

Good Luck.

"Ann" wrote:

close...i need to put in a date, rather than -7. for example i need it to be
=SUMPRODUCT(--(A1:A30="a"),--(B1:B30=5/18/2008),--(B1:B30<=5/22/2008),C1:C30)

what's the correct syntax for the dates?


ann

date range additions
 
here's the formula i'm using.
=SUMPRODUCT(--(H3:H200="ABC"),--(D3:D200DATE(2008,5,18)),--(D3:D200=DATE(2008,5,22)),E3:E200)

it's only adding up if the date matches 5/22, not 5/19 through 5/22.
tia

Peo Sjoblom

date range additions
 
You need to check the original formula I gave you and use the same
technique, the last date part should be

(D3:D200<=DATE(2008,5,22)

and not

(D3:D200=DATE(2008,5,22)





--


Regards,


Peo Sjoblom


"Ann" wrote in message
...
here's the formula i'm using.
=SUMPRODUCT(--(H3:H200="ABC"),--(D3:D200DATE(2008,5,18)),--(D3:D200=DATE(2008,5,22)),E3:E200)

it's only adding up if the date matches 5/22, not 5/19 through 5/22.
tia




ann

date range additions
 
thank you so much, don't know when i changed it, that fixed it!

"Peo Sjoblom" wrote:

You need to check the original formula I gave you and use the same
technique, the last date part should be

(D3:D200<=DATE(2008,5,22)

and not

(D3:D200=DATE(2008,5,22)





--


Regards,


Peo Sjoblom


"Ann" wrote in message
...
here's the formula i'm using.
=SUMPRODUCT(--(H3:H200="ABC"),--(D3:D200DATE(2008,5,18)),--(D3:D200=DATE(2008,5,22)),E3:E200)

it's only adding up if the date matches 5/22, not 5/19 through 5/22.
tia






All times are GMT +1. The time now is 03:52 AM.

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