LISTSERV at the University of Georgia
Menubar Imagemap
Home Browse Manage Request Manuals Register
Previous messageNext messagePrevious in topicNext in topicPrevious by same authorNext by same authorPrevious page (July 2001, week 1)Back to main SAS-L pageJoin or leave SAS-L (or change settings)ReplyPost a new messageSearchProportional fontNon-proportional font
Date:         Tue, 3 Jul 2001 15:22:03 -0400
Reply-To:     Crystal Vierhout <vierhout@UNITY.NCSU.EDU>
Sender:       "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From:         Crystal Vierhout <vierhout@UNITY.NCSU.EDU>
Subject:      Index with a key read
Content-Type: multipart/alternative;

Hello again,

Thanks for everyone help on the key label question. After I tried the code of Mike Zdeb which worked great.

data save.cohorts; set group(keep=herdcode string); set nowrite.history1 key=herd / unique; select (_iorc_); when (%sysrc(_sok)) output; when (%sysrc(_dsenom)) _error_ = 0; otherwise do; put "UNEXPECTED ERROR"; stop; end; end; run;

BUT I think I may have set this up wrong initally. Below is what I need the code to do but I need something different that is going to run a lot faster than a merge for our web program. I thought first an index key read but that seems to only get me one observation. What the most efficient way to get the same result of the below code but in half the time?

data allwrite.cohorts;

merge group(keep=herdcode string) nowrite.history1 (in=a);

by herdcode string; if a;

run;

Crystal Vierhout Dairy Records Management Systems


[text/html]


Back to: Top of message | Previous page | Main SAS-L page