Date: Tue, 9 Jun 2009 00:14:16 +0800
Reply-To: shao xiaolong <sxlion2@GMAIL.COM>
Sender: "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From: shao xiaolong <sxlion2@GMAIL.COM>
Subject: Re: Code help to Compare two data sets and remove records that
match
In-Reply-To: <a278967a-7a22-4a01-8aa9-14c74cd61ded@r34g2000vba.googlegroups.com>
Content-Type: text/plain; charset=ISO-8859-1
proc sql;
select cust_id from temp
except
select cust_id from temp1
;
quit;
On Mon, Jun 8, 2009 at 10:47 PM, sasbegy <pattukuttani@gmail.com> wrote:
> Hi,
>
> I need help to perform the following operation. I want to compare two
> data sets and remove the rows from data set 1 which matches with data
> set 2.
>
> data set 1
>
> data set name :Temp
>
> variable :cust_id
>
> 111
> 222
> 333
> 444
> 555
> 666
>
> data set 2
>
> data set name :Temp1
>
> variable :cust_id
>
> 222
> 333
>
>
> data set want
>
> data set name :Temp3
>
> variable :cust_id
>
> 111
> 444
> 555
> 666
>
>
> Any small help is much appreciated
>
|