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.

Featured Replies

I've got four related tables:

tblModel, tblAttend, tblClass, tblClassType

tblModel:

- modelID

tblAttend

- modelID

- classID

tblClass

- classID

- classDate

- classTypeID

tblType

- classTypeID

- classCategoryID

The tables all relate on the ID fields. What I'm trying to do is create a calculated field in tblModel which shows the details from the last related tblClass record for classes which occurred in the past and which are for classTypeID's in a specific category.

I'm able to do the date restriction no problem by adding a global date filter in tblAttend. However, restricting the classTypeID to a specific category is proving more difficult.

I found I was able to do this if I had an auto-enter field for the classCategory in tblClass, but this would break if the category changed for a specific classType. If I tried to use a calculation field for the classCategory in tblClass, it just didn't seem to work.

Any advice? I'm attaching a sample file with how far I've got. I'm able to do the date filter, but not the category.

test4.zip

Why not use a global ClassCategory filter in Class as well?

Note that these intermediary global filters will require a Refesh Window [ Flush cached join results ] script step in order for the portals to update.

  • Author

I've tried doing that, but it didn't seem to work. I applied it to the relationship from tblClass->tblType. It didn't filter the resulting calculated field in the tblModel table.

The calculation there is basically:

last(tblClass::classID)

This would work in a portal if I based the portal on the appropriate TO for tblType, but not in the calculated field.

The only thing I've been able to get to work is doing an auto-enter field in tblClass for the category and filtering on that from tblAttend. The same filter wouldn't work if I used a calculated field instead.

I read you.

It looks like you need to make the destination portal from a TO of Class on the other side of the Category table. Move the filters around a little, and voila!

See the attached file.

test4v2.fp7.zip

  • Author

That's it! Thanks so much!

  • Author

Hmm, maybe not. I'm still not quite able to get the calculated field correct. I'd like to have a calc field which shows only the last (or next) chronological record from class for which there is a modelID->classID correspondence. The specific classID seems to get lost in this scenario and I wind up filtering down to any class with the appropriate classCategory and Date, not exactly what I want...

  • Author

Actually, not quite.

I'm still not able to get the calculated field correct. I'd like to have a calc field which shows only the last (or next) chronological record from class for which there is a modelID->classID correspondence. The specific classID seems to get lost in this scenario and I wind up filtering down to any class with the appropriate classCategory and Date, not exactly what I want.

It looks like this type of filtering relationship doesn't really work in FM and that I'll have to use the auto-enter field within the tblClass.

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.