Uploaded image for project: 'Core Server'
  1. Core Server
  2. SERVER-16

dbcursor.count() should update based on limit() and skip()

    XMLWordPrintableJSON

Details

    • Icon: New Feature New Feature
    • Resolution: Won't Fix
    • Icon: Minor - P4 Minor - P4
    • None
    • None
    • Shell
    • None

    Description

      After retrieving a cursor from a query, calling count() on it always returns the total number of matching records, even after calling limit() or skip() on it. It would be nice if count() was updated to reflect the number of matching records after any cursor manipulation with limit() and skip().

      This would ideally be a universal change for the various drivers as well to maintain consistent behavior, but I did not create issues specifically for each of them. Perhaps if this is accepted, that kind of change could be considered.

      Attachments

        Activity

          People

            eliot Eliot Horowitz (Inactive)
            liamstask Liam Staskawicz
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: