I want to create a database for soccer scores.
Obviously, we have:
- Countries (Netherlands, Germany, (But also Europe))
- Competitions (Eredivisie, Bundesliga, UEFA Europa League)
- Teams (FC Twente, Bayern Munchen, Atletico Madrid)
- Players (Luuk de Jong, Manuel Neuer, Tiago Mendes)
- Matches (FC Twente – PSV, Bayern – Leverkusen, etc)
- Events (Goal scored in 40th minute by Luuk de Jong)
I’m using Dezign in which I have created the scheme below:

Obviously, a Competition is bound to a Country, a Player to a Team, etc.
But then some problems occur. An Event belongs to a Match and a Player. So the Event could get a match_id and a player_id. But then any player of any team could ‘score’ in a match in which he doesn’t belong (A player of team C could score in a match between team A and team B). How can I restrict this for example?
Also, a Team could compete in its ‘normal’ competition, but also in the Champions League. Thus, a simple competition_id in the Team entity would not suffice.
And do you suggest any other thoughts?
Edit in response to Philipp

You lack an entity to express the
Lineup(team, match)along with aLineupPosition (lineup, player).You could then associate an
Eventwith aLineupPosition(specific player in a specific match), thereby linking yourEventto the correctMatch, viaLineupPosition->Lineup->Match.