Confirmation regarding filtering on paginated queries
Just wanted to confirm how filtering works in a very specific scenario.
When 1. not using an index and 2. using a paginated query, will applying a filter on this query perform a full table scan or just on the current page?
3 Replies
In other words, will the following
.filter
perform a full table scan or scan through the initialNumItems
setting in the paginationOpts
It will scan the table until it finds
initialNumItems
that satisfy the filter. If most people have name!=Alex, it will read approximately initialNumItems
. If most people are named Alex, it may scan the entire table. (edited because i missed the q.neq)Ah i see, thank you Lee!