We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Hello, I have a cost table defined (Hasura v1.0.0-beta.4) with two fields:
id: Integer description: Text
If I run the mutation on cost table with variable ID declaration:
mutation ($ID: Int) { delete_cost(where: {id: {_eq: $ID}}) { returning { id } } }
and no variable JSON is attached, the mutation deletes ALL RECORDS in the table cost. It should not delete any records.
The text was updated successfully, but these errors were encountered:
Hi @matjazrak,
There is an open issue for this same case. #704
Meanwhile, you can make the id mandatory in your mutation. This will return an error if no variable is passed.
mutation ($ID: Int!) { delete_cost(where: {id: {_eq: $ID}}) { returning { id } } }
Sorry, something went wrong.
Hi @leoalves,
thank you for your feedback. I agree with the others: the {} should be treated as NULL and not as %. (I’m comming from T-SQL world :)).
Kind regards, Matjaz
I'm closing this in favour of #704.
No branches or pull requests
Hello,
I have a cost table defined (Hasura v1.0.0-beta.4) with two fields:
id: Integer
description: Text
If I run the mutation on cost table with variable ID declaration:
mutation ($ID: Int) {
delete_cost(where: {id: {_eq: $ID}}) {
returning {
id
}
}
}
and no variable JSON is attached, the mutation deletes ALL RECORDS in the table cost.
It should not delete any records.
The text was updated successfully, but these errors were encountered: