I need to search multiple indexes on Elasticsearch,
My problem is that on each index I have the same field name (is_active), how do I specify that it's the field of the other index ?
I don't believe you can specify the index as part of a bool query in the format you have specified. Have you had a look at using multisearch with the msearch API as an alternative:
The solution I found was to rename the fields of each index, like "index-1_is_active" and "index-2_is_active" . But I haven't yet tested what you've suggested, so I'll take a look at it.
Apache, Apache Lucene, Apache Hadoop, Hadoop, HDFS and the yellow elephant
logo are trademarks of the
Apache Software Foundation
in the United States and/or other countries.