I'm trying to find the empty-array subdocument records from a collection,
In Mongo Shell, below query returns 3 records,
db.test.find({"campaigns.postcode":{"$gt":{}}}).count();
same in PHP returns all the records from test collection,
$mongo->$dbname->$colname->count(array('campaigns.postcode'=>array('$gt'=>array())));
Please anyone can help me !!!