I want to retrieve the docs where ids are having docs with eventName=ShipmentLoaded and Not having other docs with eventName=ShipmentPlanned
so the query will return only the last document with id=2 because it does have doc with eventName=ShipmentLoaded and does not have other doc with eventName=ShipmentPlanned
what kind of query that we can use to achieve this?
Hi @RabBit_BR This will not work because it will also retrieve the doc with id=1 but I don't want to retrieve it because it has another doc with eventName=ShipmentPlanned
What you are describing would be a join between records, which Elasticsearch does not support. You could however create a separate index using a transform where there is one document per id, which could likely support your query.
Hi @RabBit_BR as mentioned by @Christian_Dahlqvist I basically want a join query where eventName: ShipmentLoaded and for those documents ids we don't have another documents with eventName: ShipmentPlanned
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.