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.

Comparing 2 fields

Featured Replies

Is there a way to do a find by comparing 2 fields without creating a 3rd field(that would contain the result of the comparison)?

for example, set field("field 1", ">= field 2")

FM is not accepting this: it is not taking the value of field 2 but the actual field name...

No. Unless you want to resort to scripting, you have to make a calculated field and search for it.

  • Author

Too bad...

Again,without adding another field (the file has over 30000 records, so I am trying to avoid adding extra fields), can a date field be compared to a formula like "Today - 14"?

You are probably going to give me the same answer, but I had to ask...

1124965230-Copy_and_Paste_Single_file.zip

If you want to do something like today-14, I would create a script like this:

code:


Enter find mode [no restore]

Set Field [MyDateField, Status(CurrentDate)-14]

Perform Find [no restore]


That will find all record exactly 14 days old. If you want to find anything more than 14 days old, you can use this script.

code:


Enter find mode [no restore]

Insert calculated value [select][MyDateField, "<"]

Insert calculated value [MyDateField, Status(CurrentDate)-14]

Perform Find [no restore]


If these are frequent searches that you are doing, the script is the way to go, because you don't have to wait for records to recalculate and re-index. Also, you can use global fields to get some of the search criteria from the user and then use the script to transfer it to the appropriate fields in the find request. Globals don't take up any significant amount of room and they give the user some flexibility.

[ September 19, 2001: Message edited by: BobWeaver ]

  • Author

Excellent!

I did not know about this "Insert Calculated Result", it works great. This is exactly what I needed.

Thank you very much.

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.