issue with entity id
I have a prisma entity defined as such:
"model SurveyResult {
id String @id
result String
reviews String @default("")
analysis String @default("")
idea Idea @relation(fields: [ideaId], references: [id])
ideaId Int
}"
I have an action that calls the entity create like this:
const surveyResult = await context.entities.SurveyResult.create({
data: {
result,
idea: { connect: { id: ideaId } }
},
id: reportId,
});
However, I'm getting the error "Unknown argument for 'id'. Available options are marked with ?."
Any suggestions?
"model SurveyResult {
id String @id
result String
reviews String @default("")
analysis String @default("")
idea Idea @relation(fields: [ideaId], references: [id])
ideaId Int
}"
I have an action that calls the entity create like this:
const surveyResult = await context.entities.SurveyResult.create({
data: {
result,
idea: { connect: { id: ideaId } }
},
id: reportId,
});
However, I'm getting the error "Unknown argument for 'id'. Available options are marked with ?."
Any suggestions?