[
https://issues.apache.org/jira/browse/SOLR-4128?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Aaron Daubman updated SOLR-4128:
--------------------------------
Description:
With a schema that includes a dynamic field that matches 'score' (e.g. s* or
even just *) text response writers (json, python, etc...) will return score as
an array, e.g.:
"score": [
17.522964
]
For now, a workaround (courtesy of hoss) is adding a non-indexed, non-stored,
non-multivalued 'score' field to schema.xml, e.g.:
<field name="score" type="string" indexed="false" stored="false"
multiValued="false"/>
Note that this will happen for anybody following the current (or older) example
schema.xml where "*" was used to ignore undesired fields (from: SOLR-217):
https://github.com/apache/lucene-solr/blob/trunk/solr/example/solr/collection1/conf/schema.xml#L214
was:
With a schema that includes a dynamic field that matches 'score' (e.g. s* or
even just *) text response writers (json, python, etc...) will return score as
an array, e.g.:
"score": [
17.522964
]
For now, a workaround (courtesy of hoss) is adding a non-indexed, non-stored,
non-multivalued 'score' field to schema.xml, e.g.:
<field name="score" type="string" indexed="false" stored="false"
multiValued="false"/>
Note that this will happen for anybody following the older default schema.xml
where "*" was used to ignore undesired fields (e.g. as mentioned in
https://issues.apache.org/jira/browse/SOLR-217?focusedCommentId=12492357&page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#comment-12492357
)
> multivalued dynamicField matching 'score' causes text response writers to
> output score as an array
> --------------------------------------------------------------------------------------------------
>
> Key: SOLR-4128
> URL: https://issues.apache.org/jira/browse/SOLR-4128
> Project: Solr
> Issue Type: Bug
> Components: Response Writers
> Affects Versions: 4.0
> Environment: all
> Reporter: Aaron Daubman
> Priority: Minor
> Labels: array, ignore, schema, score
>
> With a schema that includes a dynamic field that matches 'score' (e.g. s* or
> even just *) text response writers (json, python, etc...) will return score
> as an array, e.g.:
> "score": [
> 17.522964
> ]
> For now, a workaround (courtesy of hoss) is adding a non-indexed, non-stored,
> non-multivalued 'score' field to schema.xml, e.g.:
> <field name="score" type="string" indexed="false" stored="false"
> multiValued="false"/>
> Note that this will happen for anybody following the current (or older)
> example schema.xml where "*" was used to ignore undesired fields (from:
> SOLR-217):
> https://github.com/apache/lucene-solr/blob/trunk/solr/example/solr/collection1/conf/schema.xml#L214
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]