Jump to content

Recommended Posts

Okay, so have a form to input information about a football player, with a field that a person would enter in all of the teams that the player has been on.  The idea is that records of these players will be used to generate an index of teams, and team pages.  The team pages would then display records of all players who have once been on the team at some point.

 

That's how it works in abstract.  I'm not exactly sure how to handle the field; I'm thinking of having the teams be comma separated when the user inputs them.  However, I'm more concerned about how to handle the backend, in the database itself.

 

If each player has multiple teams associated with them, how should I store the teams value in the table for players?  At the moment, since the form is about a single player, the main table I'm working with is the players table.  However, I think I may need an additional table for teams.  Each row on this team table wouldn't consist of much, just an id, and then a list of players.  However, how would I then handle that list of players?

 

Any suggestions as to how to deal with this situation?  Is there a better solution?

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.