I want to update a protected table. Assume we have two users, and when I want to update the table, I need that second user will not open this table at the same time as me. Therefore I can use proc datasets.
The code looks like this: In the first proc step, I hold dataset_name, to prevent from second user to enter this table.
Then I update the table, and after that, I release the table. Can you see a problem with the code?
proc datasets lib= library_name;
modify dataset_name(pw=password);
quit;
data dataset_name;
set dataset_name dataset_name_new;
run;
proc datasets lib= library_name;
modify dataset_name(pw=password);
quit;