Date: Tue, 9 Oct 2001 14:24:10 -0400
Reply-To: "Fehd, Ronald J." <rjf2@CDC.GOV>
Sender: "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From: "Fehd, Ronald J." <rjf2@CDC.GOV>
Subject: Re: Sort a 8GB data set
Content-Type: text/plain; charset="iso-8859-1"
> From: Rich [mailto:shpzh2000@YAHOO.COM]
> I am working with a 8GB dataset under SAS 8.0 on a Windows NT under
> NTFS sytem. I need to sort the data set according to 2 variables. I
> have 22GB free space in the hard drive. During the sorting, a
> temporary system utility file with size 18GB is created. Then the
> process stopped because of "OUT OF RESOURCE".
>
> What should I do with it? Thanks a lot.
break it into subsets,
sort the subsets
then concatenate back together.
DATA S1 S2 S3 ...;
SET HUGE;
if Var1 eq Value1 then output S1;
else
if Var1 eq Value2 then output S2;
etc.
proc SORT data = S1
by Var2;
proc SORT data = S2
by Var2;
...
DATA SORTED;
set S1 S2 S3;
by Var1;
Ron Fehd the macro maven CDC Atlanta GA USA RJF2@cdc.gov
OpSys: Win_Pro Ver: 8.2
---> cheerful provider of UNTESTED SAS code from the KludgeWrx !*! <---
|