Extracting Part of Field

  • Thread starter Thread starter Ron
  • Start date Start date
R

Ron

I have a colum with the customers first name and last name
in the field. But i need to seperate them and place them
in two different colums names "First Name" and "Last
Name". There is always a space between the first name and
last name, and of cource the first name and last name vary
in length.

I can't do it with "left([FieldName],3)"

How do i write the expression to seperate them?
 
To get first name:

left([name],InStr([name]," ")-1)

To get last name:

Right([name],InStr([name]," "))

I have ways to pull the middle name/initial also, if you need them. Let me
know.

-Renee
 
I didn't ask this question but it is something I need to do with data I
imported ... thanks for the solution!

Maggic


R said:
To get first name:

left([name],InStr([name]," ")-1)

To get last name:

Right([name],InStr([name]," "))

I have ways to pull the middle name/initial also, if you need them. Let me
know.

-Renee


Ron said:
I have a colum with the customers first name and last name
in the field. But i need to seperate them and place them
in two different colums names "First Name" and "Last
Name". There is always a space between the first name and
last name, and of cource the first name and last name vary
in length.

I can't do it with "left([FieldName],3)"

How do i write the expression to seperate them?
 
Back
Top