title: MongoDB date index
body: <p>I am using node.js and mongodb for my small application and I want to index my document by date object. For Example </p>
  
  <pre><code>var MySchema = new Schema({
      created_at: { type: Date, default: Date.now }
  });
  
  myschema.index({created_at: -1});
  </code></pre>
  
  <p>But how I understand, each object will have nearly unique create_id field. Wouldit work well ? and would this method give me effect. If you can, please also send me any articles about mongodb date indexing.</p>