全部版块 我的主页
论坛 数据科学与人工智能 数据分析与数据科学 SAS专版
1275 1
2016-07-14
63题中的第55题,如果改为

dataone;

inputyear qtr budget;

cards;

2001 3 500

2001 4 400

2003 1 350

;

run;

datatwo;

inputyear qtr sales;

cards;

2001 4 300

2002 1 600

;

run;



proc sql;

select one.*, sales from work.two left join work.one

on one.year=two.year;

quit;

问:left join是先把符合match条件的row拿出来,加上table one不符合条件的row也拿出来。那为何没有2003 1 350这条呢?

[td]
yearqtrbudgetsales
20013500300
20014400300
...600

二维码

扫码加我 拉你入群

请注明:姓名-公司-职位

以便审核进群资格,未注明则拒绝

全部回复
2016-7-15 00:53:28
明白了,left join retrieves all rows that match across tables, based on the specified matching criteria (join conditions), plus nonmatching rows from the left table (the first table specified in the FROM clause).
二维码

扫码加我 拉你入群

请注明:姓名-公司-职位

以便审核进群资格,未注明则拒绝

栏目导航
热门文章
推荐文章

说点什么

分享

扫码加好友,拉您进群
各岗位、行业、专业交流群