Archive for November 2015

Using the $lookup operator in MongoDB 3.2

Warning: count(): Parameter must be an array or an object that implements Countable in /home/fbsqlcom/public_html/ on line 31

I often loiter over on the MongoDB User Google Group and there was an interesting question posted the other day. The poster wanted to form a document like this from two collections (where foo is a document from another collection)… ?View Code JAVASCRIPT{ "_id" : ObjectId("ObjectId of this bar"), "name" : "Bar Name", "foo" : […]