日期:2014-05-18 浏览次数:20667 次
select isnull(a.姓名,b.姓名) 姓名,a.成绩 as 5月成绩,b.成绩 as 3月成绩 from a full join b on a.姓名 = b.姓名
------解决方案--------------------
select a.姓名,a.成绩 as 5月成绩,b.成绩 as 3月成绩 from a inner join b on a.姓名 = b.姓名
------解决方案--------------------
select isnull(a.姓名,b.姓名) as 姓名, a.成绩 as '5月成绩',b.成绩 as '3月成绩' from a full join b on a.姓名 = b.姓名
------解决方案--------------------
SELECT a.编号,a.姓名,a.成绩 AS [5月成绩],b.成绩 AS [3月成绩]
FROM A AS a JOIN B AS b ON a.编号=b.编号
------解决方案--------------------