log.info("Executing " + cmd.toString());
MapReduceOutput mpo = dbColl.mapReduce(baseCommand);
MapreduceResults mrRes = (MapreduceResults) mapr.fromDBObject(MapreduceResults.class, mpo.getRaw(), createCache());
QueryImpl baseQ = null;
if (!MapreduceType.INLINE.equals(type))
baseQ = new QueryImpl(outputType, db.getCollection(mrRes.getOutputCollectionName()), this);
//TODO Handle inline case and create an iterator/able.
mrRes.setBits(type, baseQ);
return mrRes;