ガンバ大阪、J1リーグ 試合結果データベース

年度別にデータを参照(1993~2012)


SQLステートメントを使ってみる(SQL文の作成方法については下記を参照)


結果



ご説明

このデータベースには、1993年~2012年のJ1リーグでガンバ大阪が戦った全680試合のデータが入ってます。

ただし、1993年の場合、気温と湿度のデータはありません。

項目は以下のとおり。括弧内はフィールドの定義です。 テーブル名:gamba_yeardata

連番(id integer)
年(year integer)
月(month integer)
日(day integer)
曜日(week text)
ガンバのスコア(gscore integer)
対戦相手名(opponentname text)
対戦相手のスコア(opponentscore integer)
ホーム/アウェー(homeaway text)
試合のカテゴリ(category text)
節(section text)
キックオフの時刻(kickoff text)
スタジアム名(stadium text)
観客数(audience integer)
お天気(weather text)
気温(1993年は除く)(temperature float)
湿度(1993年は除く)(humidity integer)
主審(referee text)
副審(assistantreferee text)
第四の審判(fourthofficial text)


追加
スタジアム情報のテーブル:stadium_tbl

連番(id integer)
略称(shortname text)
当時の名称(thenname text)
正式な名称(officialname text)
現在の名称(currentname text)
専用or多目的(exclusive text)
住所(address text)
緯度(latitude double)
経度(longitude double)
キャパ(capacity text)
WikiのURL(referenceurl text)


これらを使って、SQLを作成して検索できます。
SQL文の最後は、セミコロンで閉じてください。

例1

全部のデータを抽出する場合
select * from gamba_yeardata;

例2

2012年のホームで勝った試合の対戦相手の検索
select opponentname from gamba_yeardata where year=2012 and homeaway="home" and gscore > opponentscore;

例3

2012年までのJ1の全試合中、「家本 政明」氏が主審で負けなかったゲームの検索

1993~1998までドロースコアの場合PK戦で決着をつけるレギュレーションでしたのでスコアだけから判断できない場合もありますが、 ガンバ戦で家本氏が主審をつとめたのは、2004年からなので結果に影響はありません。

select * from gamba_yeardata where gscore >= opponentscore and referee="家本 政明";

同様に、負けたゲームの検索
select * from gamba_yeardata where gscore < opponentscore and referee="家本 政明";

例4

2001年のガンバ戦、スコアと対戦相手、スタジアムの現在の名称と当時の名称を列挙してみる

select gamba_yeardata.gscore,gamba_yeardata.opponentscore,gamba_yeardata.opponentname,stadium_tbl.currentname,stadium_tbl.thenname from gamba_yeardata inner join stadium_tbl on gamba_yeardata.stadium = stadium_tbl.shortname where year=2001;