Skip to content

MultiField sorting problem #3092

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

Closed
markosrial opened this issue Apr 21, 2025 · 0 comments
Closed

MultiField sorting problem #3092

markosrial opened this issue Apr 21, 2025 · 0 comments
Labels
status: waiting-for-triage An issue we've not yet triaged

Comments

@markosrial
Copy link

markosrial commented Apr 21, 2025

Having the next mapping property in my index:

"title": {
  "type": "text",
  "fields": {
    "autocomplete": {
      "type": "completion"
    },
    "keyword": {
      "type": "keyword"
    }
  }
},

When a Sort like Sort.by(Sort.Direction.ASC, "title.keyword"), is added for the Pageable item, the MappingElasticsearchConverter class removes the .keyword because of the logic in methods updatePropertiesInFieldsSortAndSourceFilter > updateFieldNames. Seems it treats all the properties comming after the dot, as nested fields, while this case may represent a MultiField sorting.

Working with spring-data-elasticsearch version 5.4.4

@spring-projects-issues spring-projects-issues added the status: waiting-for-triage An issue we've not yet triaged label Apr 21, 2025
@sothawo sothawo closed this as completed Apr 21, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
status: waiting-for-triage An issue we've not yet triaged
Projects
None yet
Development

No branches or pull requests

3 participants