title: How to backup a mongodb collection using express.js and Node.js
body: <p>I want to take a backup of my <code>userdatas</code> collection every month.</p>
  
  <p>Backup means:  </p>
  
  <p>I need to take <code>userdatas</code> data and store it in some <code>backupuserdatas</code> collection. Every 1 month a batch program should run automatically and should store that month of data(documents) in the <code>backupuserdatas</code> collection.</p>
  
  <p>I have used node-cron for running batch programs but I don't know to write a query for backing up my <code>userdatas</code> collection every month.</p>
  
  <p>How can I do this in Node.js, express.js and mongodb?</p>