[eluser]bEz[/eluser]
:question: Not to distract to much from DM development, so I apologize if I'm asking for help by replying to the DM thread.
In a previous app, I managed a league DB using the following setup (
just a few of the many tables used).
Code:
seasons (seasonID, ..., ..., ...)
conferences (conferenceID, seasonID, ..., ..., ...)
divisions (divisionID, conferenceID, ..., ..., ...)
teams (teamID, divisionID, ..., ..., ...)
players (playerID, teamID, ..., ..., ...)
Now that I'm utilizing DM, I'm restructuring this schema as follows:
NORMAL TABLESCode:
seasons (id, ...)
conferences (id, ...)
divisions (id, ...)
teams (id, ...)
players (id, ...)
apparently I would need the following as well:
JOIN TABLESCode:
conferences_seasons (id, conference_id, season_id)
conferences_divisions (id, conference_id, division_id)
divisions_teams (id, division_id, team_id)
players_teams (id, player_id, team_id)
What I need to confirm are the following:
(A) Am I required to create other join tables (
divisions_seasons, seasons_teams, ...) in order to pull data? (
the user guide has been helpful, but I'm still in learning mode)
(B) Can I possibly get a few examples, best approaches, to populating the join tables.
Quote:i.e:
I create a new season (object & data of course).
for that season I create two conferences
in each conference I create two divisions
in each division I create approxitmately 6 teams
on each team I create 15 players.
The entire approach can be inserted using cookie cutter data (season1, conference1, conference2, division1, division2, team1, team2, ...) or each entity 1 at a time.
If cookie cutter, I could utilize a datagrid to update the data after temporary data has been "saved", which brings up another request:
© Has anyone used a datagrid CI implementation with DM?