BookmarkSubscribeRSS Feed
makset
Obsidian | Level 7


Hello


How can I split a log file in smaller pieces, when I start my bat program my log file is too large over 1GB.



Thank you for your help.

3 REPLIES 3
ballardw
Super User

Are you looking to do this as part of your batch program?

That can be done with PROC PRINTO;

filename file1 "c:\path\file1.log";

filename file2 "c:\path\file2.log";

<as many as you think you need>

add statements such as this to output data to separate files at strategic points in the program.

Proc Printo log=file1;run;

Proc prinnto; run; will return to default log behavior.

I would also look at what you have that is generating so much output such as options like MPRINT, MLOGIC, SYMBOLGEN,  the value for the ERRORS option and statements such as PUT and %PUT that may be writing to the log.

Ksharp
Super User

You mean split the LOG file while you are running the bat program. Check its parameter ,special for LOG parameter. But I didn't recall if there is such a function.

jakarman
Barite | Level 11

Do not generate that much logging in the SAS-log.

- Needing auditing compliance with SIEM there are better ways.
- Wanting a correct error/warning handling etc. design and do your coding/programming accordingly 

---->-- ja karman --<-----

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
  • 3 replies
  • 1012 views
  • 0 likes
  • 4 in conversation