Date: Thu, 9 Nov 2006 14:32:40 +0000
Reply-To: toby dunn <tobydunn@HOTMAIL.COM>
Sender: "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From: toby dunn <tobydunn@HOTMAIL.COM>
Subject: Re: newbi - anybody see anything wrong with this?
In-Reply-To: <4B143AC8A58A0A42AC375A11B459CAE6033EA47C@GNBEX03.gnb.ca>
Content-Type: text/plain; format=flowed
Well its a lot of unneeded code:
Try this:
LibName Report "C:\Transition Files" ;
Data Report.DM_IncidenceSummaryRates ;
Set Report.DM_IncidenceSummaryRates ;
Where Geo_Location In ( 313 714 803 815 820 923 925 934
935 944 947 1019 1034 1035 1105
1207 1320 1410 1510 ) ;
Run ;
Toby Dunn
Quickly, bring me a beaker of wine, so that I may wet my mind and say
something clever.
Aristophanes
Wise people, even though all laws were abolished, would still lead the same
life.
Aristophanes
You should not decide until you have heard what both have to say.
Aristophanes
From: "Beaulieu, Serge (DHW/SME)" <Serge.Beaulieu@GNB.CA>
Reply-To: "Beaulieu, Serge (DHW/SME)" <Serge.Beaulieu@GNB.CA>
To: SAS-L@LISTSERV.UGA.EDU
Subject: newbi - anybody see anything wrong with this?
Date: Thu, 9 Nov 2006 09:54:12 -0400
Hi Listees,
Sorry to be back again so soon with what is likely an idiot question
from this local village idiot - but please indulge me.
I have a bunch of records in a sas table. I want to delete all the
records where geo_location isn't one of the values below. Any ideas as
to what I am doing wrong here or should I be doing this through proc sql
or what?
LIBNAME report "C:\Transition Files";
data report.dm_incidencesummaryrates; set
report.dm_incidencesummaryrates;
if ((geo_location ^= 313) or (geo_location ^= 714) or
(geo_location ^=803) or (geo_location ^= 815) or
(geo_location ^= 820) or (geo_location ^= 923) or
(geo_location ^= 925) or (geo_location ^= 934) or
(geo_location ^= 935) or (geo_location ^= 944) or
(geo_location ^= 947) or (geo_location ^= 1019) or
(geo_location ^= 1034) or (geo_location ^= 1035) or
(geo_location ^= 1105) or (geo_location ^= 1207) or
(geo_location ^= 1320) or (geo_location ^= 1410) or
(geo_location ^= 1510)) then delete; run;
Serge (local village idiot - loose on sas-l)
_________________________________________________________________
Find a local pizza place, music store, museum and more…then map the best
route! http://local.live.com?FORM=MGA001