BookmarkSubscribeRSS Feed
🔒 This topic is solved and locked. Need further help from the community? Please sign in and ask a new question.
DPraba79
Calcite | Level 5

Hi All,

   I have a tab delimited data file, When i try to read that file, its not reading until the end of the file. I found there is one junk value in my file. The program is reading up to that record and it says end of file reached. I guess, SAS thinks that junk character as end of file character. Do you guys know how to over come this situation.

DATA DATA1;

   INFILE file1 dlm='09'x dsd termstr=CRLF;

   INPUT COL1               : $CHAR20.

         COL2            : $CHAR20.

         COL3            : $CHAR20.

         COL4           : $CHAR20.        

  ;

RUN;

at 1071th record has that junk value in COL3 posistion. But this program read until 1071th obs COL1 & COL2 correctly but COL3 & COL4 say blanks. Kindly note, my file has almost 1Million records.

Thanks,

Prabakaran

1 ACCEPTED SOLUTION

Accepted Solutions
art297
Opal | Level 21

Try adding one more option onto your infile statement, namely:

  ignoredoseof

View solution in original post

2 REPLIES 2
art297
Opal | Level 21

Try adding one more option onto your infile statement, namely:

  ignoredoseof

DPraba79
Calcite | Level 5

Wow Arthur.. That option is working. I appreciate your help.

sas-innovate-2024.png

Don't miss out on SAS Innovate - Register now for the FREE Livestream!

Can't make it to Vegas? No problem! Watch our general sessions LIVE or on-demand starting April 17th. Hear from SAS execs, best-selling author Adam Grant, Hot Ones host Sean Evans, top tech journalist Kara Swisher, AI expert Cassie Kozyrkov, and the mind-blowing dance crew iLuminate! Plus, get access to over 20 breakout sessions.

 

Register now!

How to Concatenate Values

Learn how use the CAT functions in SAS to join values from multiple variables into a single value.

Find more tutorials on the SAS Users YouTube channel.

Click image to register for webinarClick image to register for webinar

Classroom Training Available!

Select SAS Training centers are offering in-person courses. View upcoming courses for:

View all other training opportunities.

Discussion stats
  • 2 replies
  • 1043 views
  • 0 likes
  • 2 in conversation