Jump to content
  • 0

Search Using Both "and" And "or"


ISlp59lp
 Share

Question

I'm using a search and report data page to show specific ball games.

 

User can select the sport to be "football" or "basketball".

User can select a game date.

User can select a school name.

 

My table of games lists sport, date, home school, and opposing school.  (The list of valid school names is the same for both home school and opposing school.)

 

In my search and report data page, the results are selected to be "Results that match all criteria (AND)".

 

How do I setup the search such that the user can insert one school name and the report will contain any games where the school name shows up in either the home school OR opposing school?

 

That is, I want my search to be 

     "sport" AND "date" AND (

          (schoolname = "home school" ) OR (schoolname = "opposing school")  )

Link to comment
Share on other sites

5 answers to this question

Recommended Posts

  • 0

You can add criteria to the field by selecting it from the picker (exactly the same way you add an HTML Block http://howto.caspio.com/datapages/datapage-components/html-blocks/)and choose OR as the logical operator between the criteria, so user will be able to select two options to search for.

 

Or you can select listbox as form element and check to allow multi select and select OR.

Link to comment
Share on other sites

  • 0

Hello there,

This feature is now possible in Caspio. I have the same logic with my app, I think it will be something like this one: https://prnt.sc/mbltu9

Also, you can check out this link for more information about Comparison Types in your Reports DataPage: https://howto.caspio.com/datapages/reports/search-and-filter-comparison-types/

Have a great day :D

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
 Share

×
×
  • Create New...