This is a question from the exercises and projects for the little sas book regarding Ch. 3 Exercise 10. The questions asks us to read date as a MMDDYY8. input and print it in MMDDYY10. format. I can read from an external file using infile but using dataline results in invalid data. Thanks in advance.
data sample;
OPTIONS YEARCUTOFF = 1950;
INPUT date MMDDYY8.;
DATALINES;
01/01/1920
;
run;
proc print data = sample;
format date MMDDYY10.;
RUN:
SAS log reads :
NOTE: Invalid data for date in line 173 1-12.
RULE: ----+----1----+----2----+----3----+----4----+----5----+----6----+----7----+----8----+----9----+----0
173 CHAR ..01/01/1920
date=. _ERROR_=1 _N_=1
NOTE: The data set WORK.SAMPLE has 1 observations and 1 variables.
NOTE: DATA statement used (Total process time):
real time 0.00 seconds
cpu time 0.02 seconds
datalines
. Are any of them indented with two leading spaces ? - Richard