I have a question about pyes (Python API for ElasticSearch).
Is it possible for the search method to return the keys of the documents found?
The code I'm using is:
import pyes conn = pyes.ES('localhost:9200') q = pyes.StringQuery("november rain", default_operator="AND") result = conn.search(query=q, indices=[index]) for r in result: print r
Result: documents were found, without a key (field _id), with which I saved the document.
The question is how to return _id keys?
Thanks!
source share