所以我试图完成这个问题
Using a Set Operator, create a query that will show the names of those teams that have not won a
game. Include in your output the team name. Your output should look like the following:
teamName
---------------
No Winner
Red Tigers
我尝试了一些不同的东西,比如
select teamName
from team
intersect
select winning_team
from game;
但说实话我甚至不认为我很近, 我不知道怎么做,我可以让teamids出现赢得比赛,但我不知道如何让它显示没有赢得比赛的ID,即使我可以,我不知道如何转换在团队名称中的数字,我总是得到一个错误,我死在这里这是一个课堂作业,她指定作为家庭作业而不是通常我会让老师帮助解释这些东西... :(如果任何人愿意帮助那将是伟大的
我最终使用了这个
select teamName
from team
except
select teamName
from team t join game g
on g.winning_team = t.teamID;
谢谢dstanley我需要的轻推