表结构如下:
查询两支队伍的比赛情况,sql语句如下:
SELECT t1.team_name,g.team1_score,g.team2_score,t2.team_name,g.gametime FROM game as g,team as t1 ,team as t2 WHERE g.team1_id = t1.team_id AND g.team2_id = t2.team_id
表结构如下:
查询两支队伍的比赛情况,sql语句如下:
SELECT t1.team_name,g.team1_score,g.team2_score,t2.team_name,g.gametime FROM game as g,team as t1 ,team as t2 WHERE g.team1_id = t1.team_id AND g.team2_id = t2.team_id