[JAVA-489] Add DBCursor.count(boolean foundOnly) Created: 14/Dec/11 Updated: 19/Oct/16 Resolved: 19/Oct/16 |
|
| Status: | Closed |
| Project: | Java Driver |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Improvement | Priority: | Major - P3 |
| Reporter: | Uladzimir Mihura | Assignee: | Brendan W. McAdams |
| Resolution: | Done | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Description |
|
At this moment it's impossible to get the number of results with skip and limit applied: At the same time PHP and Python have this ability. |
| Comments |
| Comment by Uladzimir Mihura [ 16/Dec/11 ] |
|
Thank you Brendan. Looks strange that for different drivers we have different method names. -vova |
| Comment by Brendan W. McAdams [ 14/Dec/11 ] |
|
Count returns the total results of the cursor without skip/limit. Calling size() instead will account for skip/limit as documented in the same Javadoc page. |