Get doc with _id in rolling index

Does anybody know how to find a document (with _id) within rolling index?
I cannot use wildcard in indexname.
Do I need to search the hard index one by one?

This is what wildcards are for. If you can't use them, you need to go one by one (or selecting all indices at once when executing the search).

Out of curiosity: Can you explain, why you cannot use them?

Suppose my document is under

I cannot issue
GET xyz_201911*/_doc/84000beb-fe84-11e9-9ca4-34b0dd229042
I get index_not_found_exception where it treats * as part of the index name.

It's not I don't want to use it. It's not allowed.
Maybe I'm doing something wrong?
This is ES7.3.1

Eventually I want to do this via High Rest API. But I believe the API takes a hard index as well.

try executing a search with a query for the _id field instead of issuing a get operation.

cool. That works. Why didn't I think of that?

1 Like

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.