see on GitHub

Attachments : How to update an attachment metadata only?

UpdateAttachmentMetadata is used to update an attachment metadata in a database.

Syntax

void UpdateAttachmentMetadata(string key, Etag etag, RavenJObject metadata);

Parameters
key string key under which attachment is stored
etag Etag current attachment etag, used for concurrency checks (null to skip check)
metadata RavenJObject attachment metadata

Example

JsonDocumentMetadata attachment = store.DatabaseCommands.Head("albums/holidays/sea.jpg");
RavenJObject metadata = attachment.Metadata;
metadata["Description"] = "Holidays 2012";

store
	.DatabaseCommands
	.UpdateAttachmentMetadata("albums/holidays/sea.jpg", attachment.Etag, metadata);