Jump to content
Claris Engage 2025 - March 25-26 Austin Texas ×

Copy field value to all fields in found set (How?)


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

Recommended Posts

Posted

Hi,

I am new to filemaker, and I am trying to create a database to hold and manage my research data. Periodically I have to add large quantities of new data to the database, and I am hoping to find some tricks to save time and reduce errors.

One issue is, some fields in the records I enter at a given time will often have the same value. Also, I sometimes need to find a subset of records, and edit them by adding the same value into a particular field in all of the found records. Is there an easy way to do this without manually entering each one? (I have other questions but I think I should post separately.)

Marcel

Posted

Look up 'replacing' in FM's Help, then select 'Replacing data in fields'.

Posted

There are two good options I can think of. One is the find and replace command. The other is the replace field contents command. Both of these can operate on all records in a found set.

One problem you may run into with either of these in a multi-user setup is record locking problems. If another user is editing a record that is in your found set, you won't be able to do the replace.

One way around this is to use Set Field[] in a looping script. Then you can check for record locking and receive notification about which records weren't modified.

Dana

Posted

Thanks for the suggestions. I tried the find/replace command, and I can see how this would solve my problem. However, I am having trouble making the command search for and recognize an empty field. If I leave the "find what" box blank, put my string into the "replace with" box, and select "replace all" it doesn't search any of the records. I also tried putting the wildcard symbol * into the "find what" box, and this did result in a search through the correct field in all of the records exactly as I would like, but it did not result in any "finds" and hence, no replacements. I suspect it is looking for a literal * symbol. Think I am close...

Marcel

Posted

Don't confuse the Find/Replace (Menu > Edit > Fine/Replace) with the Find Mode, they are two separate functions.

The Find/Replace is much like you would find in a good text application. It is a literal find and replace. The Find Mode provides you the ability to use the Find Symbols like "", *, =, ... etc., Once the records meeting your criteria are in the found set, you can then replace field contents, etc.

You might also experiment with the Replace Contents (Menu > Records > Replace Contents) using a calculated results. This was how most of what the Find/Replace needs were accomplished prior to being introduce in v6.

HTH

Lee cool.gif

Posted

OK, I got it. The "replace contents" command seems to be the best way to do this. I am not expecting any multi-user conflicts, so I think the problem is solved. Thanks for all of the suggestions. This is a great forum.

(BTW, thanks for the comment about find vs find/replace. I do understand the difference, but was hoping that the wildcard symbol available in find mode would also be recognized by the "find/replace" function - turns out it isn't. I notice that all of the examples of find/replace in the filemaker help section assume that the field contains something, but the section is silent on the topic of finding empty fields, so I think this tool is less useful for this particular problem).

Marcel

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

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

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