summaryrefslogtreecommitdiff
path: root/shell/query.js
diff options
context:
space:
mode:
authorAaron <aaron@10gen.com>2009-02-06 17:16:28 -0500
committerAaron <aaron@10gen.com>2009-02-06 17:16:28 -0500
commit3504f3249c62d205d66aab2f714d1bc06b4a0934 (patch)
treef03c123b52190eba10ca39404696380e3d806a12 /shell/query.js
parent3ecc0eb11416613e353635c209dc565c0d47e629 (diff)
downloadmongo-3504f3249c62d205d66aab2f714d1bc06b4a0934.tar.gz
dbshell support for field spec with count
Diffstat (limited to 'shell/query.js')
-rw-r--r--shell/query.js1
1 files changed, 1 insertions, 0 deletions
diff --git a/shell/query.js b/shell/query.js
index 36e53ca5dd4..ddf35f6aea5 100644
--- a/shell/query.js
+++ b/shell/query.js
@@ -105,6 +105,7 @@ DBQuery.prototype.count = function(){
else
cmd.query = this._query;
}
+ cmd.fields = this._fields || {};
var res = this._db.runCommand( cmd );
if( res && res.n != null ) return res.n;