Another question related to many-to-many relations...
# orm-help
s
Another question related to many-to-many relations. I might need to convert an already existing implicit many-to-many relation, to an explicit m-n relation instead (to add extra fields in the relation table). In that context, I’d be interested to know if there is a recommended approach to smoothly achieve this with minimum disruption?
r
@Sylvain (seel-vahn) 👋 That would have to be done in multiple steps, so something like this: 1. Create the explicit table 2. Migrate existing data from the implicit table 3. Delete the implicit table and connect to the explicit one I don’t see any easier way of doing this at the moment 🙂
s
How about re-using the same naming convention as the implicit relation (aka. A / B _RelationName)? Would that cause any issue?
r
That wouldn’t work as you wouldn’t be able to fetch extra columns from the explicit relation.
Explicit relation tables with the implicit conventions are hidden from
schema.prisma
👍 1