Results 1 to 5 of 5

Thread: parsing a field

  1. #1
    Join Date
    Feb 2004
    Posts
    2

    Unanswered: parsing a field

    Could someone point me to right place -

    i have a field(full name) that i need to separate into 2 separate fields (first name and last name). what's the simplest way?

    tnx.

  2. #2
    Join Date
    Sep 2003
    Location
    Cincinnati, Oh USA
    Posts
    203

    Re: parsing a field

    Use the Leftword & rightwords function.
    Namefield = Jane Smith
    field FirstName = Leftwords(Namefield,1) = Jane
    field Last Name = Rightwords(Namefield,1) = Smith

    Originally posted by bwanaaa
    Could someone point me to right place -

    i have a field(full name) that i need to separate into 2 separate fields (first name and last name). what's the simplest way?

    tnx.
    Rick Knight
    KnightShift Office Solutions and Horse Breaking
    VB, VBA, FileMaker, Access Solutions, Web Solutions

  3. #3
    Join Date
    Feb 2004
    Posts
    2
    thank you

  4. #4
    Join Date
    Sep 2003
    Location
    So. Cal. USA
    Posts
    142
    Huh. Never knew that was an option. I would export the data TEXT, open it in Excel, copy/paste the column to be changed as plain text into Microsoft Word, have Word change spaces to TABS (^t) and then copy/paste back to Excel, and re-import into FileMaker. Jeez. Cool.

    I guess you have to keep the original Namefield though, right, or no? If this is only a one-time thing, you'd want to get rid of that Namefield for on-going database usage so you may still have to export the data and re-import into an empty shell where FirstName and LastName have no formulae.
    --ST

  5. #5
    Join Date
    Feb 2004
    Posts
    84
    Originally posted by Steve T.
    Huh. Never knew that was an option. I would export the data TEXT, open it in Excel, copy/paste the column to be changed as plain text into Microsoft Word, have Word change spaces to TABS (^t) and then copy/paste back to Excel, and re-import into FileMaker. Jeez. Cool.

    I guess you have to keep the original Namefield though, right, or no? If this is only a one-time thing, you'd want to get rid of that Namefield for on-going database usage so you may still have to export the data and re-import into an empty shell where FirstName and LastName have no formulae.
    --ST

    If you wanted to make this a one time 'thing' then you could write a script and use the SET FEILD command to do the calculation and then clear the 'orginal' value. You could even put data back into the orignal if you used a temp global field.

    The advantage of this approach is that the 'separated names' would still be editable. The other method would require a calc field which would make the database a little bt larger and you could not edit the 'calced' record. The disadvantage is you would need to write a script and trigger it with a button.


    thanks,


    Joe

Posting Permissions

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