proc dataset

Accepted Solution Solved
Reply
Valued Guide
Posts: 854
Accepted Solution

proc dataset

I'd like to run a proc datasets lib=XXXX;contents data=_all_;quit;run; but one of the tables is corrupted so it will fail.  I do not want to delete the bad table to get this information.  Is there a way to get this information without going through each table 1 by 1?

Thanks in advance,

Mark


Accepted Solutions
Solution
‎10-16-2014 12:25 PM
Grand Advisor
Posts: 10,211

Re: proc dataset

Another place to look at the information about SAS tables in variables are the DICTIONARY tables available for use in proc sql or the views in SASUSER. I don't know if this has a problem with a corrupted dataset as I don't have one to test with at the moment.

Proc sql;

     create table libcontents as

     select Memname

     from dictionary.members

     where libname='LIBRARY';

quit;

use

Proc SQL;

     describe table dictionary.columns ;/* for variable info or  dictionary.members for dataset info*/

quit;

View solution in original post


All Replies
Valued Guide
Posts: 854

Re: proc dataset

I ended up getting the data from proc datasets lib=xxxx:quit;run;

then putting that into

proc datasets lib=xxxx nolist;contents data= ____;quit;run

using excel's concatenate to list the 400 table names, copy pasted it into SAS, if there are any other options let me know.

Cheers,

Solution
‎10-16-2014 12:25 PM
Grand Advisor
Posts: 10,211

Re: proc dataset

Another place to look at the information about SAS tables in variables are the DICTIONARY tables available for use in proc sql or the views in SASUSER. I don't know if this has a problem with a corrupted dataset as I don't have one to test with at the moment.

Proc sql;

     create table libcontents as

     select Memname

     from dictionary.members

     where libname='LIBRARY';

quit;

use

Proc SQL;

     describe table dictionary.columns ;/* for variable info or  dictionary.members for dataset info*/

quit;

☑ This topic is SOLVED.

Need further help from the community? Please ask a new question.

Discussion stats
  • 2 replies
  • 311 views
  • 4 likes
  • 2 in conversation