The SAS VSAM interface looks for logical errors before
it invokes VSAM. When SAS detects an error condition, it is a SAS
logical error. When SAS cannot pass a request on to VSAM because
of an error in your program, the DATA step terminates, and an error
message that describes the error is printed on the SAS log. The following
conditions are examples of SAS logical errors:
-
You attempt to update a VSAM data
set without using the same fileref for both the INFILE and FILE statements.
-
You try to erase an ESDS record
by specifying the ERASE= variable on an INFILE statement that references
an ESDS.
-
You try to retrieve a spanned KSDS
record by RBA.
By default, the standard
INFILE statement options MISSOVER and STOPOVER are in effect for VSAM
data sets, and they relate to SAS logical error conditions.
-
The MISSOVER option assigns missing
values to all variables in the INPUT statement that do not have values
in the INPUT buffer.
Note that the MISSOVER
option enables processing to continue instead of terminating the DATA
step.
-
The STOPOVER option is the default
when data overflows the current record when writing to a VSAM data
set. The STOPOVER option causes the following:
-
partially built records to be written
to the data set
-
the DATA step to terminate immediately
with an error message