ようこそTokuMXオブジェクト[オブジェクトのオブジェクト]は方法はありません「のhasNext」
私はこれを実行した後、私はモンゴ3.0
mongo ${DB_HOST_PORT}/${DATE} ${BASE_PATH}/temp/script.js > "${BASE_PATH}/temp/listofcampaigns.csv" --quiet
var cursor=db.getCollection('combined_data').aggregate([{"$match":{"src":"sender","customer":"test","name":"ntf_NotificationSent","time":{"$gte":"2016-11-23T00:00:00.000Z","$lt":"2016-11-23T01:00:00.000Z"}}},
{"$group":{"_id":{"campaign":"$spec:crm:cmp:campaign:id"},"count":{"$sum":1}}},{"$sort":{"count":-1}}]);
if (cursor && cursor.hasNext()) { print('campaign, count');
while (cursor.hasNext()) { var item = cursor.next(); print('' + item._id.campaign + ', ' + item.count); }}
を持つマシン上で集約をしていたそして、それは問題なく動作しましたが、 TokuMXを持つマシンがインストールされ、私はONYエラーを持っている:
Wed Nov 23 14:13:06.443 TypeError: Object [object Object] has no method 'hasNext' at (...)/temp/script.js failed to load: (...)/temp/script.js
誰かがこれで私を助けることができますか? あるいは、誰かが、この種の集約をTokuMXでマシン上で実行する方法の例を試していますか?
結果ファイルは次のようになります。
campaign, count
xyz, 5
yxz, 6