Sorting Issue in Typesense Schema
TLDR Keith had issues sorting by the field 'year' after changing its type to a string. Jason clarified that Typesense currently only supports numeric sorting and offered a workaround.
1
Dec 17, 2021 (25 months ago)
Keith
05:01 PMError: 404 - Could not find a field named
year in the schema for sorting.
The field itself is optional, which it was before, does there always have to have a value though to be set inadditionalSearchParameters: {
queryBy: "title,barcode",
sortBy: "_text_match:desc,year:desc",
}
Jason
05:14 PMJason
05:14 PM1
Keith
05:15 PMKeith
05:15 PMJason
05:16 PMJason
05:16 PMKeith
05:19 PMKeith
05:26 PMKeith
05:28 PMKeith
05:32 PMJason
05:34 PMKeith
05:59 PMTypesense
Indexed 3015 threads (79% resolved)
Similar Threads
Resolve Facets and Sorting Issues with Typesense
Ethan needed assistance with getting all facet values and sorting results by date using Typesense. Jason provided guidance on how to use Typesense properties to accomplish these tasks, and resolved issues related to specific use-cases provided by Ethan and Rushil.
Query on Facet Values, `max_facet_values` , and `facet_query_num_typos`.
Jan asked about sorting facet values, managing `max_facet_values` and issues with `facet_query_num_typos`. Jason clarified the details on instantsearch widget handling of `max_facet_values` and identified a bug on the Typesense Server. Jason suggested a solution to the sorting issue.
Sorting Results in Typesense and Handling Errors
Ramees asks about sorting results by distance in Typesense, entering a list of strings as a field, and resolving an error with `fields` format. Kishore Nallan assists with these issues and advises on storing timestamps and proper authentication.
Solving Searchable String ID Sorting Issue
Mubashirullah needed to sort by string id, which was not supported. Kishore Nallan offered a preview Docker build with the feature. Mubashirullah expressed satisfaction with the solution.
Troubleshooting Typesense API Sorting Error in Item Collections
Nikhil encountered a sorting error when using Typesense API due to an optional reference field in the items collection schema. Harpreet and Jason helped debug and identified a bug with sorting in general for 2 fields with the first one being the join field, promising a fix in a forthcoming build.