Skip to content

Instantly share code, notes, and snippets.

@uris77
Created July 3, 2013 14:59
Show Gist options
  • Save uris77/5918931 to your computer and use it in GitHub Desktop.
Save uris77/5918931 to your computer and use it in GitHub Desktop.
ES Update Script
if(ctx._source.containsKey(\"matchScore\")) {
ctx._source.matchScore += {"key": anIntValue}
} else {
ctx.source.matchScore = {"key": anIntValue}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment