如何在SAS中获取sas日期格式"YYYYMM"?
从下面这段代码我得到'2011-11-01'
call symput('me',"'"||put(intnx('month',today(),-1 ),yymmdd10.)||"'");
Run Code Online (Sandbox Code Playgroud)
我想要得到类似的东西:'2011-11'
谢谢
宏版本:
%let date = %sysfunc(today());
%let me = %str(%")%sysfunc(intnx(month,&date,-1),yymmd7.)%str(%");
%put &me;
Run Code Online (Sandbox Code Playgroud)
归档时间: |
|
查看次数: |
33169 次 |
最近记录: |