Zefex Developer
03/02/2022, 12:03 AMprisma.user.update({
where: { id: '' },
data: {
name: 'John Doe',
tags: {
connect: {
tagId_userId: {
tagId: '',
userId: ''
}
}
}
}
})
I didn't want to repeat the userId
especially because I'm going to be asking as an input for the user. Is there another way of doing that? In resume, is there a way to only specify the tag ids instead of the userId
over and over again?Chris Tsongas
03/03/2022, 12:20 AMprisma.user.update({
where: { id: '' },
data: {
name: 'John Doe',
tags: {
connect: [
{
id: ''
},
{
id: ''
}
]
}
}
})
Chris Tsongas
03/03/2022, 12:21 AM