Expanded the retrieval to page through all results of the queries.