Start a new topic

Reg Ex help - first name from Last, first middle

I have a field that has a combined Last name, first name middle name. I have reg ex dictionaries to get the last name and middle name but the one we are using for first name [ (.*), ] is giving both first and middle name. Is there one that can give us just the first name. Example name Graves, Melissa Siobhan.

Melissa S. Graves

1 Comment

Hi Melissa,

You can make three dictionaries with the same value to match:

(.+), (.+) (.+)

Then the replacement values would be (one for each dictionary):

Last Name Dictionary: $1
First Name Dictionary: $2
Middle Name Dictionary: $3

And make sure you check "Use Regular Expressions" for each dictionary.

This assumes that there is exactly one comma and one space between Last and First and exactly one space between First and Middle.

Login or Signup to post a comment