Bring your best ideas to the AI Use Case Contest! Enter to win 40 hours of expert engineering support and bring your vision to life using the powerful combination of Alteryx + AI. Learn more now, or go straight to the submission form.
Start Free Trial

Alteryx Designer Desktop Discussions

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

Date MultiRow Logic

Randell9845
5 - Atom
 

Hello!

How can I do the logic in the file? I want it so that every time the date1 and date2 month integers would be equal, it should default to a value of 12 and the succeeding rows would be Row - 1. Thanks!

 

 

1 REPLY 1
Bobbyt23
13 - Pulsar

You could use this formula in the multi row tool:

 

IF DateTimeMonth([Date1_Out]) = DateTimeMonth([Date2_Out])
THEN 12
ELSE [Row-1:Integer]-1
ENDIF

 

Making sure your date fields are dates first.

 

image.png

 

You will just need to tweak the formula to handle anything that comes before the first match instance though so they aren't negative, depending on how many you have above etc.

Labels
Top Solution Authors