Report a Dgraph Client Issue
What Dgraph client (and version) are you using?
- Dgo
Version:
v210
What version of Dgraph are you using?
Latest
What you wanted to do
DGO Json Upsert Mutation
What you actually did
mu := &api.Mutation{
CommitNow: true,
SetJson: b,
}
response, err := s.DClient.NewTxn().Mutate(context.Background(), mu)
if err != nil {
log.Fatal(err)
}
The byte loaded in b looks like:
{
"query": "{ q(func: eq(containerId, 12345)) {v as uid} }",
"set": {
"containerId": "12345",
"name": "test",
"uid": "uid(v)"
}
}
Error:
variables [v] not defined
Ratle or the http endpoint on the other hand processes the mutation without any problems (see below)