In case you missed the announcement: The Alteryx One Fall Release is here! Learn more about the new features and capabilities here
ACT NOW: The Alteryx team will be retiring support for Community account recovery and Community email-change requests after December 31, 2025. Make sure to check your account preferences in my.alteryx to make sure you have filled out your security questions. Learn more here
Start Free Trial

Alteryx Designer Desktop Discussions

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

Full name split

LuckyRaju
7 - Meteor

I need to split the Full Name to First Name and Last Name.  First Name and Last name is separated with either space or any other Special character.  It should work for all the cased.  Can you please provide Regex FORMULA for the below. 

 

Full Name
TURNER, JANICE 
VAN, TAYLOR
BREAULT JASON 
LOOBY% CYNTHIA M

 

Full NameFirst NameLast Name
TURNER, JANICE TURNERJANICE 
VAN, TAYLORVAN TAYLOR
BREAULT JASON BREAULTJASON
LOOBY% CYNTHIA MLOOBYCYNTHIA M
6 REPLIES 6
ShankerV
17 - Castor

Hi @LuckyRaju 

 

This can be achieved with the help of Text to Columns tool.

 

Many thanks

Shanker V

ShankerV
17 - Castor

Hi @LuckyRaju 

 

Please find the use case explained for your scenario.

 

Screenshot 2023-07-18 223325.jpg

 

Many thanks

Shanker V 

ShankerV
17 - Castor

Hi @LuckyRaju 

 

Step 1: Input the data

 

Step 2: Text to columns tool.

 

Screenshot 2023-07-18 223325.jpg

 

Screenshot 2023-07-18 223325.jpg

 

Step 3: Data Cleansing tool used to remove the white spaces

 

Many thanks 

Shanker V

Prometheus
12 - Quasar

I think you can split the Full Name using a regular expression or you can do what I did and that's replace the comma with a space, remove extra spaces, then use the Text To Columns tool and parse on the space, which is "\s". Full Name Split.PNG

flying008
15 - Aurora

Hi, @LuckyRaju 

 

RegEx tool parse method for you:

 

^([A-Z]+?)[^A-Z]+(.+?)\s?$

 

录制_2023_07_19_08_07_39_836.gif

 

caltang
17 - Castor
17 - Castor

You can try:

(.+?),?\s(.+)

image.png

 

Add a Data Cleanse tool thereafter to remove whitespace and it'll be all good.

Calvin Tang
Alteryx ACE
https://www.linkedin.com/in/calvintangkw/
Labels
Top Solution Authors