Hello
I want to see all data sets and views in library R_R
I want to order them by file size.
I run this code but in output it is not so clear what is file size because the numbers are with E format
proc sql;
title 'All Tables and Views in the SQL Library';
select libname, memname, memtype, nobs, filesize
from dictionary.tables
where libname='R_R'
order by filesize desc
;
quit;
Use the SIZEKMG Format
Do you mean
put(filesize,sizekmg.) as filesize
It looks great now!!!
proc sql;
title 'All Tables and Views in the SQL Library';
select libname, memname, memtype, nobs,
put(filesize,sizekmg.) as filesize
from dictionary.tables
where libname='R_R'
order by filesize desc
;
quit;
April 27 – 30 | Gaylord Texan | Grapevine, Texas
Walk in ready to learn. Walk out ready to deliver. This is the data and AI conference you can't afford to miss.
Register now and save with the early bird rate—just $795!
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.
Ready to level-up your skills? Choose your own adventure.