Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

copyField chain

Tags:

solr

I tried to use copyField like a chain but it doesn't seems to work. Here my example:

<copyField source="allfields" dest="metafields1" />
<copyField source="metafields1" dest="metafields2" />
<copyField source="metafields2" dest="metafields3" />

Each field uses a different fieldType.

The problem is that except of allfields and metafields1 the other have no content after indexing. Is solr unable to copy from another copyField? I use solr 3.5.

like image 796
Mewel Avatar asked Dec 22 '22 00:12

Mewel


1 Answers

Documentation @ http://wiki.apache.org/solr/SchemaXml#Copy_Fields

The copy is done at the stream source level and no copy feeds into another copy.

Having a copyfield as the source of copyfield tag does not work.
The copyfield source must be an actual field, which has some value and does no cascade.

You can also check http://lucene.472066.n3.nabble.com/does-copyField-recurse-td2450208.html

like image 146
Jayendra Avatar answered Feb 12 '23 22:02

Jayendra