Skip to content

wordInBinary (Structured Query)

isubiker edited this page Feb 18, 2012 · 2 revisions

The wordInBinary constructor looks for the supplied word(s) or phrase(s) in text that has been extracted from binary documents. It can take three forms of input. In the first form, a simple word or phrase to search for is supplied:

{"wordInBinary": "Chomsky"}

In the second form, an array of words or phrases is supplied:

{"wordInBinary": ["Chomsky", "Aristotle"]}

In the third form, options can be supplied to control the searching behavior:

{
    "wordInBinary": "Chomsky",    // Can also be an array of words or phrases
    "caseSensitive": true,
    "stemmed": false
}

<constraint>
    <wordInBinary>Chomsky</wordInBinary>
    <caseSensitive>true</caseSensitive>
    <stemmed>false</stemmed>
</constraint>

Optional configuration:

  • caseSensitive (boolean) - Setting to true ensures that case is matched, false ignores case. The default behavior examines the query and if it contains upper-case characters it performs a case sensitive search. The above example would default to being case sensitive.
  • diacriticSensitive (boolean) - Setting to true ensures that diacritics are matched, false ignore diacritics. The default behavior examines the query and if it contains diacritics it performs a diacritic sensitive search.
  • punctuationSensitve (boolean) - Setting to true ensures that punctuation is matched in the query. It's not recommended to issue punctuation sensitive searches as they can not be resolved out of the indexes and can easily yield poor performance.
  • whitespaceSensitive (boolean) - Setting to true ensures that whitespace is matched exactly as it is in the query, otherwise whitespace is normalized. It's not recommended to issue whitespace sensitive searches as they can not be resolved out of the indexes and can easily yield poor performance.
  • stemmed (boolean) - Setting to true stems search terms (eg: "flying" also matches "fly" and "flew").
  • wildcarded (boolean) - Setting to true treats "*" and "?" as wildcards in the query.
  • weight (number) - Configure how important or how heavily this term weighs in the query. The higher the number the more this term will contribute to the score of the document, thus appearing higher in the search results.
  • language - Configure the language that the term is in (eg: "en", "de", "ja").
Clone this wiki locally