Skip 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.

Removing Punctuation from a Calculated Field

Featured Replies

Hi. I could use some help with setting up a calculated field. My question is: how can I define a calculated field to remove all punctuation?

In case it helps to know the context I am using it in:

This field is converting a person's email address into a username. The username is defined as everything that comes before the @ sign in the email, must be all lowercase and must have no punctuation. So for example, "[email protected]" would have the user name of "fred22". I've got the first two parts covered, but I can't figure out how to remove the punctuation! So here's what I have so far, which is working okay:

(Lower(LeftWords(Email, 1)

Thanks so much!

-Karen

FileMaker Pro 3! Wow, you deserve a hand for sticking with that. Can't remember the last time i've even thought of version 3... Anyhow, welcome to the forums.

Best thing i can think of is to do several nested substitute statements, accounting for all the possible characters you want stripped:

Substitute ( ( Left ( email , Position ( email , "@" , 1 , 1 ) - 1 ) , "!" , "" ) , "." , "" )

That's a lot to take in at once, but just taking it one Substitute function at a time will show you what exactly i mean:

Substitute ( "you!the.user" , "!" , "" ) = youthe.user

Substitute ( "youthe.user" , "." , "" ) = youtheuser

HTH.

Jerry

Create an account or sign in to comment

Important Information

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

Account

Navigation

Search

Search

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.