When SAS reads multiple
records to create a single observation, it does not discover that
a record is missing until it reaches the end of the data. If there
is a missing record in your data, the values for subsequent observations
in the SAS data set might be incorrect. Using LOSTCARD prevents SAS
from reading a record from the next group when the current group has
fewer records than SAS expected.
LOSTCARD is most useful
when the input data have a fixed number of records per observation
and when each record for an observation contains an identification
variable that has the same value. LOSTCARD usually appears in conditional
processing such as in the THEN clause of an IF-THEN statement, or
in a statement in a SELECT group.