diff --git a/modules/ROOT/pages/migration/index.adoc b/modules/ROOT/pages/migration/index.adoc index 6fcd4748..e05c82b5 100644 --- a/modules/ROOT/pages/migration/index.adoc +++ b/modules/ROOT/pages/migration/index.adoc @@ -765,3 +765,43 @@ type Movie @node { title: String! @private } ---- + + +=== Deprecated `where` field in `update` input + +The `where` field for nested update operations has been deprecated to be moved inside the `update` input field. +The `where` in its deprecated location is a no-op for all nested operations apart from `update`. + +For example, the following mutation is using the deprecated syntax: + +```graphql +mutation { + updateUsers( + where: { name: { eq: "Darrell" } } + update: { + posts: { + where: { node: { title: { eq: "Version 6 Release Notes" } } } + update: { node: { title: { set: "Version 6 Release Announcement" } } } + } + } + ) +} +``` + +Modify the mutation to move the `where` inside the `update` operation: + +```graphql +mutation { + updateUsers( + where: { name: { eq: "Darrell" } } + update: { + posts: { + update: { + where: { node: { title: { eq: "Version 6 Release Notes" } } } + node: { title: { set: "Version 6 Release Announcement" } } + } + } + } + ) +} +``` \ No newline at end of file