【发布时间】:2015-03-19 08:25:02
【问题描述】:
我有一个每周四运行的 SAS 作业,但有时它需要在星期三运行,也许是星期二晚上。该作业每隔 4 周收集一些数据,直到最近的星期日。例如,今天我们有 19Mar2015,我需要到 15Mar2015 的数据。
data get_some_data;
set all_the_data;
where date >= '16Feb2015' and date <= '15Mar2015';
run;
下周我也要手动更改日期参数
data get_some_data;
set all_the_data;
where date >= '23Feb2015' and date <= '22Mar2015';
run;
无论如何我可以自动执行此操作?
【问题讨论】:
-
查找
intnx和today函数的文档。