Forum Discussion
Date Range grouping
Anonymous well you tweak the code as it fits for you, I just provided the solution based on your original question.
✨ Follow us on LinkedIn and to our YouTube channel
I would ❤ Kudos if my solution helped. 👉 If you can spend time posting the question, you can also make efforts to give Kudos to whoever helped to solve your problem. It is a token of appreciation!
⚡ Visit us at https://perytus.com, your one-stop shop for Power BI-related projects/training/consultancy.
4 Replies
- parry2kSuper User
Anonymous TRY THIS:
Grouping = Var Tabledate = DATEDIFF(Date],TODAY(),Day) Return SWITCH ( TRUE() , TableDate>=61, "60+ Days", Tabledate>=30, "30-60 days", Tabledate>=23, "23-29 days", Tabledate>=16, "16-22 days", Tabledate>=6, "6-15 days", Tabledate>=3, "3-5 days", Tabledate>=1, "1-2 days", "Less than 1 Day" )✨ Follow us on LinkedIn and to our YouTube channel
I would ❤ Kudos if my solution helped. 👉 If you can spend time posting the question, you can also make efforts to give Kudos to whoever helped to solve your problem. It is a token of appreciation!
⚡ Visit us at https://perytus.com, your one-stop shop for Power BI-related projects/training/consultancy.
- AnonymousNot applicable
Thank you! This worked. My only issues is that it looks the its going back its not taking "today" (8/30/2022" and moving forward. I tried to filter by the next 3 months but it removed the categories.
- parry2kSuper User
Anonymous well you tweak the code as it fits for you, I just provided the solution based on your original question.
✨ Follow us on LinkedIn and to our YouTube channel
I would ❤ Kudos if my solution helped. 👉 If you can spend time posting the question, you can also make efforts to give Kudos to whoever helped to solve your problem. It is a token of appreciation!
⚡ Visit us at https://perytus.com, your one-stop shop for Power BI-related projects/training/consultancy.
- AnonymousNot applicable
I mean I have. The tweaks I made are not looking into the future but either way thank you it really helped.