Mongo-ize some queries.