Link to home
Create AccountLog in
Avatar of Cactus1993
Cactus1993Flag for United States of America

asked on

Year to Date Sales (SUMIF function needed?)

Today is 08/15/2023.


Attached is a spreadsheet with a column of manually entered sales, day by day, for year to date 2023. 


In the column next to it are last year's 2022 sales, day by day, for the entire year.


I would like the cell (in this case, C5) to contain a formula returning last year's sales to date, e.g. sales from 01/01/2022 thru 08/15/2022 (which should be $105,646.74.)


I'm thinking this would be a SUMIF formula, but I don't know how to write it in this example. Thank you in advance for your help!


AAA.xlsx

ASKER CERTIFIED SOLUTION
Avatar of byundt
byundt
Flag of United States of America image

Link to home
membership
Create an account to see this answer
Signing up is free. No credit card required.
Create Account
Avatar of Cactus1993

ASKER

Excellent. Thank you!!


I actually put this together last night (8/15/23), which of course wouldn't be correct today unless we subtracted 1 from the date (as you mentioned.)


It works perfectly for what I need it for just the way you wrote it today. I has having problems constructing it, including the ampersand and other designations. Thank you for doing this and for educating me how to do it in the future.

Slightly different version:


=SUMIF(B8:B191,"<>",C8:C191)


That includes the value from column C (2022 Sales) where the equivalent row in column B (2023 Sales) is not blank.