As the first step in the decommissioning of sasCommunity.org the site has been converted to read-only mode.


Here are some tips for How to share your SAS knowledge with your professional network.


PROC Delete

From sasCommunity
Jump to: navigation, search


As part of the decommissioning effort for sasCommunity.org this article/tip has been migrated to communities.sas.com.

The new home for this article/tip is PROC Delete (https://communities.sas.com/t5/SAS-Communities-Library/PROC-Delete/ta-p/475178)



Proc Delete is faster than either Datasets or SQL.

PROC Delete data = Libref.DataName;
 
PROC SQL; drop table Libref.DataName;
          quit;
 
PROC Datasets library = Libref;
              delete    DataName;
run;
 
DATA _Null_;
length dd $8;
rc = filename(dd,cats(pathname('Libref'),'\DataName.sas7bdat'));
rc = fdelete(dd);
put _all_;
run;

Previously.Old.News.Note: Proc Delete is/was officially deprecated; you could not get help from Tech Support about it, prior to 2013.

References

--macro maven == the radical programmer 11:58, 5 January 2009 (EST)