here is the index defination not fetching any data with respect to user(ObjectId ) if I remove this it will fetch according to filter let me know how can we resolve this issue?
query:
{
"mappings": {
"dynamic": false,
"fields": {
"deleteStatus": [
{
"dynamic": true,
"type": "document"
},
{
"type": "boolean"
}
],
"name": [
{
"dynamic": true,
"type": "document"
},
{
"type": "autocomplete"
}
],
"number": [
{
"dynamic": true,
"type": "document"
},
{
"type": "autocomplete"
}
],
"user": {
"type": "objectId"
}
}
}
}
{
"$search": {
"index": "contactsearch",
"compound": {
"filter": [{
"equals": {
"value": false,
"path": "deleteStatus"
}
},
{
"equals": {
"value": MongoId(parentId),
"path": "user"
}
}]
}
}
}