title: Aggregation Match Mongodb with dateFromString
body: <p>Dear attempts to filter by date in mongo but I have not succeeded. I pass my query and structure of JSON.</p>
  
  <pre><code>db.getCollection('articles').aggregate([
  { "$match": {
   "$expr": {
    "$and": [
      {
        "$gte": [
          { "$dateFromString": { "creationDate": "10-08-2018", "format": "%m-%d-%Y" }}
        ]
      },
      {
        "$lte": [
          { "$dateFromString": { "creationDate": "10-08-2018", "format": "%m-%d-%Y" }}
        ]
      }
    ]
  }
  }}
  ])
  </code></pre>
  
  <p>My JSON is </p>
  
  <pre><code>{
  "_id" : ObjectId("5bbb6b1de75b933850a608fc"),
  "title" : "05",
  "body" : "asgfasgasfa",
  "creationDate" : ISODate("2018-10-08T14:35:07.000Z"),
  "operationType" : "C",
  "__v" : 0
  }
  </code></pre>
  
  <p>MongoDB : v3.6.3</p>