We’ve extended Inspire Early Bird Pricing until March 1. Register now and enjoy 20% off conference passes and 10% off training passes. P.S. Don’t forget to bring friends! When you sign up for five or more tickets, you get an extra 20% discount on conference passes. Learn more now.

Alteryx Designer Desktop Discussions

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

Dynamically Change A Field Type

12 - Quasar

Hello --


Is there a way to Dynamically change the field type based on the Field header names? For instance:


txt_One      txt_two   num_one   bool_two  txt_three


If I wanted to change all fields that started with txt from String to vString how can I do that? I feel that Dynamic Replace might be the ticket, but I have not yet had success in making this happen.




17 - Castor
17 - Castor

I've attached an example that uses the Dynamic Select tool and the Multi-Field Formula tool.


- The Dynamic Select only selects the fields based on the name of those fields.

- Multi-Field Formula has an option to "Change Output Type to" to set the new field type of the dynamically selected fields.

- (Messy) I rejoined by position, with the original on the Right input so that I can use another Dynamic Select to deselect any fields with a "Right_" prefix (the original fields with original field types).









12 - Quasar

Perfect! Thank you and have a nice weekend!

8 - Asteroid

Thank you!  I've implemented this internally with the URL to this post in the comments.  Is there a better way to give you citation credit?  

17 - Castor
17 - Castor



I'm glad this information was helpful. Citation is not necessary, but I hope the usefulness of this information inspires other to participate in the Community.