-
Type:
Bug
-
Resolution: Unresolved
-
Priority:
Major - P3
-
None
-
Affects Version/s: None
-
Component/s: Querying
-
Environment:Ubuntu 16.04.6 with MongoDB 4.0.9
MongoDB Atlas with MongoDB 4.0.10
-
Query Execution
-
ALL
-
-
QE 2026-01-19, QE 2025-12-08, QE 2026-03-02, QE 2026-02-02, QE 2026-02-16
-
None
-
None
-
None
-
None
-
None
-
None
-
None
If you have in your collection a document:
{
_id: ...,
prices : [ {
max : 250,
min : 200
} ]
}
You can successfully query it by using the following filters:
1)
{'prices.0.min' : 200 }
2)
{'prices.0.min' : { $exists : true } }
3)
{ 'prices.0.min' : { $gt : 100 } }
4)
{ 'prices.0.min' : { $exists : true, $ne : 123 } }
BUT you CANNOT do it using the below filters:
1)
{ 'prices.0.min' : { $exists : true, $ne : null } }
2)
{ 'prices.0.min' : { $ne : null } }
The problem noted is with only `$ne : null` in filter.
- is related to
-
SERVER-36681 Dotted path {$ne: null} against array of scalars returns incorrect results
-
- In Progress
-
-
SERVER-27442 Positional path component in match language should not act as both an array index and a field name for a single document
-
- Backlog
-