ERROR: relation "public.users_permissions" does no...
# orm-help
e
ERROR: relation "public.users_permissions" does not exist
s
I see that
permissions
is a list in your datamodel. The
set
will actually replace the field’s content with what you provide, so it should look something like:
Copy code
mutation CreateLocal {
  createLocalUser(
    data: {
      email: "<mailto:example@mail.com|example@mail.com>"
      password: "Welcome1"
      user: { create: { firstName: "John", permissions: { set: [USER] } } }
    }
  ) {
    id
  }
}
Notice I wrapped the
permissions.set
in square brackets
e
Thanks, that worked.