Dear All,
My code doesn't work as intended. What I want to do is to save two results in ODS DOCUMENT named temporary and to recall them later by using PROC DOCUMENT.
When I run the code once, it seemed that it worked given that there was no error. PROC DOCUMENT also showed two results from previous PROC PRINT.
But when I run the code again (i.e., twice), PROC DOCUMENT showed "two times" of what I expect to see. It implies that ODS DOCUMENT CLOSE didn't work as I intended. Instead, ODS DOCUMENT seems to keep recording the code that has been executed. Did I do something wrong? Thanks for reading.
ods document name= temporary;
proc print data= sashelp.cars (obs= 10); run;
proc print data= sashelp.stocks (obs= 10);run;
ods document close;
proc document name= temporary; replay; run; quit;
Use the WRITE access option.
When I run your code:
ods document name=temporary;
proc print data= sashelp.cars (obs=10);
run;
proc print data= sashelp.stocks (obs=10);
run;
ods document close;
proc document name=temporary;
replay;
run;
quit;
repeatedly, I always get the same output: PRINT for cars and stocks from the original call, and then again from the REPLAY.
Cancel the above; I had only the PROC DOCUMENT marked when hitting "submit".
SIG_NOT_ENOUGH_COFFEE.
Nearly 200 sessions are now available on demand with the SAS Innovate Digital Pass.
Explore Now →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.
Ready to level-up your skills? Choose your own adventure.