I have a subroutine and it uses "run_macro" expression to execute a macro. But after execution I can't see normal data step execution statistics in the log. Instead of normal log it produces a log like
"NOTE: DATA statement used (Total process time):
real time 0.06 seconds
cpu time 0.09 seconds"
however the macro has data steps more than one. It abriges the log. I need full log.
/*SUBROUTINE DEFINITION*/
subroutine setProcessTime(app $,log $);
%include 'E:\................................\set_process_time.sas';
rc = run_macro('set_process_time', app, log);
endsub;
/*MACRO*/
%macro set_process_time_test;
data messi;
put "SSSSSSSSSSSSSSSSSSS";
a="&log";
b="&app";
run;
data kaka;
a=sleep(3,1);
run;
data carlos;
a=10;
b=15;
run;
%mend set_process_time_test;
best regards
Have you tried the symbolgen and mprint options before you submit the macro code?
options mprint symbolgen notes;
Have you tried the symbolgen and mprint options before you submit the macro code?
options mprint symbolgen notes;
I have tried , but it doesn't work. Log is here...
10310 options cmplib = (ud.user_defined);
10311 data _null_;
10312 call setProcessTime('D:\....\include_by_fcmp_sample.sas','D:\....\include_by_fcmp_sample_log.txt');
10313 run;
YYYYYYYYYYYYYYYYYYY
SYMBOLGEN: Macro variable LOG resolves to 'D:\..........\include_by_fcmp_sample_log.txt'
'D:\.......\include_by_fcmp_sample_log.txt'
MPRINT(SET_PROCESS_TIME): data sss;
MPRINT(SET_PROCESS_TIME): put "SSSSSSSSSSSSSSSSSSS";
MPRINT(SET_PROCESS_TIME): a=5;
MPRINT(SET_PROCESS_TIME): run;
SSSSSSSSSSSSSSSSSSS
SYMBOLGEN: Macro variable LOG resolves to 'D:\......\include_by_fcmp_sample_log.txt'
MPRINT(SET_PROCESS_TIME): filename rlog "'D:\.....\include_by_fcmp_sample_log.txt'";
MPRINT(SET_PROCESS_TIME): proc printto new log=rlog;
MPRINT(SET_PROCESS_TIME): run;
SYMBOLGEN: Macro variable START resolves to 1664269555.661
SYMBOLGEN: Macro variable FINISH resolves to 1664269555.698
MPRINT(SET_PROCESS_TIME): proc sql;
SYMBOLGEN: Macro variable APP resolves to 'D:\.....\include_by_fcmp_sample.sas'
SYMBOLGEN: Macro variable START resolves to 1664269555.661
SYMBOLGEN: Macro variable FINISH resolves to 1664269555.698
SYMBOLGEN: Macro variable PROCESS_TIME resolves to İşlem süresi 0.0369999409 milisaniye
MPRINT(SET_PROCESS_TIME): insert into prcstime.construction_process_times values('D:\.....\include_by_fcmp_sample.sas',1664269555.661,1664269555.698,"İşlem süresi
0.0369999409 milisaniye");
MPRINT(SET_PROCESS_TIME): run;
NOTE: DATA statement used (Total process time):
real time 0.04 seconds
cpu time 0.04 seconds
I have made a mistake , you were right , notes options has to be set : )
thanks...
Don't miss out on SAS Innovate - Register now for the FREE Livestream!
Can't make it to Vegas? No problem! Watch our general sessions LIVE or on-demand starting April 17th. Hear from SAS execs, best-selling author Adam Grant, Hot Ones host Sean Evans, top tech journalist Kara Swisher, AI expert Cassie Kozyrkov, and the mind-blowing dance crew iLuminate! Plus, get access to over 20 breakout sessions.
Learn how use the CAT functions in SAS to join values from multiple variables into a single value.
Find more tutorials on the SAS Users YouTube channel.