Guest User

Untitled

a guest
Nov 22nd, 2017
104
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.38 KB | None | 0 0
  1. db.collection("files").find().limit(3).toArray(function(err, result) {
  2. if (err) throw err;
  3. result.forEach(function(element) {
  4. db.collection("files").deleteOne(element, function(err, obj) {
  5. if (err) throw err;
  6. db.collection("procesing").insertOne(element, function(err, res) {
  7. if (err) throw err;
  8. });
  9. });
  10. });
  11. });
Add Comment
Please, Sign In to add comment