Usually the reason for finding more LINES in a text file than you thought were written to the file is because one or more of the variables written to the file contained end of line characters in them.
Sometimes you can solve this easily in SAS by using the TERMSTR= option of the INFILE statement. But that only works when the real end of lines are marked by CRLF combination and the embedded character strings only contain single CR or single LF characters. In that case you can use TERMSTR=CRLF on the INFILE statement. Try it
infile 'imported_file' truncover lrecl = 923 termstr=crlf ;
Another possibility suggested by you use of the LRECL= option set to such a strange number is that perhaps you did the same thing when writing the file but some of the lines being written needed more than 923 characters. That would have caused SAS to move to a new line when writing those values.
You can use the LENGTH= infile option if you want to try and do some analysis on the lengths of the lines in your text file.
data lengths;
infile 'imported_file' length=ll;
input;
row+1;
length=ll;
run;
proc means n min max mean;
var length;
run;
... View more