Patiparn Intaraprasert
09/23/2021, 9:32 AMRyan
09/23/2021, 11:01 AMC
you need to create a new relation. So create
would work in this case:
await prisma.A.update({
{ where: { id: 1 } },
{ C: {
create: {
// this will be an id from model B
bId: b.id
}
}
Patiparn Intaraprasert
09/23/2021, 11:46 AM