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.

Find Records Based on Contents of Rows in Portal

Featured Replies

  • Newbies

I have a layout that contains a portal.  The portal shows rows which contain dates. The master table (the "one" table in the "one-to-many" relationship) has two global fields, gStartDate and gEndDate.  I would like to have a script that would do a find that would select all the records in the master table, that have related rows in the portal table, that fall within these two dates. 

 

What is the correct way to do this?

 

Thanks very much in advance to all for any info (or alternate approaches)!

  • Author
  • Newbies

It appears that the correct way is to put the filter criteria (in this case, the date range) into the relationship between the two tables.  I previously had it in the portal filter. Once it's in the relationship, you can add a calculated field to the master table to count the number of related fields in that date range. Then it's easy to do a find for when that calculated field > 0.

It appears that the correct way is to put the filter criteria (in this case, the date range) into the relationship between the two tables.  I previously had it in the portal filter. Once it's in the relationship, you can add a calculated field to the master table to count the number of related fields in that date range. Then it's easy to do a find for when that calculated field > 0.

 

This is a rather roundabout way, not to mention that you'd searching within a non-stored field that serves no other immediate purpose.

 

A better way would be to navigate to the child table, search for children that fall into the date range, then go to the related parents of the found set (if there is one).

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.