【发布时间】:2012-10-18 21:08:58
【问题描述】:
谁能告诉我 ElasticSearch 上是否有等效的 Solr copyField 指令?
我知道有多字段类型: http://www.elasticsearch.org/guide/reference/mapping/multi-field-type.html 当您想在同一个字段上应用多个分析器时,这很好。
但并不完全相同。 Solr 允许将多个字段“合并”为一个:
<field name="id" type="string" indexed="true" stored="true"/>
<field name="name" type="string" indexed="true" stored="true"/>
<field name="subject" type="string" indexed="true" stored="true"/>
<field name="location" type="string" indexed="true" stored="true"/>
<field name="all" type="text" indexed="true" stored="true" multiValued="true"/>
<copyField source="*" dest="all"/>
这个插件很有前途: https://github.com/yakaz/elasticsearch-analysis-combo
因为它允许在使用 ElasticSearch 多值字段时将结果作为单个字段返回。 但它仍然不完全相同,因为它不允许“合并”多个字段。
我想要组合分析器和 Solr copyField。
我有一个博客文章模型(标题/描述字段),并且想将标题和描述复制到单个字段“blogContent”上,我将在该字段上应用 2 个不同的分析器。
ElasticSearch 有解决方案吗?
【问题讨论】:
标签: elasticsearch search solr lucene elasticsearch-5