Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

hightlight not worked when use script_score #46471

Closed
suxianbaozi opened this issue Sep 7, 2019 · 2 comments · Fixed by #46507
Closed

hightlight not worked when use script_score #46471

suxianbaozi opened this issue Sep 7, 2019 · 2 comments · Fixed by #46507
Labels
>bug :Search Relevance/Highlighting How a query matched a document Team:Search Relevance Meta label for the Search Relevance team in Elasticsearch

Comments

@suxianbaozi
Copy link

suxianbaozi commented Sep 7, 2019

Describe the feature:

Elasticsearch version (bin/elasticsearch --version): 7.3.1

Plugins installed: ["ikAnalyse"]

JVM version (java -version):1.7

OS version (uname -a if on a Unix-like system):centos7

Description of the problem including expected versus actual behavior:

hightlight not worked when use script_score,highlight not found in the response

if i used function_score it works fine

GET company/_search
{
"query": {
"script_score":{
"query": {
"multi_match": {
"query": "有限公司",
"fields": ["companyName^5","historyName^4","companyDesc"],
"minimum_should_match": "4<50%"
}
},
"script":{
"source":"1"
}
}
},
"highlight": {
"fields": {"companyName": {},"companyDesc": {},"historyName":{}}
}
}

@henningandersen henningandersen added :Search Relevance/Highlighting How a query matched a document >bug labels Sep 9, 2019
@elasticmachine
Copy link
Collaborator

Pinging @elastic/es-search

mayya-sharipova added a commit to mayya-sharipova/elasticsearch that referenced this issue Sep 9, 2019
@mayya-sharipova
Copy link
Contributor

mayya-sharipova commented Sep 9, 2019

@suxianbaozi Thank you for filing this issue. Indeed the highlighting was not working in script_score query. This would be fixed in 7.4.1 and 7.5.

@javanna javanna added the Team:Search Relevance Meta label for the Search Relevance team in Elasticsearch label Jul 12, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
>bug :Search Relevance/Highlighting How a query matched a document Team:Search Relevance Meta label for the Search Relevance team in Elasticsearch
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants