We are updating the requirements for Community registration. As of 7/21/21 all users will be required to register a phone number with their My Alteryx accounts. If you have already registered, you will be prompted on your next login to add your phone number.

Alteryx Designer Discussions

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

What will be the RegEx expression formula for dynamically renaming columns ?

ak515155
6 - Meteoroid

 

Hello ,

 

The column pattern is 

 

"Please select your level of awareness in the technology. [SQL]"

 

I want to rename the column into only 'SQL' . Appreciate if anyone has a potential solution.

 

Thanks and Regards,

Abhishek

5 REPLIES 5
Qiu
17 - Castor

@ak515155 

I suppose you want the string between [].

Capture3.PNG

shreyanshrathod
11 - Bolide

Hi @ak515155 ,

 

Check if this works for you. I hope I have understood your problem statement correctly. If not, requesting you to share a sample workflow explaining the same.

 

In my attached solution, I am assuming there will always be a set of '[]' in which resides your desired column name.

Let me know if the solution helps.

 

Cheers,

Shreyansh Rathod

messi007
13 - Pulsar

@ak515155,

 

The formula below will do the job for you as well:

 

messi007_0-1617258727837.png

 

Attached the workflow.

Hope this helps!

Regards

ak515155
6 - Meteoroid

Thank you @Qiu  !! This worked smoothly as expected. thanks a lot once again

 

If you can just explain the logic once , would be really helpful as I have just learning RegEx .

Qiu
17 - Castor

@ak515155 
Glad to help and thank you for the accept mark.

I use this site to form and test RegEx.

And you also find very detailed explanation on the right hand side.

https://regex101.com/

 

Regex.PNG

Labels