Upute za pretraživanje
Slijedeće upute vrijede ukoliko je pojam koji se pretražuje duži od 3 slova (4 ili više). U slučaju pretraživanja pojma od 3 ili manje slova navedeni booleovi operatori neće raditi, a pretražuje se jednostavno niz navedenih zankova.
Ukoliko se polje za pretraživanje ostavi prazno dobiva se popis svih pitanja (20 po stranici) poredanih po datumu primitka od zadnjeg prema prvom.
Dakle, ukoliko je ovo zadovoljeno onda:
The boolean full-text search capability supports the following operators:
A leading plus sign indicates that this word must be present in every row returned.
A leading minus sign indicates that this word must not be present in any row returned.
By default (when neither
-is specified) the word is optional, but the rows that contain it are rated higher.
These two operators are used to change a word's contribution to the relevance value that is assigned to a row. The
>operator increases the contribution and the
<operator decreases it. See the example below.
Parentheses are used to group words into subexpressions. Parenthesized groups can be nested.
A leading tilde acts as a negation operator, causing the word's contribution to the row relevance to be negative. It's useful for marking noise words. A row that contains such a word is rated lower than others, but is not excluded altogether, as it would be with the
An asterisk is the truncation operator. Unlike the other operators, it should be appended to the word.
A phrase that is enclosed within double quote (‘
"’) characters matches only rows that contain the phrase literally, as it was typed.
If the phrase contains no words that are in the index, the result is empty. For example, if all words are either stopwords or shorter than the minimum length of indexed words, the result is empty.
The following examples demonstrate some search strings that use boolean full-text operators:
Find rows that contain at least one of the two words.
Find rows that contain both words.
Find rows that contain the word “apple”, but rank rows higher if they also contain “macintosh”.
Find rows that contain the word “apple” but not “macintosh”.
'+apple +(>turnover <strudel)'
Find rows that contain the words “apple” and “turnover”, or “apple” and “strudel” (in any order), but rank “apple turnover” higher than “apple strudel”.
Find rows that contain words such as “apple”, “apples”, “applesauce”, or “applet”.
Find rows that contain the exact phrase “some words” (for example, rows that contain “some words of wisdom” but not “some noise words”). Note that the ‘
"’ characters that surround the phrase are operator characters that delimit the phrase. They are not the quotes that surround the search string itself.