-
Type:
Bug
-
Resolution: Gone away
-
Priority:
Unknown
-
None
-
Affects Version/s: None
-
Component/s: None
-
None
-
None
-
None
-
None
-
None
-
None
-
None
-
None
Summary
$dateDiff is failing with "Invalid $project :: caused by :: Unknown expression $dateDiff."
Mongo Version
V2.13
Mongo2Go Version
V3.1.3
How to Reproduce
Code use below works in practise but not when testing.
{"duration", new BsonDocument
{
{ "$dateDiff", new BsonDocument
{
{"startDate", $"${nameof(State.Updated)}"},
{"endDate", DateTime.Now},
{"unit", "day"}
}
}
}
}