【sas proc sql】coalesce
1 data mylearn.coalesce; 2 input a $ 1-1 b $ 3-3; 3 datalines; 4 a e 5 b 6 c f 7 d g 8 h 9 ; 10 run; 11 proc sql feedback; 12 select coalesce(a,b) from mylearn.coalesce; 13 quit; 14 proc print data=mylearn.coalesce; 15 run;
coalesce函数返回参数里面的第一个非空值。