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.

Help with creating a Find using logical or

Featured Replies

Hey all,

 

I've got the following find command statement. I need it to search on 4 fields, the first 3 being standard items, but the 4th field containing a possible of 4 different options. Any ideas how can I achieve this? Many thanks as always

 

$request = $fm->newFindCommand('Cars');
$request->addFindCriterion('Color','=='.$_POST['Color']);
$request->addFindCriterion('Distance',$_POST['Distance']);
$frequest>addFindCriterion('Age',$_POST['Age']);


$request->setLogicalOperator(FILEMAKER_FIND_OR);

$request->addFindCriterion('Type', 'Coupe');
$request->addFindCriterion('Type', 'Estate');
$frequest>addFindCriterion(''Type, 'Hatchback');
$request->addFindCriterion('Type', 'Saloon');
$requestResult = $request->execute();

 

I think it's called CompoundFind.

 

I tend to sidestep that, and use a calc field that I then search on. Points for laziness, negative points for elegance...

  • Author

Thanks webko, got it working with a CompoundFind

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.