is there a findOrcreate method in Prisma ?
Apparently prisma doesn't have a findOrCreate, but rather passing an empty object to the update property in upsert.
A decision hasn't been reached yet on this issue https://github.com/prisma/docs/issues/640 , because I can't find any upsert example in the docs that uses an empty update object, or a findOrCreate section. Please fix
@Joël
r
Ryan
10/18/2021, 5:35 AM
This can be easily done using
upsert
and specifying an empty object in update as you have specified above.
n
Nathaniel Babalola
10/18/2021, 7:13 PM
@Ryan yes , but it isn't in the docs. I rather found it in GitHub issues.