data one;
input id Address $5-42 ;
cards;
101 Murphy’s Sports 115 Main St.
102 Sun N Ski 2106 Newberry Ave.
103 Sports Outfitters 19 Cary Way
104 Cramer & Johnson 4106 Arlington Blvd.
105 Sports Savers 2708 Broadway
data two;
input id Order;
cards;
102 562.01
104 254.98
104 1642.00
101 3497.56
102 385.30
;
proc sort data=two;
by id;
data three;
merge one two (in=b);
by id;
if b=0;
proc print ;
run;
Hi Devarayalu..
bellow code is alternative for the above data step..
Proc SQL ;
Create Table AntiJoin As
Select *
From One a
Left Join
Two b
On a.id =b.id
Where Missing( b.id ) ;
Quit ;
Regards..
Sanjeev.K
Hi Devarayalu..
bellow code is alternative for the above data step..
Proc SQL ;
Create Table AntiJoin As
Select *
From One a
Left Join
Two b
On a.id =b.id
Where Missing( b.id ) ;
Quit ;
Regards..
Sanjeev.K
Hi Sanjeev.K
This is left join, but i want all from one except b. Please run the data step once.
Thank you
Sorry u are correct......
Hmm Good..
Just Make my answer as a Correct Answer..That would be Great for me..:-)
Regards.
Sanjeev.K
Hi..
But You put the condition as IF b=0,
which means you are taking ID's those are present in ONE but Not in TWO.
Just run your data step and SQL query which i have provided....You will get same result...
Regards..
Sanjeev.K
Don't miss out on SAS Innovate - Register now for the FREE Livestream!
Can't make it to Vegas? No problem! Watch our general sessions LIVE or on-demand starting April 17th. Hear from SAS execs, best-selling author Adam Grant, Hot Ones host Sean Evans, top tech journalist Kara Swisher, AI expert Cassie Kozyrkov, and the mind-blowing dance crew iLuminate! Plus, get access to over 20 breakout sessions.
Use this tutorial as a handy guide to weigh the pros and cons of these commonly used machine learning algorithms.
Find more tutorials on the SAS Users YouTube channel.