Details
-
Bug
-
Resolution: Done
-
Major - P3
-
None
-
None
-
None
-
None
Description
The attached Program.cs fails with the message:
Message=Command 'mapreduce' failed: db assertion failure (response: { "assertion" : "could not create cursor over test.test for query : { B:
{ $exists: true }} sort :
{ B: 1 }", "assertionCode" : 15876, "errmsg" : "db assertion failure", "ok" : 0.0 })
The code is based on the official test TestMapReduceInlineWithQuery. Perhaps
the problem can be seen just there if the line
var result = _collection.MapReduce(query, map, reduce);
is replaced with
var options = new MapReduceOptionsBuilder();
options.SetQuery(query);
options.SetOutput(MapReduceOutput.Inline);
options.SetSortOrder((new SortByBuilder()).Ascending("B"));
var result = _collection.MapReduce(map, reduce, options);
If I remove the line with SetSortOrder then the code works fine.
Sorry if I just do something wrong and this is a false alarm. I asked the
question at the forum but did not get the answer.
Attachments
Issue Links
- related to
-
SERVER-2269 Map/reduce with sorting fail
-
- Closed
-