Closed AKlaus closed 2 years ago
Rewrite patch requests in a more strongly typed way (as it was suggested in ravendb/ravendb/issues/12650).
Example:
var index = GetIndexQuery(session.Query<PrimarySkills.Result, PrimarySkills>() .Where(result => result.SkillId == 1)); index.Query += @" update { for (var i = 0; i < this.Skills.length; i++) { this.Skills[i].IsPrimary = false } }"; var operation = store.Operations.Send(new PatchByQueryOperation(index)); static IndexQuery GetIndexQuery<T>(IQueryable<T> queryable) { var inspector = (IRavenQueryInspector)queryable; return inspector.GetIndexQuery(isAsync: false); }
Rewrite patch requests in a more strongly typed way (as it was suggested in ravendb/ravendb/issues/12650).
Example: