【问题标题】:Remove duplicates without considering position删除重复而不考虑位置
【发布时间】:2012-12-10 14:57:16
【问题描述】:

有没有过滤器工厂可以用来去除重复而不考虑位置?

我不能使用 RemoveDuplicatesTokenFilterFactory,因为它考虑了 position [stack]

【问题讨论】:

标签: search solr indexing


【解决方案1】:

我有一个类似的问题,在我希望它们是唯一的字段中有很多重复值。解决方案是将处理器添加到 solrconfig.xml 文件中。下面是示例。列出的字段的每个值都是唯一的。我的字段名称是 ingredient_substance, active_moiety ...

<updateRequestProcessorChain>
    <processor class="org.apache.solr.update.processor.UniqFieldsUpdateProcessorFactory">
        <lst name="fields">
            <str>ingredient_substance</str>
            <str>active_moiety</str>
            <str>generic_medicine</str>
            <str>inactive_ingredient_substance</str>
        </lst>
    </processor>
    <processor class="solr.RunUpdateProcessorFactory"/>
</updateRequestProcessorChain>

【讨论】:

    猜你喜欢
    • 2012-02-20
    • 1970-01-01
    • 2021-11-08
    • 2021-04-13
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多