0
我有使用OrietDB Lucene索引的問題。當我使用它查詢時,它會返回一個不完整的數據集。這裏是例子:OrientDB對lucene搜索的查詢結果不正確
create class Foo extends V
create property Foo.text string
create index Foo.text_spanish on Foo(text) fulltext engine lucene metadata
{ "analyzer": "org.apache.lucene.analysis.es.SpanishAnalyzer",
"index": "org.apache.lucene.analysis.es.SpanishAnalyzer",
"query": "org.apache.lucene.analysis.es.SpanishAnalyzer",
"allowLeadingWildcard": true
}
insert into Foo (text) values ("axxx")
insert into Foo (text) values ("áxxx")
insert into Foo (text) values ("xxxa")
insert into Foo (text) values ("xxxá")
insert into Foo (text) values ("xxaxx")
insert into Foo (text) values ("xxáxx")
現在
當我運行此查詢:
select from Foo where text lucene "*a*"
我得到:
xxáxx
xxaxx
xxxa
axxx
與它錯過了
áxxx
xxxá
如果我跑這個:
select from Foo where text lucene "*á*"
我得到:
áxxx
xxxá
而錯過了休息。即使在這種情況下,它應該顯示xxáxx。 我在做什麼錯?