If you are using the sasbatch.bat file to execute SAS batch jobs, all this file is doing is calling sas.exe with some options, one of which might be the -LOG option to specify the name and location of the SAS log file. It's the SAS executable that is creating and locking the log file, not sasbatch.
User said they were using SAS in batch.
There are various ways of invoking SAS in batch mode. You can call the SAS command directly from a command line or via a scheduling tool, run the SAS-provided sasbatch BAT file, or run SAS via a user-written BAT or script file. You will need to provide more details of your problem before we can help.
Are you ready for the spotlight? We're accepting content ideas for SAS Innovate 2025 to be held May 6-9 in Orlando, FL. The call is open until September 25. Read more here about why you should contribute and what is in it for you!
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.