Results 1 to 2 of 2
  1. #1
    Join Date
    Oct 2004
    Posts
    29

    Unanswered: Is there an easier way to this?

    In my property owner databases I get my first name and last name joined.

    Example:

    ALFORD CARL L
    BOOTH MICHAEL L & ANGELA D (if theres shared, or 2 owners)
    PIERCE COMER C JR

    Because all the names are not set up in the same way, (initials, 2 owners, etc.) Because of this reason, when i want to seperate them i have to put commas wherever i want each record to be seperated, then export it into text and then import it back and make comma the seperator.

    So... is there any easier way to do this?

    Thanks.

  2. #2
    Join Date
    Jan 2004
    Location
    Aberdeen, Scotland
    Posts
    1,067
    is there any set standards to the split i.e. on instance of an Apersand (&) split to 2 seperate fields if thats what you want you could write an update query based on the Mid Function

    otherwise it could be a bit of a nightmare and probably impossible without user intervention

    Edit code added
    something like
    Code:
    UPDATE tblName
     SET tblName.col1 = Trim(Mid([Col1],1,InStr(1,[Col1],"&")-1)), 
            tblName.Col2 = Trim(Mid([Col1],InStr(1,[Col1],"&")+1,(Len([Col1])-InStr(1,[Col1],"&")+1)))
    WHERE (((tblName.col1) Like "*&*"));
    Last edited by DavidCoutts; 01-07-05 at 07:20.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •