# Update request not updating documents in index

**URL:** <https://discuss.elastic.co/t/update-request-not-updating-documents-in-index/185861>\
**Category:** Elasticsearch\
**Created:** [June 14, 2019, 1:23pm UTC](https://discuss.elastic.co/t/update-request-not-updating-documents-in-index/185861 "2019-06-14T13:23:49Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![vyas.radhakrishnan](https://avatars.discourse-cdn.com/v4/letter/v/838e76/32.png) [@vyas.radhakrishnan](https://discuss.elastic.co/u/vyas.radhakrishnan)\
**Post date:** [June 14, 2019, 1:23pm UTC](https://discuss.elastic.co/t/update-request-not-updating-documents-in-index/185861/1 "2019-06-14T13:23:49Z")

</div>

in Elastic 6.5.4 update request for a field does not update the field correctly.

The existing content is (partial content from doc)

"PrimaryEmail": {  
"ContactPointId": 100000016065020,  
"\_secured": "Y",  
"EmailAddress": "sendmail-test-discard@abc.com",  
"OverallPrimary": true  
}  
},

Now there is a PUT request to update this content,

"PrimaryEmail": {  
"ContactPointId": 100000016065020,  
"EmailAddress": "sendmail-test-discard@oracle.com",  
"OverallPrimary": true  
}  
},

So ideally after this request "\_secured": "Y" should be removed. This is not happening.

Header of curl is

{  
"update": {  
"\_index": "mm\_d4e808fe-ede7-4e29-b5f5-f65ead14fa51\_bb500161-b24d-4bde-afb5-f472cae272ae",  
"\_type": "documentType",  
"\_id": "300100179416462",  
"\_version": "5"  
}"doc": {  
...

We are doing a full update like referred here  
[https://www.elastic.co/guide/en/elasticsearch/guide/master/update-doc.html](https://www.elastic.co/guide/en/elasticsearch/guide/master/update-doc.html)

What might be going wrong here due to which \_secured is not removed. ?

---

<div class="post-metadata">

**Author:** ![dadoonet](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/dadoonet/32/137187_2.png) [@dadoonet](https://discuss.elastic.co/u/dadoonet)\
**Post date:** [June 14, 2019, 11:36pm UTC](https://discuss.elastic.co/t/update-request-not-updating-documents-in-index/185861/2 "2019-06-14T23:36:15Z")

</div>

Could you provide a full recreation script as described in [About the Elasticsearch category](https://discuss.elastic.co/t/about-the-elasticsearch-category/21). It will help to better understand what you are doing. Please, try to keep the example as simple as possible.

A full reproduction script will help readers to understand, reproduce and if needed fix your problem. It will also most likely help to get a faster answer.

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [July 12, 2019, 11:36pm UTC](https://discuss.elastic.co/t/update-request-not-updating-documents-in-index/185861/3 "2019-07-12T23:36:46Z")

</div>

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