944 0 0 0
Last Updated : 2025-04-28 22:09:58
Sometimes when searching multiple indices at once with one of those indices having a nested rule to be searched against, other indices that don't have this rule, will return an error like this : [nested] failed to find nested object under path [usersTagsArray], Here is the solution for it: inside the nested query it self use the following attribute to ignore it inside unmapped indices : "ignore_unmapped" : true,
"ignore_unmapped" : true, //This is it
//an Example :
{
"nested":{
"path": "usersTagsArray",
"ignore_unmapped" : true,
"query": {
"bool": {
"must": [
{
"bool": {
"should" : [
';
//Here is the source : https://www.elastic.co/guide/en/elasticsearch/reference/current/query-dsl-nested-query.html
Here is the source link : https://www.elastic.co/guide/en/elasticsearch/reference/current/query-dsl-nested-query.html