PrismaP
Prisma2y ago
2 replies
22parent

Multiple relations between the same Tables

I am trying to create the following relationship in my Prisma schema.
I have two tables,
Questions
Answers

I am trying to create the following relationship
model Question {
    answers Answers[]
    correctAnswer Answer
}

model Answer{
}

How should i go about setting up the relations?
Was this page helpful?