Forum Discussion
Last Quarter dates (distinct) needed
For a time calender I need the comparable 9distinct) last day of the quarter of the last quarter.
I am trying this, but not sure what neeeds to e changed:
Hi acg
If you want to find the last day of the last quarter based on Today Date (or any specific date), you can use the below code:CompareDateQuarter = VAR _Today = TODAY () RETURN VAR _LastQuarter = QUARTER ( _Today ) - 1 RETURN VAR _LastQMonth = _LastQuarter * 3 RETURN DATE ( YEAR ( _Today ), _LastQMonth + 1, 1 ) - 1The output will be as below:
Did I answer your question? Mark my post as a solution!
Appreciate your Kudos !!
3 Replies
- VahidDM
Super User
Hi acg
If you want to find the last day of the last quarter based on Today Date (or any specific date), you can use the below code:CompareDateQuarter = VAR _Today = TODAY () RETURN VAR _LastQuarter = QUARTER ( _Today ) - 1 RETURN VAR _LastQMonth = _LastQuarter * 3 RETURN DATE ( YEAR ( _Today ), _LastQMonth + 1, 1 ) - 1The output will be as below:
Did I answer your question? Mark my post as a solution!
Appreciate your Kudos !!
- acg
Resolver I
Need to see, whether I can rework this with a dynamic quater date- in other words, it needs to work with any quarter date.
- CNENFRNL
Community Champion