Date: Fri, 7 Nov 2008 11:23:54 -0500
Reply-To: "Lane, Jim" <jim.lane@RBC.COM>
Sender: "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From: "Lane, Jim" <jim.lane@RBC.COM>
Subject: Re: what is the most effective way to remove observation with
duplicate key?
In-Reply-To: A<gf1jh6$5fo$1@aioe.org>
Content-Type: text/plain; charset="iso-8859-1"
Kevin: I'm not sure that it's logically possible to remove duplicates
without sorting data somewhere along the line. You can use SELECT
DISTINCT in PROC SQL but that will sort the data under the covers if it
isn't sorted already. If you try to use SET BY and FIRST.key in a DATA
step SAS will require you to have the data sorted beforehand.
In general sorting is either expensive or inexpensive depending on how
much data you have. Sometimes it's just a cost of doing business.
FWIW
Jim Lane
-----Original Message-----
From: SAS(r) Discussion [mailto:SAS-L@LISTSERV.UGA.EDU] On Behalf Of
kwu0914
Sent: 2008, November, 07 9:32 AM
To: SAS-L@LISTSERV.UGA.EDU
Subject: what is the most effective way to remove observation with
duplicate key?
All SAS_L users, what is your commom way to do that?
Is there a effective way without requiring sorting to do it since we all
konw sorting is a expensive operation?
or can you refer any paper which is foucs on this aspect?
Thanks!
Kevin
_______________________________________________________________________
This e-mail may be privileged and/or confidential, and the sender does not waive any related rights and obligations.
Any distribution, use or copying of this e-mail or the information it contains by other than an intended recipient is unauthorized.
If you received this e-mail in error, please advise me (by return e-mail or otherwise) immediately.
Ce courrier électronique est confidentiel et protégé. L'expéditeur ne renonce pas aux droits et obligations qui s'y rapportent.
Toute diffusion, utilisation ou copie de ce message ou des renseignements qu'il contient par une personne autre que le (les) destinataire(s) désigné(s) est interdite.
Si vous recevez ce courrier électronique par erreur, veuillez m'en aviser immédiatement, par retour de courrier électronique ou par un autre moyen.