lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Kumaran Ramasubramanian <kums....@gmail.com>
Subject indexing analyzed and not_analyzed values in same field
Date Tue, 25 Oct 2016 18:37:10 GMT
Hi All,

i have indexed 4 documents in an index where BANKNAME field is analyzed in
two documents and it is not_analyzed in another two documents. i have
mentioned search cases below where i am able to search using both analyzed
( using classic analyzer ) and not_analyzed ( using keyword analyzer )
terms. But, is it right to have index with both analyzed and not_analyzed
values in a field?




output:


BANKNAME field of these two documents is analyzed

using classic analyzer
 query : BANKNAME:"swiss bank"
total hits:2

DocId:0  DocScore:1.6096026
[stored,indexed,tokenized<BANKNAME:swiss  bank>,
stored,indexed,tokenized<PLACENAME:swissland>,
stored,indexed,tokenized,omitNorms,indexOptions=DOCS_ONLY<company:goog>]

DocId:2  DocScore:1.6096026
[stored,indexed,tokenized<BANKNAME:swiss  bank>,
stored,indexed,tokenized<PLACENAME:swissland>,
stored,indexed,tokenized,omitNorms,indexOptions=DOCS_ONLY<company:goog>]





BANKNAME field of these two documents is not analyzed

using keyword analyzer
rrsk query : BANKNAME:swiss bank
total hits:2

DocId:1  DocScore:1.287682
[stored,indexed,tokenized<BANKNAME:swiss bank>,
stored,indexed,tokenized<PLACENAME:swiss>,
stored,indexed,tokenized,omitNorms,indexOptions=DOCS_ONLY<company:goog>]

DocId:3  DocScore:1.287682
[stored,indexed,tokenized<BANKNAME:swiss bank>,
stored,indexed,tokenized<PLACENAME:swiss>,
stored,indexed,tokenized,omitNorms,indexOptions=DOCS_ONLY<company:goog>]






--
Kumaran R

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message