Corey Snyder
06/07/2020, 2:22 AMdatamodel.prisma
type Product{
id: ID! @id
images: [Image] @relation(onDelete: CASCADE)
}
When this is called, would you expect the images to all be deleted for that product?
await context.prisma.deleteProduct({ id: args.id })
Because that’s totally not what’s happening. Images rows are being left hanging with nothing linking to them.Ryan
06/08/2020, 9:47 AMconnect
to those images to the Product
while creating the Image? If not, that could be the issue.