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.

indexed calculations ?

Featured Replies

Hello all,

Please forgive me as its been awhile since I've worked in FMP and I'm sure I'm just a little rusty.

So here is the problem

I three tables lets call them A,B,C

table A has a field called ID containing a string

table B has three fields

ID which is related to table A's ID and a field

COUNT which is a calculation field that contains count(A:ID) resulting in a the number of records in A that contain the ID.

MyBOOLEAN_A which is a calculation that checks to see if count is greater than 10(as an example)

table C contains 1 field

MyBOOLEAN_B set to 1 or true and related to table B and I have a portal showing the data related.

Sounds good right ? but the records don't show up in the portal because MyBoolean_A is not indexed. but no matter what I do I can't get it to index. I keep getting a message saying the field cannot be indexed because it references a related field, an unstored calculation field.... blah blah

any help or suggestions would be appreciated

mm

First when referencing a related field it will not index the field. The parent side of a relationship can have an unidexed field, but the child side must be indexed.

You will have to try to reapproach your method and adjust the parent side.

John is correct, but I'm finding it difficult to follow your scenario. Can you use the actual table names and tell us your requirements?

You mention needing to know how many records in TableB contain the foreign key for TableA. Do you need this in browse mode, or can you run a subsummary report?

More details.

  • Author

the Parent in this case would be table C since it has the portal ?

mm

  • Author

ok let me start over then I'm trying to track software.

So I have three tables. InUSE,Software,Hardware

InUSE contains two fields SoftwareID,HardwareID

Software contains many details about the software

but the man focus is is the fields SoftwareID NumLicenses NumInUse(this is where I count the number licenses for this software that are in use) and HaveLicense a calculation if(NumInUse < NumLicenses; True ; False )

then In Hardware I made a field called HaveLicense and set it to true then made the portal showing the details of available software.

does that make more sense ?

MM

Try making your calc =

Case ( NumInUse < NumLicenses ; SoftwareID )

then define a new relationship between Software and Hardware using the "x" operator, and change the calc field in Hardware to =

List ( AllSoftware::cAvailableID )

This field can be the match to a third occurrence of Software, to show only available records.

Note that as always with relationships depending on other relationships, you can expect some refresh issues - Refresh Window [ Flush cached join results] often comes handy in these situations.

  • Author

what is this "x operator" you speak ?

  • Author

I figured out what you meant thanks you very much that worked

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.