Alteryx Designer Desktop Discussions

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

Macro to Rename An Identified Field

redcoop55
Átomo

Hi Team 🙂

 

Apologies if this is a stupid question. I am looking to create a macro that will rename a string field from the incoming data connection to 'Customer ID' and date field to 'Date'.

 

I work with many different data sources and the 'Customer ID' and date fields almost never has the same name between data sources (e.g., 'Customer', 'Client', 'Customer Number', ect.). I would like to put this macro at the beginning of a workflow where I can map a field so it will change the field name from the selected field to 'Customer ID' and 'Date'

 

I have attached sample data that I am working with below. 

 

Regards,

Brad

3 RESPOSTAS 3
Tyro_abc
Bólide

Hi @redcoop55 

 

Not sure if I understood how that final structure would be, but tried something based on my understanding. Inside Macro, I used an Text Input to have possible list of names for customer and replacing them dynamically using "Dynamic Rename" tool. Please let me know if this is something you are trying to achieve. 

 

 

 

 

Best Regards

Arundhuti

redcoop55
Átomo

 Hi @arundhuti726.

 

Thank you so much for getting back to me. I did see this solution posted online previously. I was hoping to have a option to "select" from a dropdown menu the one field from the incoming data that would then be renamed as customer ID. For example, I could have data with the field names [name], [type], [date], [amount] where I would like to map whichever field I want to customer ID (in this case, it would be the [name] field but the macro would also allow me to map [type]  as the field to be renamed to 'Customer ID' if I chose to). Does that make sense? 

redcoop55
Átomo

I figured it out. It is simply to use the desired column information as a text input and use the "Show Field Map" on the macro input tool. Thanks @arundhuti726!

Enquetes
We’re dying to get your help in determining what the new profile picture frame should be this Halloween. Cast your vote and help us haunt the Community with the best spooky character.
Don’t ghost us—pick your favorite now!
Rótulos