Bring your best ideas to the AI Use Case Contest! Enter to win 40 hours of expert engineering support and bring your vision to life using the powerful combination of Alteryx + AI. Learn more now, or go straight to the submission form.
Start Free Trial

Alteryx Designer Desktop Discussions

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

Formula to add a column with relevant information

suds144
8 - Asteroid

Hi Everyone,

 

I want to add a column to my data in alteryx which includes the name of the university. I have a list of email addresses with students university name and would like to translate this information to the name of the university.

 

So if my output is:

suds144_1-1646825722679.png

 

 

Then my ideal output would be:

 

suds144_2-1646825755843.png

 

I attach the dummy data for review as well. Thank you

5 REPLIES 5
atcodedog05
22 - Nova
22 - Nova

Hi @suds144 

 

Here is how you can do it.

Workflow:

atcodedog05_0-1646826210013.png

 

Hope this helps : )

 

suds144
8 - Asteroid

Amazing! I was using the formula tool but was using a different formula so it wasn't working! Thank you!

atcodedog05
22 - Nova
22 - Nova

Happy to help : ) @suds144 

Cheers and have a nice day!

suds144
8 - Asteroid

A quick question, could you please explain why you put ".*@(\u+)\..*","$1" - what do some of the symbols account for? I understand some but not all.

 

Thank you :)

atcodedog05
22 - Nova
22 - Nova

Hi @suds144 

 

".*@(\u+)\..*" in this (\u+) means take only letters which come after @ symbol. Wrapping with brackets () makes it a capture group and this will be first and only group

 

"$1" means replace the whole string with only the text in the first group.

 

Hope this helps : )

Labels
Top Solution Authors