For two tables
player
and
team
With a 1-∞ relationship (player to team): how would you count how many players belong to each team?
Failed attempt:
SELECT team.teamid, (SELECT COUNT(player.team) FROM player)
FROM team
LEFT JOIN player ON player.team = team.teamid