Search code examples
sassas-macro

clearing a library which is being used for stored compiled SAS macro


I have a program which creates a stored compiled macro in a library using the syntax:

options mstored sasmstore=MyLib; 
%macro MyMac() /store source des='My Macro'; 
  %let x=1;
%mend;

However I cannot seem to re-assign my library (MyLib) afterwards - I get the following message (sas 9.1.3):

ERROR: Unable to clear or re-assign the library MYLIB because it is still in use.
ERROR: Error in the LIBNAME statement.

Can anyone advise?


Solution

  • In SAS 9.3 or higher, you can now clear the libref using the %SYSMSTORECLEAR Statement.