Select the best answer
for each question. Check your answers using the answer key in the
appendix.
-
Suppose you have submitted
a SAS program that contains spelling errors. Which set of steps should
you perform, in the order shown, to revise and resubmit the program?
-
What happens if you
submit the following program?
proc sort data=cert.stress out=maxrates;
by maxhr;
run;
proc print data=maxrates label double noobs;
label rechr='Recovery Heart Rate;
var resthr maxhr rechr date;
where toler='I' and resthr>90;
sum fee;
run;
-
SAS log messages indicate
that the program ran successfully.
-
A log message might
indicate an error in a statement that seems to be valid.
-
A SAS log message indicates
that an option is not valid or not recognized.
-
A SAS log message might
indicate that a quoted string has become too long or that the statement
is ambiguous.
-
What generally happens
when a syntax error is detected?
-
SAS continues processing
the step.
-
SAS continues to process
the step, and the SAS log displays messages
about the error.
-
SAS stops processing
the step in which the error occurred, and the SAS log displays
messages about the error.
-
SAS stops processing
the step in which the error occurred, and the Output window
displays messages about the error.
-
A syntax error occurs
during the following actions:
-
Some data values are
not appropriate for the SAS statements that are specified in a program.
-
The code executes successfully,
but produces incorrect results.
-
Program statements do
not conform to the rules of the SAS language.
-
-
How can you tell whether
you have specified an invalid option in a SAS program?
-
A SAS log message indicates
an error in a statement that seems to be valid.
-
A SAS log message indicates
that an option is not valid or not recognized.
-
You cannot tell until
you view the output from the program.
-
-
Which of the following
programs contains a syntax error?
-
proc sort data=cert.mysales;
by region;
run;
-
data=work.mysales;
set cert.sales17;
where sales<5000;
run;
-
proc print data=work.mysales label;
label region='Sales Region';
run;
-
-
What are the temporary
variables that can be helpful when debugging a DATA step?
-
When the source of the
errors in the program is not apparent, which statement or statements
can you use to examine errors and print messages to the log?
-
What types of errors
can the PUTLOG statement help you resolve?