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.

Combining OR and AND in a link command

Featured Replies

Once again the and/or mixed metaphor.

While this has been discussed many times, I still have not seen an answer which is any better than this: the operators 'and' and 'or' are not usable as you are proposing.

If you look at the cdml reference page "Operator ... Tag Type Variable", you will find a list of operator values. There is even an example of the operator "eq" in a form action. If you attempt this, you will be equally disappointed. (pardon the pun)

My experience is that these tags work well when you are embedding a conditional [fmp-if] on a format file. They work well in such situations as:

[fmp-if: fieldname .eq. '']

display this text

[fmp-else]

display this other text

[/fmp-if]

What you need to learn is how to use the symbols of the database's status tool bar which are offered during a 'find' in the database file. Essentially, I am talking about ==, >=, <=, *, etc. Essentially these can be used in your cdml code, be it form action or link action.

A recent example of this type of code was offered here in a posting started by "helmut" (I don't recall the name of the subject line) in which code for finding in a range was offered. Also there have been several mentions of FileMaker technical reference articles on the exact search (==).

When you learn how to use these symbols in your code, you will be able to solve your problem.

Peace

Keith

I have a database that contains different products and different vendors for each product.

I am trying to write a link command that looks for

ANY of three values in one field (PRODUCT)

and

ALWAYS one value in another field (VENDOR)

For example:

I would like to create a button, that when pressed, finds all the apples oranges and grapes that the vendor, ACME, has to offer. (but not the bananas or pears, etc.)

The code below just finds all of ACMEs products and ignores the types that I want to retrieve.

http://193.100.100.175/TT/FMPro?-DB=ProductsForSale.fp5&-Format=search_results.htm&PRODUCT=apple+orange=grape&-LOP=OR&-Op=eq&VENDOR=ACME&-Find=

Deleting the "-OP=eq" in front of my vendor gives me the same results.

Putting the VENDOR part before the PRODUCTS part of the command still gives the same results.

If I delete the whole section "&-Op=eq&VENDOR=ACME" then the "or" operator seems to work just fine (I get the right fruits) but I get them from ALL vendors, not just ACME.

Help?!

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.