Find().limit(-100) should fail if less than 100 docs returned (100 docs > 4MB)

XMLWordPrintableJSON

    • Type: Bug
    • Resolution: Done
    • Priority: Major - P3
    • None
    • Affects Version/s: 2.0
    • Component/s: None
    • None
    • None
    • None
    • None
    • None
    • None
    • None
    • None

      If you set a negative limit and the number returned is less than requested an exception should be thrown.

      if (coll.find().limit(-100).getSizes()[0] != 100) //fail

      This should be an error since it is misleading and could break code that thinks it will get back that number; instead it will seem like there are less result than there actually are.

            Assignee:
            Eliot Horowitz (Inactive)
            Reporter:
            Scott Hernandez (Inactive)
            None
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved: