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.

Calculated Results

Featured Replies

I have this list of names that I want to run a calculation on. Basically I want to start with the first name, preform a script, which will return a result, and insert the result in the name's record. I have thought of some ideas but there's got to be an easier way. Any suggestions?

We probably need a little more detail, but this can be done with a SetField and a looping script or a Replace with a calculation.

-bd

  • Author

More detail...

I have a database called Name, it has a bunch of names. I have another db called Basic, it has a bunch of info related to the Name db.

What my script does: It takes a name from the Name db and does a find on how many times it shows up in a specific field in the Basic db, then it gets a percentage of that number, and finally inserts it back into the persons record in the Name db.

What I want to do is automatically do all the names in the list without manually selecting each name and running the script.

With a relationship NameToBasic and a relationship AllRecords(make a calculation field in each that's a constant, i.e. cOne = 1, then for the AllRecords relationship match cOne to cOne so that all records match the relationship)

Percentage = (Count(NameToBasic::Name) / Count(AllRecords::cOne)) * 100

  • Author

Thanks, that solves a lot of others problems. But what happens if you want to subtract from the (Count(NameToBasic::Name). I want to take out anyone that is > $1000 and State = NC from the total. And the money is in another database as well.

Probably the best way to take out certain records selectively, is to create a lookup field (called "Amount") in your Basic db to bring the money amount into the Basic db, then create a stored and indexed calc field in the Basic db which has a formula along the lines of:

Case(Amount > 1000 and State = NC, "", Name)

Then, from within your Name db, re-define the NameToBasic relationship to match to the new calculating field in the Basic db.

That's it, now your summary and the resulting percentage will exclude the records that meet your criteria.

  • Author

That works, thanks.

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.