You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@lucene.apache.org by "David Smiley (Jira)" <ji...@apache.org> on 2021/01/29 20:13:00 UTC

[jira] [Resolved] (SOLR-12663) Highlighting is not working with docValues only String field

     [ https://issues.apache.org/jira/browse/SOLR-12663?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

David Smiley resolved SOLR-12663.
---------------------------------
    Fix Version/s: 8.5
       Resolution: Fixed

Implemented via SOLR-14194 in 8.5 for the original highlighter (though not the Unified one).

> Highlighting is not working with docValues only String field
> ------------------------------------------------------------
>
>                 Key: SOLR-12663
>                 URL: https://issues.apache.org/jira/browse/SOLR-12663
>             Project: Solr
>          Issue Type: Bug
>          Components: highlighter
>    Affects Versions: 7.2.1
>            Reporter: Karthik Ramachandran
>            Priority: Major
>             Fix For: 8.5
>
>
> Highlighting is not working with docValues only String field.  Need to check SortableTextField as mentioned by [~erickerickson]
> Schema:
>  <schema name="core" version="1.6">
>    <uniqueKey>id</uniqueKey>
>    <fieldType name="string" class="solr.StrField" sortMissingLast="true"/>
>    <field name="id" type="string" docValues="true" indexed="true" required="true"/>
>    <field name="name" type="string" docValues="false" indexed="true" stored="true"/>
>    <field name="name1" type="string" docValues="true" indexed="true" stored="false"/>
>    <copyField source="name" dest="name1"/>
>  </schema>
> Data:
>  [\\{"id":1,"name":"Testing line 1"},\\{"id":2,"name":"Testing line 2"},\\{"id":3,"name":"Testing line 3"}]
> Query:
>  [http://localhost:8983/solr/test/select?q=Testing*&df=name&hl=true&hl.fl=name,name1]
> Response:
>  {"response":{"numFound":3,"start":0,"docs":[
> {"id":"1","name":"Testing line 1","name1":"Testing line 1"}
> ,\{"id":"2","name":"Testing line 2","name1":"Testing line 2"},\{"id":"3","name":"Testing line 3","name1":"Testing line 3"}]},"highlighting":{"1":
> {"name":["<em>Testing line 1</em>"]}
> ,"2":{"name":["<em>Testing line 2</em>"]},"3":{"name":["<em>Testing line 3</em>"]}}}



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@lucene.apache.org
For additional commands, e-mail: issues-help@lucene.apache.org