_update_by_query doesn't return a list of affected IDs and Indices

I want to update records by running "_update_by_query" and after that receive the list of affected ID's and indices like it happens when creating new record.
It would be also nice to have returning the selected fields from the affected records.

The exact _update_by_query request doesn't matter here, you can run any request with the same result.

The update by query response does not contain any ids, but you could update a field as part of the update by query task, and then query for that field after the update is finished.

Yes, I know.
But I want to do it by 1 request.

as written above, that is not possible. Out of curiosity: What is the problem with the mentioned workaround, that will allow you to do what you need to? Why doesn't that work in your case?

In my query I have an unknown index and known id.
After update I want to know the exact index name where I've updated the record for the following updates.
If it is impossible I'll have to split _update_by_query request into 2 requests - search and update.

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