Hi All,
We generally create new variables using assignment statement. When the specified variable is not present in the data step we get an uniniitalized note in the SAS log. But the requirement is to generate an ERROR in the log if the specified variable is not present while creating new variable using assignment statement. Any ideas on this.
data want;
set sashelp.class;
new=gender;
run ;
NOTE: Variable gender is uninitialized.
NOTE: There were 19 observations read from the data set SASHELP.CLASS.
NOTE: The data set WORK.WANT has 19 observations and 7 variables.
NOTE: Compressing data set WORK.WANT increased size by 100.00 percent.
Compressed is 2 pages; un-compressed would require 1 pages.