PrismaP
Prisma15mo ago
26 replies
kimb0x

Can't delete records from Prisma Postgres in Studio

I haven't been able to delete data from the new Prisma Postgres within Studio--neither a single register nor with a rawquery using prisma client.

The error I get is:

Type: undefined
Message: 
Invalid prisma.table_name.delete() invocation:


Error in batch request 0: Error occurred during query execution:
ConnectorError(ConnectorError { user_facing_error: None, kind: QueryError(PostgresError { code: "55000", message: "cannot delete from table \"TableName\" because it does not have a replica identity and publishes deletes", severity: "ERROR", detail: None, column: None, hint: Some("To enable deleting from the table, set REPLICA IDENTITY using ALTER TABLE.") }), transient: false })

Code: undefined

Query:
[object Object]


When I try to set the Replica Identity I get a permission error.

The owner of the tables is: prisma_migration

My user is: prisma_application

I can't change the permissions with that user.

I tried creating the database with prisma migrate dev and with prisma db push and the situation is the same.

I connect to Studio (v0.503.0) with a generated Prisma Client (v5.21.1) using the --no-engine flag within a local Deno (v2.0.4) development.

Thank you so much!

PS. Love the Prisma Postgres btw! Can't wait to see how it develops!
Was this page helpful?