Hello guys !
Can someone help me please ? I want to create two slices :
How can I do that ? Do you have an expression for that ?
Thank you.
Solved! Go to Solution.
Please try
WEEKNUM([Date Column])= WEEKNUM(TODAY())
WEEKNUM([Date Column])= WEEKNUM( (EOWEEK(TODAY()) - 7) )
AppSheet’s week is from Sunday to Saturday in all WEEK expressions.
Edit: made a change in second expression
Please try
WEEKNUM([Date Column])= WEEKNUM(TODAY())
WEEKNUM([Date Column])= WEEKNUM( (EOWEEK(TODAY()) - 7) )
AppSheet’s week is from Sunday to Saturday in all WEEK expressions.
Edit: made a change in second expression
Thank’s @Suvrutt_Gurjar for your answer, I’m going to try it right now !
It works perfectly, thank you @Suvrutt_Gurjar
You are welcome. Please do test well for weekends during the year end when the year flips but the weeks remain same,
Alright. I’ll be careful and make an adaptation just in case. Thank you
One expression shorter EOWEEK([Date Column])=EOWEEK(TODAY() - 7). If you use dates more than from one year, the WEEKNUM() doesn’t work correctly.
Supporting what @Aleksi has mentioned, you can get the correct WEEKNUM with below expression:
FLOOR(
(10 +
IF(
MOD(YEAR([TIMESTAMP]), 4) = 0,
INDEX({0, 31, 60, 91, 121, 152, 182, 213, 244, 274, 305, 335},MONTH([TIMESTAMP])),
INDEX({0, 31, 59, 90, 120, 151, 181, 212, 243, 273, 304, 334},MONTH([TIMESTAMP]))
) + DAY([TIMESTAMP]) - (WEEKDAY([TIMESTAMP]) - 1)) / 7
)
so monday to sunday week is behind tricks only??
User | Count |
---|---|
38 | |
35 | |
27 | |
23 | |
18 |