A
Alan B. Densky
I'm using Access 2000.
I have a names field that has inconsistent data in it. Sometimes it only has
a
FirstName and a LastName, and sometimes it also has a middle initial with or
without a period after it: FirstName MI LastName.
I'm currently parsing the field into FirstName and LastName by taking the
first name
from the left, and the last name from the right.
FirstName: Trim(Left([CustomerName],InStr([CustomerName]," ")))
LastName: Trim(Mid([CustomerName],InStrRev([CustomerName]," ")+1))
I'd like to know how I can parse out the middle initial, or the middle
initial and the period
if it exists.
Thanks,
Alan
I have a names field that has inconsistent data in it. Sometimes it only has
a
FirstName and a LastName, and sometimes it also has a middle initial with or
without a period after it: FirstName MI LastName.
I'm currently parsing the field into FirstName and LastName by taking the
first name
from the left, and the last name from the right.
FirstName: Trim(Left([CustomerName],InStr([CustomerName]," ")))
LastName: Trim(Mid([CustomerName],InStrRev([CustomerName]," ")+1))
I'd like to know how I can parse out the middle initial, or the middle
initial and the period
if it exists.
Thanks,
Alan