Knowledge Base

Search logic explained

in Ajax Search Pro Tips Tags: explainedkeywordslogicsearchsearch logic

As of version 3.2 it is possible to control the search logic.

General options -> Behavior -> Keyword Logic

 

There are 4 possible logics to choose from:

  1. OR (default)
  2. OR with exact word matches
  3. AND
  4. AND with exact word matches

OR

Match is found if any of the search keywords is part of the result. It's the least strict of all possible options – it returns many results, finds almost anything.

KeywordPossible resultMatch?
hellohello world, robot hereYES
hello robothello world, robot hereYES
hello bothello world, robot hereYES
help bothello world, robot hereYES
hello sciencehello world, robot hereYES

OR with exact word matches

Similar to the simple OR, but at least one keyword must match a whole word, partial results are not accepted.

KeywordPossible resultMatch?
hellohello world, robot hereYES
hello robothello world, robot hereYES
hello bothello world, robot hereNO
help bothello world, robot hereNO
hello sciencehello world, robot hereYES

AND

Every keyword must match at least partially the result.

KeywordPossible resultMatch?
hellohello world, robot hereYES
hello robothello world, robot hereYES
hello bothello world, robot hereYES
help bothello world, robot hereNO (help is not found)
hello sciencehello world, robot hereNO (science is not found)

AND with exact word matches

The most strict search logic. Every keyword must match a whole word in result.

KeywordPossible resultMatch?
hellohello world, robot hereYES
hello robothello world, robot hereYES
hello bothello world, robot hereNO (bot does not match a word)
help bothello world, robot hereNO (bot, help does not match a word)
hello sciencehello world, robot hereNO (science does not match a word)