I am trying to pull all the varibales from the subdivisionsort and chartersort data sets yet only keep a couple ultimately but the variable NAME appears in both data sets. I need both of them but I keep getting errors saying that the statement is too ambiguous if I do not specify which data set to pull it from but when I put S. or C. in front of NAME sas says the variable NAME already exists in Realestatefilter. I want to merge them where I am not sure which way is the best way to complete this task but none of the options below are working. Any suggestions would be much appreciated! Thanks!! Proc sql; create table work.Realestatefilter as select S.NAME,C.NAME,APPROVYEAR,JURISDICTION,YEAROPEN,CITY from work.Subdivisionsort as S, work.Chartersort as C where S.APPROVYEAR=C.YEAROPEN; quit; Proc Print data=Realestatefilter; run; Proc sql; create table work.Realestatefilter as select NAME,APPROVYEAR,JURISDICTION,YEAROPEN,CITY from work.Subdivisionsort as S, work.Chartersort as C where S.APPROVYEAR=C.YEAROPEN; quit; Proc Print data=Realestatefilter; run; Proc sql; create table work.Realestatefilter as select * from work.Subdivisionsort (keep=NAME APPROVYEAR JURISDICTION) as S, work.Chartersort (keep= NAME YEAROPEN CITY) as C where S.APPROVYEAR=C.YEAROPEN; quit; Proc Print data=Realestatefilter; run;
... View more