'IElasticClient.UpdateByQuery In ASP .NET core
I'm trying to update the document with this statement. IDK this is the correct argument to the UpdateByQuery method?
[HttpPut("update")]
public async Task<string> UpdateUser(User user)
{
var res = await elasticClient.UpdateByQuery<User>(x => x.Index("User").Query(q
=> q.Match(m => m.Field(f => f.Email).Query(user.Email))));
return response.Id;
}
I want to update my user object by Email.
Thanks for your time.
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|
