sushe1527 发表于 2010-5-26 20:52 
是谁告诉你不能写 * 呢?
data x;
input a b c;
cards ;
20090202 2 4
20090404 4 5
;run;
data y;
input a g k;
cards;
20090303 2 5
20090202 2 6
20090404 5 7
;run;
proc sql;
create table a_new as
select x.*, y.*
from x,y where x.a=y.a
;
quit;
你这样写的话由于两个表里都有变量a, 系统就会报错,只能取一个a, 你运行一下程序就知道了。
假如我取了y里的a,这时y里剩下的变量怎么表示呢?只能一个一个列出来。