Uploaded image for project: 'Mongoid'
  1. Mongoid
  2. MONGOID-2487

Bug in mongoid 3.0.9

    • Type: Icon: Task Task
    • Resolution: Done
    • 3.0.10
    • Affects Version/s: None
    • Component/s: None
    • None

      Query:

      result = Pages.only(:id, :subject, :sub_subject, :picture, :valid_from)
      .where(kats: params['category_id'])
      .order_by('valid_from desc')
      .skip(@skip)
      .limit(15)
      .cache

      result.size returns count of all records in a collection not just size of result. Which should be 15.

      I reverted back to mongoid 3.0.5 where everything works as expected.

      Rails 3.2.8, Ruby 1.9.3., MongoDB 2.2.0

      by
      TheR

            Assignee:
            Unassigned Unassigned
            Reporter:
            TheR2 TheR2 [X]
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved: