I need to get SAS to trigger an error if a certain condition is not meet i have tried to use abort return n, abort abend etc.. but they all seems to to disconnect the entire session where i only want to get an error like with syntax etc.
It is a sas propgram only to be run from SAS-EG in interactive mode with prompts
my code:
DATA _NULL_;
IF prxmatch("/^TBDLZL\d{4}_[A-Z]/",&tablename_in) eq 0 then do;
put "error table name &tablename_in does not match";
ABORT RETURN 15;
END;
RUN;
any suggestions ?