title: I can not get mongoose/node.js to retrieve data properly. What am I doing wrong?
body: <p>I am trying to get node.js to write to the console the data in the table, my other tables work.</p>
  
  <p>Whenever I try I get the following output:</p>
  
  <pre><code>NO ERROR!
  QUERY:{"emitted":{"complete":[[]]},"_events":{}}
  </code></pre>
  
  <p>Am I missing something in the Schema definition?
  Any help would be appreciated.<br>
  - Eric</p>
  
  <p><br><br></p>
  
  <p>The following is from the mongo shell :</p>
  
  <pre><code>&gt; db.userAssessments.find({})
  { "accountId" : "509683edcb884b0000000001", "created" : ISODate("2013-01-12T03:31:20.723Z"), "_id" : ObjectId("50f0d9084469766bb7000001") }
  </code></pre>
  
  <p>This is my js:</p>
  
  <pre><code>var userAssessmentsSchema = new mongoose.Schema({
      accountId : String,
      created : Date,
      id: String
  });
  
  ANALYZER.userAssessments = mongoose.model('userAssessments', userAssessmentsSchema);
  ANALYZER.analyzeAssessment = function() {
      var query = ANALYZER.userAssessments.find({}).exec(function(err, ass) {
          if (!err) {
              console.log("NO ERROR!");
              console.log("QUERY:" + JSON.stringify(query));
          } else {
              console.log("ERROR!");
          }
      });
  };
  </code></pre>