我有一个包含数据的集合:
{
"_id" : ObjectId("51dfb7abe4b02f15ee93a7c7"),
"date_created" : "2013-7-12 13:25:5",
"referrer_id" : 13,
"role_name" : "Physician",
"status_id" : "1",
}
我正在发送查询:
cmd {
"mapreduce" : "doctor" ,
"map" : "function map(){emit(this._id,this);}" ,
"reduce" : "function reduce(key,values){return values;}" ,
"verbose" : true ,
"out" : { "merge" : "map_reduce"} ,
"query" : { "$where" : "this.demographics.first_name=='makdoctest'"}
}
我收到错误消息:
"errmsg" : "exception: count failed in DBDirectClient: 10071 error on invocation of $where function:\nJS Error: TypeError: this.demographics has no properties nofile_a:0"