SQLZOO练习–The JOIN operation
8.The example query shows all goals scored in the Germany-Greece quarterfinal.
Instead show the name of all players who scored a goal against Germany.
HINT
Select goals scored only by non-German players in matches where GER was the id of either team1 or team2.
You can use teamid!=‘GER’ to prevent listing German players.
You can use DISTINCT to stop players being listed twice.
SELECT distinct player
FROM game inner JOIN goal ON id = matchid
WHERE team1 = 'GER' OR team2