Prisma 1 Forum

Defining a 3-way relationship

I also posted this question on StackOverflow


I’m new to Prisma. So I have a 3-way relationship between User, Event and Role I would like to define. For each association of a User and an Event, there exists a Role for that association. If I were to design a database table for another ORM, I would have created a event_user table with user_id, event_id and role_id as columns to relate them.

How would one create a relationship like this in Prisma?


For some context, each user would have a list of global roles as well, so there would already be an association between User and Role. The question concerns the “local roles” for each event.

This topic was automatically closed 45 days after the last reply. New replies are no longer allowed.