Is there a way to do multiple mutations so that a field in one mutation can be used in subsequent mutations? Something like this where the id from create_group
is to be used in add_to_group
:
mutation {
create_group {
id
}
add_to_group(id: "someId", value: 1) {
value
}
}
Or do I have to do two executes for this to happen?I don’t think the graphql spec allows this. You would have to create a mutation like “create and add to group”
mutations do not compose 😞 It's not only GQL limitation. EQL Ecosystem also has this limitation
darn 😞 2 executes it is then
@souenzzo EQL has (Dotomic style) tempid however 🙂
@myguidingstar yep, it solve one problem But there is no (good/stable) implementations and it's hard to guarantee consistence in both mutations (or the behavior case one fail)