I am using Azure Table Storage Rest Api to Update the entity. If the entity has 5 columns(col1,col2,col3,col4,col5) and I am making a PUT request body something like this.
{"col1":"value"}
The rest of the columns value is set to NULL.
Is there a way to avoid it?
The reason you're seeing this behavior is because you're performing
Update Entityoperation which will replaces an entire entity.If you're only interested in changing just one attribute (property), you need to use
Merge Entityoperation which updates an existing entity by updating the entity's properties. It does not replace the existing entity.Simply changing your HTTP Request method to
MERGEfromPUTshould do the trick.