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.

Terminate Relationships

Featured Replies

  • Newbies

I have realtionships that I would like to teminate after a specified date. Once a certain date is trigerred I reference a local field and no longer need the Related File to be referenced. Is there a way to do this? Thanks in advance!

You should have wrote that into your pre-nub. smile.gif

but the answer is no, you can't. There isn't really a reason to either...

You could do that with a calculated key.

Just make the key change to "Invalid", or "Expired" or something else that it would never find a match to on the other side if the criteria is not met.

As long as there are no globals or other related fields in the calculation it can be indexed and a relationship can be created.

  • Author
  • Newbies

The main reason for this is to stop the file from referencing and opening another file that is no longer needed. Thanks for the reply, clever idea for a prenub wink.gif

I think you will find that it will open the file regardless. Reason being is because it will always look for a match regardless.

My suggestion will only create a no match situation, but FileMaker will still need to open the file to determine this.

The only way to keep FileMaker from opening the file is to not reference, display, edit, calculate anything that refers to that relationship. Othewise, the file must open.

  • 2 weeks later...

The only way to keep FileMaker from opening the file is to not reference, display, edit, calculate anything that refers to that relationship. Othewise, the file must open.

Quite true, however there may be a way...

The Case function is notable for the fact that it calculates only to the point where a valid result is returned, and any redundant syntax which follows is ignored. Therefore if the only reference within the file which uses the relationship is at the tail of a case function, viz:

Case(Status(CurrentDate) > RefDate + 9, LocalField, RelatedFile::RelatedField)

...then (in this example) the calc field will reference the related file until ten days have elapsed since RefDate, but after that, should ignore it entirely (and should not open it since it will not be referenced).

I've tried it out and it seems to work here with v5.5. Give it a try and see if it does what you want.

Somewhat picky point, but I think the Case function performs all the calculations, but selects the first match. Might be significant in something that takes a long time to evaluate.

-bd

Create an account or sign in to comment

Important Information

By using this site, you agree to our Terms of Use.

Account

Navigation

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.