-
Notifications
You must be signed in to change notification settings - Fork 63
Open
Description
Is it possible to support using distinct and withSearchIndex together?
Something like:
return stream(ctx.db, schema)
.query('addresses')
.withSearchIndex(`by_state`, (si) => si.search('state', 'N'))
.order('asc')
.distinct(['state'])
.paginate(args.paginationOpts);The idea is that if addresses contains 1000s of address with state NY and 1000s with NJ, searching for N does not always return all addresses with states beginning with N because it may exhaust the initialNumItems in the usePaginatedQuery before it reaches unique values.
Relevant source:
| withSearchIndex(_indexName: any, _searchFilter: any): any { |
Metadata
Metadata
Assignees
Labels
No labels