If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

 
Go Back  dBforums > General > Database Concepts & Design > Football Help

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 07-27-11, 16:11
cpod500 cpod500 is offline
Registered User
 
Join Date: Jul 2011
Posts: 5
Football Help

hi guys could any one help me normalise this :TEAM(Team_id,TeamName)

PLAYER(Player_id,FirstName,LastName,DOB)

CONTRACT(Player_id,Team_id,StartDate,EndDate,Sqaud Number)

FIXTURE(Fixture_id,Ref_id,HomeTeam,AwayTeam,Date)

REFEREE(Ref_id,FirstName,LastName)

DISCIPLINARY CASE(DCase_id,Player_id,Fixture_id,Event)



im struggling to get my head round the hometeam and awayteam, Do i make new tables for them, or somthing else
Reply With Quote
  #2 (permalink)  
Old 07-27-11, 16:22
blindman blindman is offline
World Class Flame Warrior
 
Join Date: Jun 2003
Location: Ohio
Posts: 11,726
It must be homework season again.
Do not make separate tables for home teams and away teams.
__________________
If it's not practically useful, then it's practically useless.

blindman
www.chess.com: "sqlblindman"
Reply With Quote
  #3 (permalink)  
Old 07-27-11, 17:41
r937 r937 is offline
SQL Consultant
 
Join Date: Apr 2002
Location: Toronto, Canada
Posts: 19,524
Quote:
Originally Posted by cpod500 View Post
im struggling to get my head round the hometeam and awayteam
you mean in the fixtures table? they are both foreign keys
__________________
r937.com | rudy.ca
please visit Simply SQL and buy my book
Reply With Quote
  #4 (permalink)  
Old 07-28-11, 03:26
cpod500 cpod500 is offline
Registered User
 
Join Date: Jul 2011
Posts: 5
Foreign keys from which table ?
Reply With Quote
  #5 (permalink)  
Old 07-28-11, 03:31
r937 r937 is offline
SQL Consultant
 
Join Date: Apr 2002
Location: Toronto, Canada
Posts: 19,524
Quote:
Originally Posted by cpod500 View Post
Foreign keys from which table ?
take a screaming wild guess -- which of your tables has team information in it?
__________________
r937.com | rudy.ca
please visit Simply SQL and buy my book
Reply With Quote
  #6 (permalink)  
Old 07-28-11, 04:03
cpod500 cpod500 is offline
Registered User
 
Join Date: Jul 2011
Posts: 5
So my team_id can be in hometeam colum and away team colum ?
Reply With Quote
  #7 (permalink)  
Old 07-28-11, 04:18
r937 r937 is offline
SQL Consultant
 
Join Date: Apr 2002
Location: Toronto, Canada
Posts: 19,524
um..... yes
__________________
r937.com | rudy.ca
please visit Simply SQL and buy my book
Reply With Quote
  #8 (permalink)  
Old 08-04-11, 05:16
dbGuyo dbGuyo is offline
Registered User
 
Join Date: Jul 2011
Posts: 9
These tables look, at least, in BCNF normal form.
The only thing I don't like in this design is the DCase_id in DISCIPLINARY CASE.
You can eliminate it but add DCase_time to show the time that the event happened if you want to be more realistic.

Am I right?
Reply With Quote
Reply

Tags
database design, normalisation

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On