Do we have any alternative solution to search with the Decimal128 field in Mongo DB Atlas search?
I tried to create an Atlas index with Number but it seems they support only int32, int64 and double. Decimal 128 doesn't work with this index.
{
"mappings": {
"dynamic": false,
"fields": {
"totalAmountTaxIncluded": {
"fields": {
"value": {
"type": "number"
}
},
"type": "document"
}
}
}
}
Here is my Query:
{
"$search": {
"index": "invoice_search",
"compound": {
"must": [{
"range": {
"path": "totalAmountTaxIncluded.value",
"gte": 300,
"lte": 300
}
}]
}
}
}
In the above query, I tried to fetch the invoice with totalAmountTaxIncluded.value of 300.