Tip of the Day:June 18

From sasCommunity
Jump to: navigation, search

sasCommunity Tip of the Day

filename tmpfile temp;
 
data _null_;
    file tmpfile;
    put 'this is a test';
run;
 
data _null_;
    infile tmpfile;
    input;
    put _infile_;
run;

Scenario: You need to create an external file which will only be needed for the duration of the job or session. Don't hard-code an address in the host file system. Instead, use TEMP as your device type and let SAS transparently (1) find "parking space" in the host file system and (2) delete the file at the end of the job/session. Another advantage: This approach is platform-independent.


Submitted By Howles



Feel free to comment on this tip.


Prior tip - Next tip - Random Tip

Submit a Tip