Jump to content

I don't understand why I can't just create one table?


sirflex10

Recommended Posts

I'm new to php & mysql and I'd like to create a sports statistics database to track my flag football teams player stats. Is there anything wrong with just creating one table with player name, player id, touchdowns, flag grabs, interceptions, sacks, etc.

 

Can someone please explain the logic behind creating multiple tables? Thank you in advance

There are a number of reasons for multiple tables, many of which are good (but some of which aren't). Normalization is a good one as it helps prevent data duplication and improve potential searches, while partitioning is mostly just for keeping "groups" of data in separate locations for cleanliness.

 

Here's a question for you:

Of all the player data you want to track, is anything of it related to something besides the player him-/herself? Maybe you want to track some of the numbers per-game and not throughout their entire "career"?

Thank you for your quick reply. As of know I only want to track "Career" stats. Below is an example of the table that I have in mind.

 

player_id, player_name, points, assist, rebounds, blocks, turnovers

 

Is there any benefit of making multiple tables or is it ok to use one table for the info above?

Archived

This topic is now archived and is closed to further replies.

×
×
  • 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.