假设一个具有名称的多值、存储和索引字段comment
。
执行搜索时,我只想返回以下值comment
其中包含匹配项。例如:
当搜索“gold”而不是得到这个结果时:
<doc>
<arr name="comment">
<str>Theres a lady whos sure</str>
<str>all that glitters is gold</str>
<str>and shes buying a stairway to heaven</str>
</arr>
</doc>
我更愿意得到这样的结果:
<doc>
<arr name="comment">
<str>all that glitters is gold</str>
</arr>
</doc>
(记忆中的伪 XML,可能不准确,但说明了这一点)
Thanks.
考虑到与其他 Solr 用户的对话让我相信这是一个有用的功能,我已经提交了一个功能请求:
Solr:仅返回匹配的多值字段
本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)