_update API in elastic search

Hi ES users,

Can we perform the _update query to multiple Id's.

For example if I want to update the Time field of my Index/type/id as below:
curl -xPOST http://192.168.0.164:9200/prashant_cata/session/123/_update -d '{

"script": "ctx._source.Time = "2014-03-25T14:31:12""
}'

So is there anyway I can update the Time field of all docs like:
curl -xPOST http://192.168.0.164:9200/prashant_cata/session/*/_update -d '{

"script": "ctx._source.Time = "2014-03-25T14:31:12""
}'

Or is there any other way around for this scenario.

You are looking for this: https://github.com/elasticsearch/elasticsearch/issues/1607

May be this plugin could help: https://github.com/yakaz/elasticsearch-action-updatebyquery in the meantime.

--
David Pilato | Technical Advocate | Elasticsearch.com
@dadoonet | @elasticsearchfr

Le 1 avril 2014 à 09:06:43, Prashant Agrawal (prashant.agrawal@paladion.net) a écrit:

Hi ES users,

Can we perform the _update query to multiple Id's.

For example if I want to update the Time field of my Index/type/id as below:
curl -xPOST http://192.168.0.164:9200/prashant_cata/session/123/_update -d
'{

"script": "ctx._source.Time = "2014-03-25T14:31:12""
}'

So is there anyway I can update the Time field of all docs like:
curl -xPOST http://192.168.0.164:9200/*prashant_cata/session/**/_update -d
'{

"script": "ctx._source.Time = "2014-03-25T14:31:12""
}'

Or is there any other way around for this scenario.

--
View this message in context: http://elasticsearch-users.115913.n3.nabble.com/update-API-in-elastic-search-tp4053216.html
Sent from the ElasticSearch Users mailing list archive at Nabble.com.

--
You received this message because you are subscribed to the Google Groups "elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an email to elasticsearch+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/elasticsearch/1396336000440-4053216.post%40n3.nabble.com.
For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an email to elasticsearch+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/elasticsearch/etPan.533a713c.12e685fb.16bdd%40MacBook-Air-de-David.local.
For more options, visit https://groups.google.com/d/optout.