03-20-2013 08:14 AM
How do I Join 2 datasets WITHOUT a BY variables? I have a file of ZIP Codes 30,000 observations named work.ZIP. I want to horizontally add 100 variables from table WORK.DATA with 1 observation and 9 variables. How do I get the 9 variables from WORK.DATA and copy for all 30,000 ZIP codes without a common BY field to JOIN? Any suggestions? THANK YOU!
proc print data=WORK.ZIP (obs=12)
WORK.DATA (doesn't have a ZIP Code to join with WORK.ZIP)
proc print data=WORK.DATA
03-20-2013 08:25 AM
You could of course do a merge without a BY statement, or you could try something with a SET statement, like
if _n_=1 then set data;
but ... since I can't visualize the end result you want, nor can I figure it out from your words, I would like to see an example of the final merged data set you would like to have.