Jump to content
View in the app

A better way to browse. Learn more.

FMForums.com

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Parse Comma Delimited field

Featured Replies

  • Newbies

Field is: LastN Suffix (e.g. Jr.), FirstN MiddleN (note comma between Suffix & FirstN

The field's data may have only LastN and FirstN or any combination of the above (2 up to 4 words).

e.g. Smith, Allen (2 names) or Smith Jr., Allen (3 names) or Smth, Allen Sterling (3 names) or Smith jr., Allen Sterling (4 names)

The result needed for each field is -

FirstN MiddleN (if any) LastN and Suffix (if any) in one field with out comma

I have seen postings about saving a copy as global. Is this a file or field? And using the Position function. All in all I am totally confused. Any help would be appreciated.

crazy.gif

Assuming there's no comma between the LastN and the Suffix (as there theoretically should be), you can use the "Position" command to find the first word after the comma. Sorry, too tired right now to do the whole thing for you, but it's a start.

I'll be the Professor of Logic for today... cool.gif

Last Name =

Left(Name, Position(Name, ",", 1, 1) - 1)

Here the Position() function tells us what character number the comma is, and since we don't want the comma, we subtract one. The Left() function tells us to get that many characters.

First Name =

Right(Name, Length(Name) - Position(Name, ",", 1, 1))

Here we need to sort of flip the first function around, so we get the Length of the Name and subtract the function we used in the first step.

so the Full Name = Right(Name, Length(Name) - Position(Name, ",", 1, 1)) & " " & Left(Name, Position(Name, ",", 1, 1) - 1)

I know it's a bit of a mind-bender. Have some coffee and read the online help, it explains it better than I could.

  • Author
  • Newbies

Thanks to both of you for the help. Dan got me started in the correct direction and Fitch gave me the "nuts and bolts". It is working beautifully.

Not exactly Tinker to Evers to Chance, but then I was never a Cubs fan anyway.

Create an account or sign in to comment

Important Information

By using this site, you agree to our Terms of Use.

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.