Alteryx Designer Desktop Discussions

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

Generate rows: "the value did not change after loop"

CarstenWiedemann
5 - Atom

Hi all,

I use the "Generate rows" tool to create daily entries for data with only starting and ending dates, following exactly the tool's example workflow.

Nonetheless the tool does what it's meant to do but shows an error "The value did not change after the Loop Expression"

The Loop expression is: DateTimeAdd([Entrydate],1,"days")

I have no clear understanding what is meant with "The value" as every value in the generated rows shows what i asked it to show. Does anyone have an idea where I maybe wrong? (I cannot attach an example from my data but I use the tool exactly the same way as in the example workflow)

Thanks in advance!

 

Best regards

Carsten

2 REPLIES 2
MarqueeCrew
20 - Arcturus
20 - Arcturus

@CarstenWiedemann ,

 

Looping with dates is tricky.  Here is a link to a gallery macro that I created to that generates all the days (time units) between two dates (time units).

 

https://community.alteryx.com/t5/Community-Gallery/CReW-Generate-Date-Rows/ta-p/926163

 

If you want to understand the looping, you need to initialize with a DATE (e.g. FROM_DATE) and then  compare that date to the looping variable (e.g. [OUT__DATE] <= [TO__DATE])  and Loop with an expression that adds the right days (units) to it (e.g. DateTimeAdd([OUT__DATE],1,"Days") )

 

 

Cheers,

 

Mark

Alteryx ACE & Top Community Contributor

Chaos reigns within. Repent, reflect and restart. Order shall return.
Please Subscribe to my youTube channel.
CarstenWiedemann
5 - Atom

Hi Mark,

 

thanks for your quick reply. After deeper analysis I found that the entries where my "startingdate" and/or "endingdate" was Null caused the error. After I excluded them by filter the row generation worked without error.

 

BR,

Carsten

Labels