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.

Choosing the best photo in nested tables

Featured Replies

I perform surveys by taking photographs of all the persons I encounter but each person can only be encountered once per survey. The survey table has a nested table with the individuals encountered, but each individual has a nested table listing all the photographs taken during that encounter. I want to flag one photograph from each encounter (the best for that individual). Then, from the best photo of each encounter, I want to flag the best overall photo for that individual. I've attached a sample of the database I'm using and how I am trying to make it work. I am trying to use the "set field" to flag the best image filename and add it to the parent table, then using the matching filenames to display the photo. From a table of best photos, I want to flag the overall best and using "set field", send that filename to the "best overall photo" table, and once again display the image by matching those filenames. For some reason when I set the field, the filename does not get passed up to the parent table.

The other method was to flag the child image with a "yes" field to indicate the best one. Then show that image in the parent table through a relationship where the parent table has a field that is always set to "yes". I've spent a ridiculous amount of time trying to get this to work properly but can't seem to get it quite right. Any help or suggestions would be greatly appreciated.

BestPhotosNested.fp7.zip

The best image of an encounter is an attribute of encounter and should be recorded in a BestImageID field in the Encounters table. Similarly, the overall best image of an individual should be selected by populating a BestImageID field in the Individuals table.

  • Author

So would you do this with a "Set Field" script? In the images table (grandchild table), setup a button next to the image I want to be the best encounter image that populates a field in the encounters table (child table) with the imageID? Then display that image via a relationship between ImageID and BestImageID? And then do the same in the encounters table, with a "Set Field" button that populates a field (BestOverallImageID) in the individuals table (Parent table) with the BestImageID of the encounters table? Then show the best overall image via a relationship between BestOveralImageID and BestIMageID?

More or less, yes.

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.