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.

Performance problems with loop function

Featured Replies

Hi,

I have developed a job bag system with which I am experiencing some performance problems with loops. The system is served by a Mac G4 to around 10 cross platform hosts.

This is my scenario: I have 2 databases - Jobs and Contacts. I go to create a new job, and I am asked to choose who the job is for - the contact. I have a list of available contacts which is a portal. The relationship is based on a global number field in the jobs database, which is set to 1 and a match field which is a number (or flag) in the contacts database which can either be '0' or '1' (so that contacts marked as '1' appear in the selection list). I have a filter function so that, say I know that the contact who the job is for contains 'John', I can type this into a text field and press the filter button, and return all the 'John's' in the contact database in the selection list. This works by first looping through all the contacts setting the number (flag) field to '0', then performing a find and finally setting all the matches number (flag) fields to '1' by looping through them again.

This works fine, but it is slow, can anyone suggest an alternative approach to this, should I be using Filemaker server - would this speed it up?

Many thanks for any help or advice.

Regards

Kevin Price-Ward

Hi Kevin,

Sometimes performance gets better when you add the 'Freeze Window' script step at the beginning of the script.

But I think for your problem you would be better of using something like Ugo describes in his example:

http://www.fmforums.com/threads/showflat.php?Cat=&Board=files&Number=56068&page=5&view=collapsed&sb=5&o=&fpart=1

Besides being a more elegant approach, Ugo's solution is also multi-user friendly, which your method does not seem to me...

About using FMServer; though this may improve performance somewhat, I would suggest 'cleaning up' your solution first.

Best regards,

Ernst.

  • Author

Thanks Ernst,

I will take a look at that when I get a moment.

All the best

Kevin

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.