[DocumentDB] Allow Paging (skip/take)
Allowing paging would be huge. Btw, Thank You for rolling out this feature at all! It looks wonderful! Can't wait to try it! However, I won't be able to use it for actual work projects until it supports paging and sorting.
This feature is now complete. For more information on Skip/Take (Limit/Offset), please see the article below.
Thank you for your suggestions and votes.
This would be super helpful when driving a UI straight from DocumentDB. The primary rule of scaling any UI to handle millions of records is to implement paging everywhere. Please don't implement it with continuation tokens the way Azure Table Storage did. That's very hard to consume in a UI. You have to store the previous token in a session (which is not scalable) so the user can navigate backwards. Plus, there's no way to tell the user how many pages there are total.
An implementation more akin to SQL's skip/take/limit would be much more usable. Also, pagination is not very useful unless it can also be ordered by some criteria. Therefore, please remember to include an "order by" clause that can be used in conjunction with the skip/take/limit clause.
This is needed for paging scenarios. This would be much more powerful if we had "order by" and "skip" commands to use in conjunction with a "limit" command.
I want this feature as well
Luis Delgado commented
implement the capability to limit the results that come back from the Azure DocumentDB collection, for example, 'LIMIT 1000' will return only the first 1000 rows the meet the query filter.