Skip to content

Instantly share code, notes, and snippets.

@rifkiamil
Last active October 27, 2021 22:05
Show Gist options
  • Save rifkiamil/a149f4ddb4ba6fae88b4dd49b3f6a884 to your computer and use it in GitHub Desktop.
Save rifkiamil/a149f4ddb4ba6fae88b4dd49b3f6a884 to your computer and use it in GitHub Desktop.
Football Data Database Markup Language - no joins
Project project_name {
database_type: 'BigQuery'
Note: 'Football data'
}
Table appearances {
player_id INTEGER
game_id INTEGER
appearance_id STRING [pk]
league_id STRING
player_club_id INTEGER
goals INTEGER
assists INTERER
minutes_played INTERER
yellow_cards INTERER
red_cards INTERER
}
Table clubs {
club_id INTERER [pk]
name STRING
pretty_name STRING
domestic_competition STRING
league_id STRING
total_market_value FLOAT
squad_size INTERER
average_age FLOAT
foreigners_number INTERER
foreigners_perecentage FLOAT
national_team_players INTERER
statium_name STRING
statium_seats INTEGER
net_transfer_record STRING
coach_name STRING
url STRING
}
Table games {
game_id INTERER [pk]
league_code STRING
season INTERGER
round STRING
date DATE
time TIME
home_club_id INTERGER
away_club_id INTERGER
home_club_goals INTERGER
away_club_goals INTERGER
home_club_position INTERGER
away_club_potition INTERGER
stadium STRING
attendance INTERGER
url STRING
}
Table leagues {
league_id STRING
name STRING
confederation STRING
}
Table players {
player_id INTERGER
current_club_id INTEGER
name STRING
pretty_name STRING
country_of_birth STRING
country_of_citzenshp STRING
date_of_birth DATE
position STRING
sub_position STRING
foot STRING
height_in_cm INTEGER
url STRING
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment