Uploaded image for project: 'C# Driver'
  1. C# Driver
  2. CSHARP-1441

Support transparent identifiers in SelectMany

    XMLWordPrintableJSON

Details

    • Icon: Improvement Improvement
    • Resolution: Unresolved
    • Icon: Major - P3 Major - P3
    • None
    • None
    • Linq
    • None

    Description

      The following test in MongoQueryableTests fails because SelectMany does not handle transparent identifiers well.

         [Test]
              public void SelectMany_with_collection_selector_with_a_transparent_identifier()
              {
                  var query = from x in CreateQuery()
                              from y in x.G
                              orderby x.Id
                              select new { x.B, y };
       
                  Assert(query,
                      4,
                      "{ $unwind: '$G' }",
                      "{ $project: { G: '$G', _id: 0 } }");
              }
      

      Attachments

        Activity

          People

            Unassigned Unassigned
            craig.wilson@mongodb.com Craig Wilson
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated: