To submit your program to
the batch queue, you can use the
batch
,
at
,
nohup
,
or
cron
commands. For example, you could
submit
weekly.sas
from your shell prompt
as follows:
$ at 2am
sas weekly.sas
<control-D>
warning: commands will be executed using /usr/bin/sh
job 8400.a at Wed Mar 16 02:00:00 2011
$
If you create a file that contains the SAS command
(for example,
cmdfile.sh
) that is necessary
to run your program, then you can enter the following command at your
shell prompt:
at 2am < cmdfile.sh
SAS
sends the output to a file that has the same name as the program.
The output file has an extension of .lst. The log file writes to a
file with an extension of .log. Both of these files are written to
your current directory. Refer to the UNIX man pages for these commands
for more information about submitting jobs to the batch queue. For
more information about routing output, see
Printing and Routing Output.
If you submit a file
in batch mode, then a line that is greater than 256 bytes will be
truncated. An explicit message about this truncation is written to
the SAS log.
Note: If your program contains
statements that start an interactive procedure such as the FSEDIT
procedure, CATALOG procedure, or the REPORT procedure, you will need
to run your program as a foreground process, or you will need to use
the
–noterminal option.