随笔分类 -  mongo

摘要:for (var i = 1; i <= 30; i++) {db.wechatAttention.save({_class:"la.xiaoxiao.manager.wechat.entity.WechatAttentionEntity",ghId:"gh_"+ObjectId().valueO... 阅读全文
posted @ 2015-12-19 17:48 wind90 阅读(275) 评论(0) 推荐(0)
摘要:db.getMongo().setSlaveOk() 阅读全文
posted @ 2015-11-05 15:49 wind90 阅读(855) 评论(0) 推荐(0)
摘要:TypedAggregation aggregation = newAggregation(DemoEntity.class, match(match), group("name").count().as("total"), sort(Sort.Direction.AS... 阅读全文
posted @ 2015-11-05 15:30 wind90 阅读(353) 评论(0) 推荐(0)
摘要:DBCollection coll = mongo.getCollection(OrgHeatEntity.class.getAnnotation(Document.class).collection()); DBObject query = new BasicDBObject(); query... 阅读全文
posted @ 2015-11-03 17:07 wind90 阅读(667) 评论(0) 推荐(0)