SAS数据集取前N条记录
方法一:
data temp1;
set sashelp.air(firstobs=n obs=n/obs=n);
run;
/*firstobs.n < obs.n*/
方法二:
proc sql;
create table temp2 as
select * from sashelp.air(firstobs=n obs=n/obs=n);
quit;
/*firstobs.n < obs.n*/
方法三:
proc sql inobs=n;
create table temp3 as
select * from sashelp.air;
quit;
方法四:
proc sql outobs=n;
create table temp4 as
select * from sashelp.air;
quit;