We are celebrating the 10-year anniversary of the Alteryx Community! Learn more and join in on the fun here.
Start Free Trial

Alteryx Designer Desktop Discussions

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

Current Month and Prior

Srawat
8 - Asteroid

Hi,

 

Can we have a any tool or condition formula with the help of write current month or prior month. Whenever  latest month come treat as a current month and rest all in prior month. Please refer below examples screen shot.

 

Srawat_0-1661850780094.png

 

Thanks,

3 REPLIES 3
IraWatt
17 - Castor
17 - Castor

Hey @Srawat,

Assuming your columns are ordered you could use a formula like this:

 

IF [Field1] = "Latest month" THEN "Current" ELSEIF !Contains([Field2], "closing") AND !IsEmpty([Field2]) THEN "Prior" ELSE NULL() ENDIF

 

IraWatt_1-1661851707027.png

 

It checks if its the latest month if yes use "Current" If the date column is empty and does not contain closing then "Prior" else leave the row empty .

 

The community has some quick and easy videos on formulas and the Formula Tool here https://community.alteryx.com/t5/Interactive-Lessons/tkb-p/interactive-lessons/label-name/Writing%20...

 

Any questions or issues please ask

Ira Watt
Technical Consultant
Watt@Bulien.com 

 

binuacs
21 - Polaris

@Srawat Just to confirm your data look like the above? Also if you are closing in August the current month should be Jun which is 2 months less than August.

binuacs
21 - Polaris

@Srawat One way of doing this, this is method is dynamic.

 

binuacs_0-1661852271821.png

 

Labels
Top Solution Authors