Support the ongoing development of Laravel.io →
Database Eloquent
Last updated 1 year ago.
0

Hi, What you have here is a many-to-many relationship You can check Many To Many

Last updated 1 year ago.
0

Thanks for the reply. One more question. After reading my post, I'm not sure I was 100% clear on the relationship of the Files. The files that belong to the People only belong to People. However, there are files that belong to other Models. So, let's say I also have a Location model. Those files only belong to Locations and not People.

Does that make sense? Does that change anything? Or, should I still be looking at Many to Many. (which I'm doing now on my end.)

Last updated 1 year ago.
0

If Files for Location and Files for People share model, you can without problem set it as many-to-many or even poli relation.

Last updated 1 year ago.
0

Sign in to participate in this thread!

Eventy

Your banner here too?

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.

© 2024 Laravel.io - All rights reserved.