Alteryx Designer Desktop Discussions

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

Dynamic Column Name Based On Maximum Date

Gary_Brock
5 - Atom

This seems simple enough, but I feel like I'm going in circles.

 

This data is stored in SQL Server.

 

I have a column that identifies the max date in the required date field. I have a calculation that is a projection for the next month, which I've labeled "NewCalc1". I need "NewCalc1" to be dynamic, and should be the max date plus one month, or "2021_11_01". I would do this for at least 12 months. "2021_12_01", "2022_01_01", etc.

 

Thanks!

 

 

 

AlteryxData.png

2 REPLIES 2

Hi @Gary_Brock 

 

I used Summarize to get the max date and then use Generate rows with some datetime functions to generate 12 months. Is this what you are looking for? Cheers!

christine_assaad_0-1639587388429.png

 

FlorianC
Alteryx
Alteryx

Hi @Gary_Brock,

 

In addition to the solution provided by @christine_assaad, here is an example on how to use those generated dates to dynamically rename your forecast fields.

 

Example workflowExample workflowWorkflow resultsWorkflow results

Florian Carrier
Strategic Solution Consultant
Alteryx
Labels