-
Notifications
You must be signed in to change notification settings - Fork 20
Open
Description
Consider the following query:
{
$expr: {
$lt:[ {
$cond: {
if: { $gte: ["$qty", 100] },
then: { $divide: ["$price", 2] },
else: { $divide: ["$price", 4] }
}
},
5 ]
}
}The expected result would contain fields for price and qty. Instead the results for for a field named $expr:
RESULT {
"parts": [
{
"field": "$expr",
"operator": "$lt",
"operand": [
{
"$cond": {
"if": {
"$gte": [
"$qty",
100
]
},
"then": {
"$divide": [
"$price",
2
]
},
"else": {
"$divide": [
"$price",
4
]
}
}
},
5
],
"parts": []
}
]
}Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels