Uploaded image for project: 'Core Server'
  1. Core Server
  2. SERVER-15727

two-dimension Array $elemMatch bug

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major - P3
    • Resolution: Duplicate
    • Affects Version/s: 2.6.5
    • Fix Version/s: None
    • Component/s: Querying
    • Labels:
      None
    • Operating System:
      ALL
    • Steps To Reproduce:
      Hide

      db.foo.insert({x:[{a:[[1,2]], b:[[3,4]]}], y:[{a:[[5,6]], b:[[7,8]]}]})
      db.foo.find({x:{$elemMatch:{a:{$elemMatch:{$in:[2]}}}}})

      Show
      db.foo.insert({x:[{a:[[1,2]], b:[[3,4]]}], y:[{a:[[5,6]], b:[[7,8]]}]}) db.foo.find({x:{$elemMatch:{a:{$elemMatch:{$in:[2]}}}}})

      Description

      like this query

        
      {
      	"fieldsValue" : {
      		  "$elemMatch" : {
       			"namePath" : {
      				"$elemMatch" : {
      					"$in" : ["some word"]
      				}
      			}
      		}
      	}
      }

      at 2.4.8 version can work ok,at 2.6.5 find nothing,not test other version

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              david.storch David Storch
              Reporter:
              rendong rendong
              Participants:
              Votes:
              0 Vote for this issue
              Watchers:
              6 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved: