Date: Wed, 7 Oct 1998 10:56:08 +0800
Reply-To: Brenden Bertuola <brenden@DPH.UWA.EDU.AU>
Sender: "SAS(r) Discussion" <SAS-L@UGA.CC.UGA.EDU>
From: Brenden Bertuola <brenden@DPH.UWA.EDU.AU>
Organization: The University of Western Australia
Subject: Re: Top Results Data Set
SS wrote in message <361ACEFA.29844132@mailhost.col.ameritech.net>...
>I want to create a new data set with the top 25 sales people in each
>market.
>
>I tried
> If first.market then do;
> a=_N_+24;
> do until (_N_=a);
> output;
> end;
> end;
>
>What I got was the top performer in each market (only one per market).
>Any help would be appreciated. Thank you.
Try
retain a;
If first.market then a=25;
a-1;
if a>0 then output
Brenden
|