Best way to set up this Relation

2013-04-30 Thread Fernando Nery Filho
Hey everybody. I am looking for some advice here. I got the following tables in my application: Movies and Celebrities. Celebrities can participate in movies as Actors, Directors and Script Writters. So, while editing a movie (or adding one) I should be able in my view to select in 3

Re: Best way to set up this Relation

2013-04-30 Thread Ciul
Hi Fernando, an idea that it's up to you to try is implement a MovieParticipation Model. Thus: *Celebrities* *hasMany* *MovieParticipation* *Movies* *hasMany* *MovieParticipation* * * Where the MovieParticipation table might have following fields: - *id* - *celebrity_id* - *movie_id*