Sylvain (seel-vahn)
02/08/2021, 5:12 AMawait prisma.post.update({
where: { id: 'xxx' },
data: {
tags: {
disconnect: [
// disconnect tag with uppercase
{ label: "World" }
],
connectOrCreate: [
// connect or create tag full lowercase
{
where: { label: "world" },
create: { label: "world" }
}
]
}
}
})
Sylvain (seel-vahn)
02/08/2021, 5:56 AMdisconnect
and connectOrCreate
appear to be case-insensitive.
The example query I wrote is not returning any error - however, under the hood, it would simply disconnect and then reconnect to the same tag.