I trying to loop thrus a single index (eg: userprofiles) and update the single field (eg: user_type) if the userprofiles.NAME is exist in other index (eg: badlistedusers)
Can "_update_by_query" API do that?
userprofiles mapping
"mappings" : {
"doc": {
"properties" : {
"NAME" : { "type" : "text" },
"USER_TYPE" : { "type" : "text" }
}
}
}
badlistedusers mapping
"mappings" : {
"doc": {
"properties" : {
"NAME" : { "type" : "text" }
}
}
}