consider sort order during result collection with pagination