I use 'mongo', '1.6.2' and 'mongoid', '2.4.11' . I have a ProPlayer model when I start the console.
irb(main):006:0> ProPlayer.first => #<ProPlayer _id: 508a5549d3966f02e7000001, _type: nil, created_at: nil, updated_at: nil, first_name: "Adam", last_name: "Jones", batting_style: "R", image_thumbnail: "1.jpg", is_pro_player: true, team_id: BSON::ObjectId('508a550ad3966f02ce000012'), token_id: nil>
Here the record with is_pro_player as true is present, but when I run the query, it returns me zero records, but in fact there are 71 records.
irb(main):008:0> ProPlayer.where(:is_pro_player=>true).to_a.size => 0
This request worked before, but suddenly did not work. Can someone tell me what could be the problem?
source share