manticoresoftware / manticoresoftware/manticoresearch-php
Return distance when sorting by _geo_distance
Nobody has claimed this yet.
- Dominant language
- PHP
- Stars
- 211
- Forks
- 39
- Avg merge
- 1d 20h
- Merged PRs (30d)
- 1
Description
would be awesome if we could include the distance value with the search result.
I know this can be done with SQL but would be great if we could add it to the result.
Similar to how we add score with $search->trackScores(true)
Something like $search->trackDistance(true) ? maybe
Will possibly add it locally, if it works would you like a PR?
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by tracing how the PHP client builds search requests and maps search results, then compare that path with the existing trackScores(true) behavior. Determine how _geo_distance sorting is represented in the response; done means callers can request and receive the distance value alongside each search result, with the behavior covered by the relevant client tests.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- php
- Domain
- api
- Issue type
- Feature
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Active
- Clarity
- Mostly clear
- Newbie friendliness
- 52/100