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.

newbie find / currentfoundcount problem

Featured Replies

  • Newbies

Hi there

I'm new to filemaker, and I'm running into a really frustating problem that I'm hoping a guru out there can help me with.

Here is the set up.

I have a basic database designed for entering, sorting and summarising bugs in a piece of software. All is going well except for a "statistics / summary" page.

What I want is a page that summarizes the number of bugs of different states, and different severities displayed in a table like (and this is a simplified version):-

Total A B C D < these are severity categories

All bugs 25 2 17 2 4

Open etc

Open please verify fixed

Closed fixed

Closed by design

Currently, the way I have it set up is a different number field for each of the numbers I want to calculate above, and I've begun writing a script that performs a find on the bugs entered which satisfy the specific criteria, and counts the result. The first one is easy - find total # of bugs - just a script saying

show all records

insert calculated result [select, "All bug # totals", "Status (CurrentFoundCount)"]

Got to Layout ["Statistics"]

For testing purposes, and to get my head round this, I've been writing many little scripts for each search / find, and creating a script that performs the seperate subscripts for each find / count procedure.

So moving along, the next mini script is to find the total number of A severity bugs:-

perform find [restore, replace found set]

insert calculated result [select, "All bugs #A", "Status (currentfoundcount)"]

got to layout ("Statistics")

the same kind of script is written for all the remaining fields, just with differing find criteria based on 2 fields, "bug status" (open, closed etc.) and "bug severity" ("A - must fix" to "D - enhancement request").

If you perform the sub scritps individually, they work, and return the numbers in the correct fields. If you try running the main script which calls these subscripts - which I want to then add all the counts for all the finds, the 1st # is shown (i.e. for total number - with no find scritp step) and the last find script number is displayed. However all the other number fields are blank.

I'm assuming this is either a bug or a misunderstanding of the status(currentfoundcount) functionality on my part. It seems that status(currentfoundcount) clears each time, and only returns the last count from the subscripts in the main script. But it's driving me insane and I need help figuring it out!

TIA

Tamsen

Hmm, there are a variety of possibilities.

One is that you are storing the results of the current found count. This will permanantly stick it into a field and it will not be refreshed. Make sure that any calculation fields that use this, are set as UNSTORED.

Another is that you are storing these values in one or more seperate records and are simply not able to find and display them again. Say you find and store the results for the search for "A", then do it for "B", and so on. By the time you are finished, you have the results scatter singly across at least 7 different records. To solve this, make the fields that you are storing the results in GLOBALS.

  • Author
  • Newbies

Hi Kurt

Thanks! I works a treat - I've changed the fields to global and everything seems fine

Thank you so much!

Tamsen

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.