Linq Driver Performing pipeline instead of find on query

XMLWordPrintableJSON

    • Type: Bug
    • Resolution: Works as Designed
    • Priority: Major - P3
    • None
    • Affects Version/s: 2.10.3
    • Component/s: None
    • None
    • None
    • None
    • None
    • None
    • None
    • None
    • None

      Reporting this as a bug BUT i would have expected the linq query to generate the same qeury under the covers as the find query.  Instead the linq query is generating an aggregation pipeline.

       

      ```

            var document = GetCollection<MediaDocument>()

                      .Find(x => x.ImageUniqueIdentifier == imageUniqueIdentifier)

                      .FirstOrDefault();

      ```

       

      ```

                  var document = GetCollection<MediaDocument>()

                      .AsQueryable()

                      .Where(x => x.ImageUniqueIdentifier == imageUniqueIdentifier)

                      .FirstOrDefault();

      ```

            Assignee:
            Unassigned
            Reporter:
            Michael Fyffe
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: