The PATCH
method requests that a set of changes described in the request entity be applied to the resource identified by the request URL. The set of changes is represented in a format called the
Patch Document. The PATCH
method affects the resource identified by the request URL.
Within the RavenDB server, the PATCH
request allows any single document to be updated without replacing the entire document as it is happening with the PUT
request. The PATCH
command accepts an array of commands, so it is possible to issue multiple modifications for the same document. The PATCH
command keys are case sensitive and they have to be specified with the correct
Pascal Casing. The six different command keys which you need to specify are listed as follows:
Type
: This represents the operation type. RavenDB supports the following patch operations:Set
: It is a property to a new value. (Optionally, creating the property).Inc
: Use this to increment a property value by a given value. (Optionally...