SPDSUSDS Reserved Macro Variable

When the SPDSUSAV macro variable or UNIQUESAVE= table option is set to YES and an Append or Insert operation is performed on a table that has unique indexes, SPD Server creates a hidden table to store any rows that are rejected because they have duplicate key values. The SPDSUSDS reserved macro variable references this hidden table.
The following example shows how SPDSUSDS is used to access the hidden table.
data employee.names1 (index=(id/unique ));
   input name $ id ;
   list;
   datalines;
Jill 4344
Jack 5589
Jim  8888
Sam  3334
run;

data employee.names2;
   input name $ id;
   list;
   datalines;
Jack  8443
Ann   3334
Sam   8756
Susan 5321
run;

%let SPDSUSAV=YES;
proc append base=employee.names1 data=employee.names2;
run;
proc print data=&spdsusds;
run;
After the update, the log shows the following:
NOTE: Appending EMPLOYEE.NAMES2 to EMPLOYEE.NAMES1.
NOTE: There were 4 observations read from the data set EMPLOYEE.NAMES2.
NOTE: 3 observations added.
NOTE: The data set EMPLOYEE.NAMES1 has 7 observations and 2 variables.
WARNING: Duplicate values not allowed on index id for file EMPLOYEE.NAMES1. (Occurred 1 times.)
NOTE: Duplicate records have been stored in file EMPLOYEE._7296DDD.
The &SPDSUSDS in the PROC PRINT statement refers to the file in the last NOTE.
Last updated: February 8, 2017