diff options
Diffstat (limited to 'doc/src/sgml/datatype.sgml')
-rw-r--r-- | doc/src/sgml/datatype.sgml | 17 |
1 files changed, 12 insertions, 5 deletions
diff --git a/doc/src/sgml/datatype.sgml b/doc/src/sgml/datatype.sgml index 0b60c61d480..11e246fa351 100644 --- a/doc/src/sgml/datatype.sgml +++ b/doc/src/sgml/datatype.sgml @@ -3923,11 +3923,18 @@ SELECT to_tsvector('english', 'The Fat Rats'); <para> A <type>tsquery</type> value stores lexemes that are to be - searched for, and combines them honoring the Boolean operators - <literal>&</literal> (AND), <literal>|</literal> (OR), - <literal>!</> (NOT) and <literal><-></> (FOLLOWED BY) phrase search - operator. Parentheses can be used to enforce grouping - of the operators: + searched for, and can combine them using the Boolean operators + <literal>&</literal> (AND), <literal>|</literal> (OR), and + <literal>!</> (NOT), as well as the phrase search operator + <literal><-></> (FOLLOWED BY). There is also a variant + <literal><<replaceable>N</>></literal> of the FOLLOWED BY + operator, where <replaceable>N</> is an integer constant that + specifies a maximum distance between the two lexemes being searched + for. <literal><-></> is equivalent to <literal><1></>. + </para> + + <para> + Parentheses can be used to enforce grouping of the operators: <programlisting> SELECT 'fat & rat'::tsquery; |