Hello:
Yes. You would do this in a query. Make a query with your column data in it. Enclosed are the first two expressions to extract your data.
'
Expr1: Left([Field1],InStr(1,[Field1]," ")-1)
'
Expr2: Mid([Field1],InStr(1,[Field1]," ")+1,InStr(InStr(1,[Field1]," ")+1,[Field1]," ")-InStr(1,[Field1]," ")-1)
'
Substitute your column name for Field1 in all the statements. Continue the same procedure for the rest.
Refer to Left, Mid, and Right functions in VBA
Regards
Mark
Mark's routine will break the entries up into words but you might have to write extra code to deal with entries which don't exactly match the pattern of [title] [firstname] [lastname] [suffix]. Even then you'll have to check the results by eye - there are bound to be some weird entries that don't fit.
Geoff is right. Names are just like addresses when it comes to separating the various components. In my younger days I did some temp work for a huge bank that spents 10's 0f 1000's of dollars in their IT department trying to figure out how to "automatically" import data from an aquired bank's system. They finally spent far less hiring temps to re-enter the data by hand!
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.