Subject: | count and sort_by conflict ? |
Hello, i discovered weird bug when using mongo driver.
For example i 5 sales and doing simple query:
$cursor = $db->sales->query({}, { limit => 10, skip => 0 });
$cursor->count() # returns 5
and its fine, but then i need them sorted, so i changed query and added
"sort_by":
$cursor = $db->sales->query({}, { limit => 10, skip => 0, sort_by => {
created => 1 } });
$cursor->count() # returns 0 !
i think this is not fully correct, because it should return 5 in my
opinion. I tried it with stable 1.6.5 and development 1.8rc2 versions of
mongodb.