Today the data provider is using the update many query in hasura to update single entries. This led to a critical bug in production for one of the companies I'm developing for, where all records were updated. This is because update many actually runs without the id column in the where clause being present!
With update_resource_by_pk hasura actually requires the pk_columns to be set, and this behaviour is no longer possible.
Also update by pk is more db-efficient and should lead to easier graphql debugging for anyone experiencing issues.
NOTE: this should be considered a minor version, as it has the potential to break existing implementations that are extending the package with custom buildVariables for the UPDATE queries
Today the data provider is using the update many query in hasura to update single entries. This led to a critical bug in production for one of the companies I'm developing for, where all records were updated. This is because update many actually runs without the id column in the where clause being present!
With update_resource_by_pk hasura actually requires the pk_columns to be set, and this behaviour is no longer possible.
Also update by pk is more db-efficient and should lead to easier graphql debugging for anyone experiencing issues.
NOTE: this should be considered a minor version, as it has the potential to break existing implementations that are extending the package with custom buildVariables for the UPDATE queries