Support the ongoing development of Laravel.io →
posted 10 years ago
Eloquent

Consider the following:

  1. student many-to-many with semester (pivot1)

  2. lesson many-to-many with class (pivot 2)

Now i want to create the following relation

A student in a semester enrolls in some lessons which are tought in specific classes which is basically a many-to-many relation between the pivots?

Is this achievable through eloquent relations?

Last updated 3 years ago.
0

Sign in to participate in this thread!

Eventy

Your banner here too?

nikosv nikosv Joined 5 Mar 2014

Moderators

We'd like to thank these amazing companies for supporting us

Your logo here?

Laravel.io

The Laravel portal for problem solving, knowledge sharing and community building.

© 2025 Laravel.io - All rights reserved.