title: MongoDB : OrderBy a specific field in an array
body: <p>I have document structure like that :</p>
  
  <pre><code>{
    "_id": ObjectId("4ed3733abde68a21780000a0"),
    [HERE OTHER DATA...]
    "myArray": [
      {
        "name": "myName1",
        "value": 4
      },
      {
        "name": "myName2",
        "value": "myValue"
      },
      {
        "name": "myName3",
        "value": 14.6
      }
    ]
  }
  </code></pre>
  
  <p>I want to do a query documents ordered by a specific field in the array "myArray".</p>
  
  <p>Example : I want to query documents ordered by myArray[name="myName1"].value</p>
  
  <p>If myArray[name="myName1"] doesn't exist, it must be at the end of the result list.</p>
  
  <p>If myArray[name="myName1"] exist two times in the document, maybe take the first.</p>
  
  <p>Is it possible ?</p>