WEEK # in Month Calculation

Hi there,

I'm using this formula to calculate what week number in a month a week is. For example 1/1/24 would be week 1 and 1/7 would be week 2, 1/14 starts week three etc. I'm getting 1/14 coming through as week 2. Any suggestions or ideas on how I could clean up this formula to function properly?

=WEEKNUMBER(Date@row) - WEEKNUMBER(DATE(YEAR(Date@row), MONTH(Date@row), 1)) + 1


Tags:

Best Answer

  • Paul Newcome
    Paul Newcome ✭✭✭✭✭✭
    edited 02/13/24 Answer ✓

    All we need is an IF to say that if the weekday is a Sunday (1) then add one more to the final calculation.

    =WEEKNUMBER(Date@row) - WEEKNUMBER(DATE(YEAR(Date@row), MONTH(Date@row), 1)) + 1 + IF(WEEKDAY(Date@row) = 1, 1, 0)

    Come see me in Seattle at ENGAGE 2024! I will be at the 10xViz partner booth throughout as well as the "Lets Talk About Community" Meet & Eat table on Tuesday from 11:45am - 12:45pm!

    CERTIFIED SMARTSHEET PLATINUM PARTNER

    10xViz.com

Answers

Help Article Resources

Want to practice working with formulas directly in Smartsheet?

Check out the Formula Handbook template!