Alteryx Designer Discussions

Find answers, ask questions, and share expertise about Alteryx Designer.
Don't forget to submit your entry for the Excellence Awards by October 30! | Need more information about the program? Check out the blog here
SOLVED

Convert Text value into Field Name

Highlighted
8 - Asteroid

Hi All - 

 

I have situation where I have to merge two fields into one... let say First Name  and Last Name into new field "Full Name".

 

very simple process but thing is that  these two fields name could change in future, so is there way I can control these two field header through mapping or interface design.

 

what in my mind is if I could two text box and consider their value as field header.

 

please let me in case of more clarification.

 

Thank you.

 

Highlighted
11 - Bolide
11 - Bolide

Hi @Mukeshy12390Jpmc 

 

I'd probably just use a dynamic rename tool, as attached and below

dynamicrename.PNG

 

 

Hope that helps

 

Andy

Highlighted
8 - Asteroid

thanks for quick reply. I will check and confirm solution.

 

Do know if there is any formula which coverts string reference into field name.

like in Excel we have "Indirect function"

 

eg - "[" + [#1] + "]"

Highlighted
11 - Bolide
11 - Bolide

Yes, the Dynamic Rename tool allows you to rename column(s) based on an expression, as well as lots of other functionality. 

 

I'd recommend taking a look here, though if you need a specific example let me know 

https://help.alteryx.com/2018.2/DynamicRename.htm

 

Andy 

Highlighted
8 - Asteroid

Hi Andyuttley,

 

one question , as I'm using two field for calculation (using Dynamic rename).

 

how can I get original fields (before rename) and along with new fields (after rename)?

 

Thanks.

 

 

 

Highlighted
11 - Bolide
11 - Bolide

Hi @Mukeshy12390Jpmc 

 

Can you give an example of exactly what you're trying to do? 

Thanks

Highlighted
8 - Asteroid

Okay. I will try.

Here is the situation.

I'm merging two text column .. let say "First Name" and "Last Name", As these two field header could change in future so controlling through mapping using "Dynamic Rename".

 

in mapping Column1_FirstName = First Name and Column2_LastName = Last Name.

once I renamed it I using "Dynamic Rename" tool I lose original name. 

 

How can i get and maintain both before rename columns and after rename column.

in other word I want all four columns. "Column1_FirstName = First Name and Column2_LastName = Last Name."

 

 

 

 

 

 

Highlighted
11 - Bolide
11 - Bolide

Interesting use case! Few ways you could do it. Simplest way would be just to join the data back to the input (by record position) once you've passed through the dynamic rename (as this will give you all four fields). 

 

Like this

Capture.PNG

Labels