Jump to content

Finding misspelled word, same field, many records


This topic is 6537 days old. Please don't post here. Open a new topic instead.

Recommended Posts

  • Replies 3
  • Created
  • Last Reply

Top Posters In This Topic

Popular Days

Top Posters In This Topic

FMP v6 provides a find and replace feature out of the box.

If you're working in an earlier version, the best approach is probably to script your own, using a couple of global fields and a script which loops through the records applying the a Set Field step to each in turn, with the formula:

Substitute(YourTextField, gFindWhat, gReplaceWith)

If you have only one problem to deal with - ie the "Sfa" issue, you might prefer to dispense with the global fields, and hard code your script as:

Show all Records

Go to Record/Request/Page [First]

Loop

Set Field ["Address", "Substitute(Address, "Sfa", "SFA")"]

Go to Record/Request/Page [Exit after last, Next]

End Loop


Which will do the trick by way of a 'one hit wonder' smile.gif

Link to post
Share on other sites

FYI next time, there is a quicker way, using the same idea, but no script.

First backup your file (if you make a mistake with either solution you might loose your entire field's contents)

In browse mode, select all records, then click in the address field.

Choose menu item Records->Replace... (cmd-= or ctrl-=)

Click 'Replace with calculated result...'

Enter the same formula as above, ie:

Substitute(Address, "Sfa", "SFA")

Click OK, then click Replace.

This does exactly the same thing as the above solution, but it is faster and doesn't require you to write a script.

(PS. Instructions generated for FMP5, but similar for other versions. Menu item moved from version 4->5).

Cheers,

John

Link to post
Share on other sites

This topic is 6537 days old. Please don't post here. Open a new topic instead.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.


×
×
  • Create New...

Important Information

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