How to craft a data transformation - use script?

Pretty simple requirement:

Find all documents where the field "vendorid" has no value and give it a
value of "6"

Would I do this with an update call and use script? I'm a little unclear
how. Or is there a more canonical way to do something like this?

You received this message because you are subscribed to the Google Groups "elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an email to
To view this discussion on the web visit
For more options, visit