用sql求两表的差异

wwfxgm wwfxgm 墨衍会员 · AI 创作全网分发 墨衍智能分发 通过墨衍一键同步至各平台 可同步平台 CSDN微信公众号微博知乎掘金百家号博客园抖音小红书 你的文章也可以这样分发 墨衍会员 ¥399起/年,写一次发全网 我也要 + 加入社区
题目要求如下:


表的结构和示例数据如下:
drop table if exists dbo.REPORT_CARD_A;
go
create table dbo.REPORT_CARD_A(
cid char(1) not null,
sid int not null,
score int not null
)



drop table if exists dbo.REPORT_CARD_B;
go
create table dbo.REPORT_CARD_B(
cid char(1) not null,
sid int not null,
score int not null
)

insert into dbo.REPORT_CARD_A
values('A',210,88),('A',211,89),('A',212,90),('A',213,91),('B',210,78),('B',211,79),('B',212,80),('B',213,81),('C',210,80),('C',211,78),('C',212,68)


insert into dbo.REPORT_CARD_B
values('A',210,88),('A',211,69),('A',212,90),('A',214,91),('B',210,78),('B',211,79),('B',214,91),('C',210,80),('C',211,78),('C',212,68),('C',214,45)



我写了好久,感觉功力还是差,没有办法,请大神帮忙。
...全文
评论 11
收藏 已收藏
分享
返回顶部
wwfxgm
应用实例 27,579 成员 68,540 内容