Hi Reeza,
Thanks for your solution. I have created var_list and tried to retain using two ways,
data have;
set have;
retain &var_list.;
run;
but this gives me an error because there is , between variables.
ERROR 22-322: Syntax error, expecting one of the following: a name, a quoted string, a numeric constant, a datetime constant, a missing value, (, -, :, ;, _ALL_, _CHARACTER_, _CHAR_, _NUMERIC_.
ERROR 76-322: Syntax error, statement will be ignored.
second approach i have is using proc sql but get this error in return,
proc sql; create table have2 as select &var_list. from have; quit;
ERROR: The following columns were not found in the contributing tables: area19, area20, area21, area22, area23, area24, area25, bed19, bed20, bed21, bed22, bed23, bed24, bed25, checkin_date_time19, checkin_date_time20, checkin_date_time21, checkin_date_time22, checkin_date_time23, checkin_date_time24, checkin_date_time25, checkout_date_time19, checkout_date_time20, checkout_date_time21, checkout_date_time22, checkout_date_time23, checkout_date_time24, checkout_date_time25, LOS19, LOS20, LOS21, LOS22, LOS23, LOS24, LOS25. NOTE: The SAS System stopped processing this step because of errors.
Is there a way to fix this?
... View more