BookmarkSubscribeRSS Feed
nadra
Calcite | Level 5
Hello,

I am using a macro that generate a huge Log file when excuting on batch mode.

I want to delete the log file.

any help?

Thanks
5 REPLIES 5
Doc_Duke
Rhodochrosite | Level 12
If you don't need it at all, you can use PROC PRINTTO to direct it to the bit bucket.
sbb
Lapis Lazuli | Level 10 sbb
Lapis Lazuli | Level 10
Tell us more about your SAS operating environment (OS, whether SAS is installed locally or on a remote server), and your SAS version as well. And, the recommendation by Doc@Duke is a good one, possibly even providing control to only delete the SAS-generated log file when a good completion occurs, as you choose to determine.

Scott Barry
SBBWorks, Inc.
nadra
Calcite | Level 5
Hello,
thank you for your responses!


SAS 9.1.3 is installed on a remote server. I opearte the program and after I gather the results via filezilla.

in my program I specified this command :
proc printto log='..../myprogram.log' new; run;


but the log file exists again!

what does mean bitbucket? how can I specify a null route when excecuting on a remote server?
data_null__
Jade | Level 19
filename dummy dummy;
proc printto log=dummy;
run;

[pre]
device-type
specifies the type of device or the access method that is used if the fileref points to an input or output device or location that is not a physical file:

DUMMY specifies that the output to the file is discarded.

Tip: Specifying DUMMY can be useful for testing.

[/pre]
sbb
Lapis Lazuli | Level 10 sbb
Lapis Lazuli | Level 10
Consider that you may want to review the SAS log output, so it is possible to generate the SAS log to a file (with PRINTTO), and then if your processing is satisfactory to your liking, then run a post-processing DATA step to delete the file you are using to capture the SAS log, rather than just writing it to a dummy destination. Explore using a SAS DATA step with CALL functions FILEEXIST, FILENAME, and FDELETE, in order to accomplish the special-handling of your generated log file.

The link below is associated with the SAS companion for Windows platform documentation - other similar guides are provided for your operating environment.

Scott Barry
SBBWorks, Inc.

SAS Functions and CALL Routines under Windows
http://support.sas.com/documentation/cdl/en/hostwin/61924/HTML/default/function.htm

sas-innovate-2024.png

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.

 

Register now!

What is Bayesian Analysis?

Learn the difference between classical and Bayesian statistical approaches and see a few PROC examples to perform Bayesian analysis in this video.

Find more tutorials on the SAS Users YouTube channel.

Click image to register for webinarClick image to register for webinar

Classroom Training Available!

Select SAS Training centers are offering in-person courses. View upcoming courses for:

View all other training opportunities.

Discussion stats
  • 5 replies
  • 2368 views
  • 0 likes
  • 4 in conversation