Stored Workflow Documentation (from Fraktal SAS Programming)

Aus phenixxenia.org
Version vom 15. Mai 2014, 10:48 Uhr von Wolf-Dieter Batz (Diskussion | Beiträge) (Die Seite wurde neu angelegt: „== Scenario == There's many occasions where direct output to the LOG window is convenient and a matter of time-saving. In a validated and highly automated env…“)
(Unterschied) ← Nächstältere Version | Aktuelle Version (Unterschied) | Nächstjüngere Version → (Unterschied)
Zur Navigation springen Zur Suche springen

Scenario

There's many occasions where direct output to the LOG window is convenient and a matter of time-saving. In a validated and highly automated environment, this advantage does not count, since every un-controlled performed user action immediately harms validation and leaves behind un-documented, hence, un-trackable results.

With respect to this the professional SAS user is offered means to store LOG information in general as well as Generated Code as intermediate results in cases when macro programming is applied. As already seen from other examples, SAS provides a wide variety of options to write any type of results to an external location.

At this point we will examine two of them.


Stored LOG text

Since program flow is documented in the LOG window of an interactive SAS session, it should be as simple as redirecting this data stream to a text file. And indeed, PROC PRINTTO does exactly this:

/*
Switch on
*/
proc printto LOG = "C:\TEMP\MyLOG.txt"; 
run;
/*
Switch off
*/
proc printto LOG = LOG; 
run;

Pretty easy, isn't it?

Of course, any OS path is valid here, moreover, if a structured repository is intended for documentation, automatic variables like &SYSTIME., &SYSDATE., &SYSUID. or others might occur in the filename(s) used.


Stored Generated Code