[SERVER-2188] Check count code path when using $min and $max Created: 07/Dec/10 Updated: 19/May/14 Resolved: 20/Dec/10 |
|
| Status: | Closed |
| Project: | Core Server |
| Component/s: | None |
| Affects Version/s: | 1.7.3 |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Minor - P4 |
| Reporter: | Alberto Lerner | Assignee: | Alberto Lerner |
| Resolution: | Won't Fix | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Operating System: | ALL |
| Participants: |
| Description |
|
s = "" for ( i=0; i<10000; i++ ){ db.foo2.insert( { s : s , a : z() , b : z()}); } shard on a,b and make a couple of split points db.bar.find( { $min: { a: 0, b: 0}, $max: { a:1000, b:1000}, $query: {} } ).itcount() gives the correct count, but db.bar.find( { $min: { a: 0, b: 0}, $max: { a:1000, b:1000}, $query: {} } ).count() doesn't |
| Comments |
| Comment by Alberto Lerner [ 20/Dec/10 ] |
|
The usage of $min / $max is not supported yet. To get the functionality, we use the shell version of these functions: http://www.mongodb.org/display/DOCS/min+and+max+Query+Specifiers |