diff --git a/all.sas b/all.sas index 80c260a..6c87bb8 100644 --- a/all.sas +++ b/all.sas @@ -2936,20 +2936,24 @@ run; %mend;/** @file @brief Drops tables / views (if they exist) without warnings in the log - @details + @details Useful for dropping tables when you're not sure they exist, or if + you are not sure whether they are a dataset or view. Also efficient for + dropping multiple tables / views. + Example usage: proc sql; create table data1 as select * from sashelp.class; create view view2 as select * from sashelp.class; - %mp_dropmembers(list=data1 view2) + %mp_dropmembers(libref=WORK, list=data1 view2) +

SAS Macros

@li mf_isblank.sas - @param list space separated list of datasets / views - @param libref= can only drop from a single library at a time + @param list space separated list of datasets / views, WITHOUT libref + @param libref= (WORK) Note - you can only drop from a single library at a time @version 9.2 @author Allan Bowe @@ -2970,7 +2974,7 @@ run; delete &list; delete &list /mtype=view; run; -%mend;/** +%mend mp_dropmembers;/** @file @brief Create a CARDS file from a SAS dataset. @details Uses dataset attributes to convert all data into datalines. diff --git a/base/mp_dropmembers.sas b/base/mp_dropmembers.sas index a62d352..014d67b 100755 --- a/base/mp_dropmembers.sas +++ b/base/mp_dropmembers.sas @@ -1,20 +1,24 @@ /** @file @brief Drops tables / views (if they exist) without warnings in the log - @details + @details Useful for dropping tables when you're not sure they exist, or if + you are not sure whether they are a dataset or view. Also efficient for + dropping multiple tables / views. + Example usage: proc sql; create table data1 as select * from sashelp.class; create view view2 as select * from sashelp.class; - %mp_dropmembers(list=data1 view2) + %mp_dropmembers(libref=WORK, list=data1 view2) +

SAS Macros

@li mf_isblank.sas - @param list space separated list of datasets / views - @param libref= can only drop from a single library at a time + @param list space separated list of datasets / views, WITHOUT libref + @param libref= (WORK) Note - you can only drop from a single library at a time @version 9.2 @author Allan Bowe @@ -35,4 +39,4 @@ delete &list; delete &list /mtype=view; run; -%mend; \ No newline at end of file +%mend mp_dropmembers; \ No newline at end of file