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

Hello,

 

I am encountering an error I have not seen before. I am getting this error after double clicking on the file in my file explorer. I was sent six SAS datasets that are all similar and two of them are producing this error, the others open normally. I have plenty of disk space, have restarted everything and redownloaded the datasets. Any thoughts on what to do? Thank you!

 

smg3141_0-1626791191224.png

 

1 ACCEPTED SOLUTION

Accepted Solutions
Sajid01
Meteorite | Level 14

Datasets may be corrupted as pointed  by @Tom Try repairing the datasets as follows

proc datasets lib=Your_library;
   repair the_corrupt_file;
run;
quit;

Your_library is the libname of the location where corrupt file exists.

the_corrupt_file is the name of the corrupt dataset.

View solution in original post

6 REPLIES 6
ballardw
Super User

Did you assign a library to folder with those data sets before attempting to open them? If not that may help or may allow more options to examine them.

smg3141
Obsidian | Level 7

Thanks for the reply, I hadn't tried that. Still getting the error though. These are the errors I got when I tried to run a proc contents on the file and just double clicking in the file explorer after assigning the library.

 

smg3141_0-1626792617299.png

smg3141_1-1626792636084.png

 

ballardw
Super User

Long shot here: what version of SAS are you running? And is it 32-bit?

 

If you are running SAS 9.3 or earlier it may be having difficulties with reading one of the header record values to accommodate larger data sets.

 

Run this code:

proc options option=extendobscounter;run;

If you get a message that the option doesn't exist (SAS 9.3 and earlier I think) that could be the problem: version of SAS.

If the log shows it is set to NO instead of Yes like this

 EXTENDOBSCOUNTER=YES
                   Specifies whether to extend the maximum number of observations in a new SAS
                   data file.

you might be able to address this problem by setting the sytem option to EXTENDOBSCOUNTER=YES using the Options statement. As I say, this is sort of a long-shot.

 

 

 

 

Tom
Super User Tom
Super User

Usually that means the file is corrupted. Perhaps you copied it from somewhere and only part of the file actually made it.

Sajid01
Meteorite | Level 14

Datasets may be corrupted as pointed  by @Tom Try repairing the datasets as follows

proc datasets lib=Your_library;
   repair the_corrupt_file;
run;
quit;

Your_library is the libname of the location where corrupt file exists.

the_corrupt_file is the name of the corrupt dataset.

smg3141
Obsidian | Level 7
I was able to open the datasets after running this code, but I lost some of the data. I believe the datasets that were sent to me were corrupt on the sender's end. Thanks for your help!

Ready to join fellow brilliant minds for the SAS Hackathon?

Build your skills. Make connections. Enjoy creative freedom. Maybe change the world. Registration is now open through August 30th. Visit the SAS Hackathon homepage.

Register today!
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
  • 6 replies
  • 6094 views
  • 2 likes
  • 4 in conversation