我想用 Solr 做一个完全匹配的查询。我已经有一个 solr.textField 类型来进行模糊和词干搜索,但我需要能够进行完全匹配(或“包含”匹配)查询,就像这样
document_1.text_exact: "The fox was jumping on the goose"
document_2.text_exact: "The fox is jumping on the goose"
document_3.text_exact: "The fox is jumping at the goose"
我想做这样的查询:
text_exact:"The fox is jumping"
我想要 solr document_2 和 document_3 但不是 document_1。在 Firefox 中查找文本时也可以这样做(你知道,使用 Ctrl-F)。
我应该如何定义“text_exact”字段以完成此操作?
谢谢