From 764283bf8af2e05bcfb8b3d9b04b348f943469ab Mon Sep 17 00:00:00 2001 From: Erik Hatcher Date: Fri, 3 Oct 2003 03:01:05 +0000 Subject: [PATCH] minor touchup to QueryParser syntax docs git-svn-id: https://svn.apache.org/repos/asf/lucene/java/trunk@150074 13f79535-47bb-0310-9956-ffa450edef68 --- docs/queryparsersyntax.html | 12 +++++++----- xdocs/queryparsersyntax.xml | 12 +++++++----- 2 files changed, 14 insertions(+), 10 deletions(-) diff --git a/docs/queryparsersyntax.html b/docs/queryparsersyntax.html index 3cc44afb1b1..24d0b5076ab 100644 --- a/docs/queryparsersyntax.html +++ b/docs/queryparsersyntax.html @@ -135,7 +135,7 @@
  • Untokenized fields are best added directly to queries, and not through the query parser. If a field's values are generated programmatically by the application, then so should query clauses for this field. - Analyzers, like the query parser, are designed to convert human-entered + An analyzer, which the query parser uses, is designed to convert human-entered text to terms. Program-generated values, like dates, keywords, etc., should be consistently program-generated.
  • @@ -409,7 +409,7 @@

    Range Queries allow one to match documents whose field(s) values are between the lower and upper bound specified by the Range Query. - Range Queries are inclusive (i.e. the query includes the specified lower and upper bound). + Range Queries can be inclusive or exclusive of the upper and lower bounds. Sorting is done lexicographically.

    @@ -430,7 +430,7 @@
    -

    This will find documents whose mod_date fields have values between 20020101 and 20030101. +

    This will find documents whose mod_date fields have values between 20020101 and 20030101, inclusive. Note that Range Queries are not reserved for date fields. You could also use range queries with non-date fields:

    @@ -441,7 +441,7 @@ - + @@ -451,7 +451,9 @@
    title:[Aida TO Carmen]
    title:{Aida TO Carmen}
    -

    This will find all documents whose titles are between Aida and Carmen.

    +

    This will find all documents whose titles are between Aida and Carmen, but not including Aida and Carmen.

    +

    Inclusive range queries are denoted by square brackets. Exclusive range queries are denoted by + curly brackets.


    diff --git a/xdocs/queryparsersyntax.xml b/xdocs/queryparsersyntax.xml index 114a054e864..b5b8b36dfa0 100644 --- a/xdocs/queryparsersyntax.xml +++ b/xdocs/queryparsersyntax.xml @@ -25,7 +25,7 @@
  • Untokenized fields are best added directly to queries, and not through the query parser. If a field's values are generated programmatically by the application, then so should query clauses for this field. - Analyzers, like the query parser, are designed to convert human-entered + An analyzer, which the query parser uses, is designed to convert human-entered text to terms. Program-generated values, like dates, keywords, etc., should be consistently program-generated.
  • @@ -102,13 +102,15 @@

    Range Queries allow one to match documents whose field(s) values are between the lower and upper bound specified by the Range Query. - Range Queries are inclusive (i.e. the query includes the specified lower and upper bound). + Range Queries can be inclusive or exclusive of the upper and lower bounds. Sorting is done lexicographically.

    mod_date:[20020101 TO 20030101] -

    This will find documents whose mod_date fields have values between 20020101 and 20030101. +

    This will find documents whose mod_date fields have values between 20020101 and 20030101, inclusive. Note that Range Queries are not reserved for date fields. You could also use range queries with non-date fields:

    - title:[Aida TO Carmen] -

    This will find all documents whose titles are between Aida and Carmen.

    + title:{Aida TO Carmen} +

    This will find all documents whose titles are between Aida and Carmen, but not including Aida and Carmen.

    +

    Inclusive range queries are denoted by square brackets. Exclusive range queries are denoted by + curly brackets.