Alteryx Designer Desktop Discussions

Find answers, ask questions, and share expertise about Alteryx Designer Desktop and Intelligence Suite.
SOLVED

Current Month, QTD, YTD Flag

itsmeanuj
7 - Meteor

Hi Guys,

 

I am looking for some help/logic in achieving Quarter, Current Month, QTD, and YTD Flags in my data. These flags are dynamic in nature and keep updating every month. e.g. we have data only till Feb (sum_value >0), hence Current month would be 1, QTD/YTD = 1 for Jan & Feb).

 

Time SortSum_ValueVersionsTime Period NewQuarterCurrent MonthQTDYTD
1500Actuals1/1/20231011
21000Actuals2/1/20231111
30Actuals3/1/20231000
40Actuals4/1/20232000
50Actuals5/1/20232000
60Actuals6/1/20232000
70Actuals7/1/20233000
80Actuals8/1/20233000
90Actuals9/1/20233000
100Actuals10/1/20234000
110Actuals11/1/20234000
120Actuals12/1/20234000
5 REPLIES 5
Christina_H
14 - Magnetar

This should work.  It assumes the current month is the last one with [Sum_Value]>0

Christina_H_0-1680163795169.png

 

Raj
14 - Magnetar

Sol

ShankerV
17 - Castor

Hi @itsmeanuj 

 

One way of doing this.

 

ShankerV_0-1680166141686.png

 

Many thanks

Shanker V

itsmeanuj
7 - Meteor

Thanks, @ShankerV  - This solution won't work when we have data for April. Using this solution QTD Flag for Jan, Feb, and Mar is also showing 1 when we have data in April. Ideally only Apr should have a QTD flag as 1 since its the beginning of the new quarter.

 

Thanks,

Anuj

ShankerV
17 - Castor

Hi @itsmeanuj 

 

I have tweaked the workflow to get the desired result.

 

ShankerV_0-1680172336982.png

 

Many thanks

Shanker V

Labels