Eng-Tips is the largest engineering community on the Internet

Intelligent Work Forums for Engineering Professionals

Extracting Data 2

Status
Not open for further replies.

Neak1

Computer
Sep 10, 2001
12
0
0
US
Hey Everyone,

I have a field called Name. In this field there is First Name, Last Name and middle initial. The field is 22 characters long. Each Portion of this field is separated by a blank space. Ex: Mary K Jones or Micheal J Jordan Jr What I need to do is extract the First Name only from this field using a query. I am not sure what type of syntax to use to do this since all the First Names are different lengths. Is there some way that I can say stop at the first blank space and give me the results?

Please Help!!!

Neaka

 
Replies continue below

Recommended for you

you can use Instr() to find the space, and then once you know where the space is, use Left() to take the characters up to the space. See the VB help for syntax & examples.


 
Status
Not open for further replies.
Back
Top