admin管理员组文章数量:1355542
Question: I am working on a search functionality using Lucene.NET with the StandardAnalyzer, and I noticed an issue with wildcard queries not matching expected results.
Issue: My indexed field contains values like: 24-PC-QMR-NB-3
Since StandardAnalyzer tokenizes the text by splitting on hyphens (-), the stored tokens become:
["24", "pc", "qmr", "nb", "3"] When I run a normal search query like 24-PC-QMR-NB-3, Lucene correctly finds the document.
However, when using a wildcard query like 24-PC-QMR-NB-3*, it does not return any results.
Question: Why does StandardAnalyzer prevent wildcard queries from matching tokenized fields?
How can I modify my indexing or querying approach to allow wildcard searches on fields containing spaces or special characters?
本文标签:
版权声明:本文标题:c# - Lucene.NET StandardAnalyzer Not Matching Tokens for Wildcard Queries - Stack Overflow 内容由网友自发贡献,该文观点仅代表作者本人, 转载请联系作者并注明出处:http://www.betaflare.com/web/1743960756a2568979.html, 本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌抄袭侵权/违法违规的内容,一经查实,本站将立刻删除。
发表评论