Hi:
It would be better if you could post some of your data, but there are some general things to check for. Consider this "test" data:
[pre]
"id","type","cls_dt"
1,a,11/15/1950
2,b,08/23/1951
3,c,23/8/1951
4,d,11/29/1984
5,e,21Mar2009
6,03/21/2009,f
[/pre]
There's something wrong with ID #3 (the date is NOT MM/DD/YYYY form). Neither is the date for ID #5. Both of those dates are in the wrong form. For ID #6, there's a different problem -- the variable values were entered in the CSV file with CLS_DT and TYPE reversed on the row.
What's going to happen when SAS tries to read this file? Some of the input records will be OK. Some of the input records will generate an error. Here's the LOG that results from trying to read the above file:
[pre]
136 data abc;
137 infile datalines delimiter = ',' MISSOVER DSD firstobs=2 ;
138 informat id $1.type $1. cls_dt mmddyy10.;
139 format id $1. type $1.cls_dt mmddyy10.;
140 input id $ type $ cls_dt ;
141 return;
142 datalines;
NOTE: Invalid data for cls_dt in line 146 5-13.
RULE: ----+----1----+----2----+----3----+----4----+----5----+----6----+----7----+----8----+
146 3,c,23/8/1951
id=3 type=c cls_dt=. _ERROR_=1 _N_=3
NOTE: Invalid data for cls_dt in line 148 5-13.
148 5,e,21Mar2009
id=5 type=e cls_dt=. _ERROR_=1 _N_=5
NOTE: Invalid data for cls_dt in line 149 14-14.
149 6,03/21/2009,f
id=6 type=0 cls_dt=. _ERROR_=1 _N_=6
NOTE: The data set WORK.ABC has 6 observations and 3 variables.
NOTE: DATA statement used (Total process time):
real time 0.01 seconds
cpu time 0.01 seconds
150 ;
151 run;
[/pre]
You can see that I got exactly the same error message as you reported, for the rows in the data, where there was something wrong with CLS_DT. One good diagnostic technique is to visually examine your file, SAS will only report the first 20 or so errors, but you may be able to find out, by examining the log just which rows have the problem.
To fix records #3 and #5, I could go to the CSV file and re-type them to be MMDDYY format and then resave the CSV file. To fix record #6, the entire line needs to be fixed so that TYPE is where SAS expects it and CLS_DT comes after TYPE on the line.
Another way to read all the different date values would be to use the ANYDTDTE informat instead of the MMDDYY10. informat. However, nothing will help you "fix" bad record #6.
An INFORMAT statement tells SAS how to read records INTO SAS format. So, if your data does not correspond to the INFORMAT you specify, SAS has no choice but to issue an error message. The FORMAT statement tells SAS how to display SAS values when they're used by procedures, such as PROC PRINT or PROC FREQ or PROC MEANS, etc, etc. So, for example, the first date on ID #1 is 11/15/1950. This date is "internally" stored in the SAS dataset as -3334, the number of days from Jan 1, 1960. If you wanted to display that value with different DATE formats, that date value can be "formatted" a number of different ways:
15Nov1950 Date9.
11/15/1950 mmddyy10.
11/15/50 mmddyy8.
1950-11-15 yymmdd10.
November 15, 1950 worddate.
On the other hand, your program can only specify one method for how data should be read INTO SAS using an INFORMAT. I suspect the reason you're getting that error is that you have some bad data rows or records in the CSV file. It's entirely possible that not all the CLS_DT variables use the MMDDYY10. INFORMAT for the values.
Scott showed you a good debugging technique. You might read in the documentation about INFORMATs and FORMATs and "cleaning" data. If you cannot edit the data yourself, then you may only be able to report the errors to the people who maintain the file and ask them to do corrections and then send you a corrected file.
Good luck!
cynthia