Advent of Code is back! Unwrap daily challenges to sharpen your Alteryx skills and earn badges along the way! Learn more now.
Free Trial

Alteryx Designer Desktop Discussions

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

[urgent] Dynamic Rename based on the condition

hungdm
8 - Asteroid
F1F2F3F4
IDnullPRODUCTnull
nullnullnulldata
nullnullnullnull

 

 

I'd like to rename the column name with the value based on certain conditions in some cases below:

 

F1: to get data of the first row then concat with the current field name.

F2. don't change anything because the value of the first row = null. (really need help for this case)

F3: to get the first row value then replace the current field name

F4: to get first value of any rows of the column

 

Can alteryx 2020 help me in one of the scenarios above?

 

Thanks! 

 

Output expected:

 

F1_IDF2PRODUCTdata
 null  

 

 

2 REPLIES 2
PhilipMannering
16 - Nebula
16 - Nebula

Hi hungdm,

 

You may need to edit the IF statement in the formula to get exactly what you need, but the structure of the solution might look like the attached.

 

Hope this helps.

 

Philip

echuong1
Alteryx Alumni (Retired)

I'm not sure I understand your rationale for why the first column should keep the F1 portion. There is not a difference that I can see between F1 and F3. 

 

The attached workflow takes the first filled in value for each column and uses it as the field name. This could be a good starting place for you. 

 

echuong1_0-1598277737034.png

 

Labels
Top Solution Authors