title: How do I use new Meteor.Collection.ObjectID() in my mongo queries with meteor?
body: <p>I have a Collection that has documents with an array of nested objects. 
  Here is fixture code to populate the database:</p>
  
  <pre><code>if (Parents.find().count() == 0) {
      var parentId = Parents.insert({
          name: "Parent One"
      });
      Children.insert({
          parent: parentId,
          fields: [
              {
                  _id: new Meteor.Collection.ObjectID(),
                  position: 3,
                  name: "three"
              },
              {
                  _id: new Meteor.Collection.ObjectID(),
                  position: 1,
                  name: "one"
              },
              {
                  _id: new Meteor.Collection.ObjectID(),
                  position: 2,
                  name: "two"
              },
  
          ]
      });
  }
  </code></pre>
  
  <p>You might be asking yourself, why do I even need an ObjectID when I can just update based off of the names. This is a simplified example to a much more complex schema that I'm currently working on and the the nested object are going to be created dynamically, the ObjectID's are definitely going to be necessary to make this work. </p>
  
  <p>Basically, I need a way to save those nested objects with a unique ID and be able to update the fields by their _id.</p>
  
  <p>Here is my Method, and the call I'm making from the browser console: </p>
  
  <pre><code>Meteor.methods({
    upChild: function( options ) {
          console.log(new Meteor.Collection.ObjectID());
          Children.update({_id: options._id, "fields._id": options.fieldId }, {$set: {"fields.$.position": options.position}}, function(error){
              if(error) {
                  console.log(error);
              } else {
                  console.log("success");
              }
          });
      }
  });
  </code></pre>
  
  <p>My call from the console:</p>
  
  <pre><code>Meteor.call('upChild', {
    _id: "5NuiSNQdNcZwau92M",
    fieldId: "9b93aa1ef3868d762b84d2f2",
    position: 1
  });
  </code></pre>
  
  <p>And here is a screenshot of the html where I'm rendering all of the data for the Parents and Children collections:
  <img src="https://i.stack.imgur.com/50Myy.png" alt="enter image description here"></p>