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 (June 2000, week 1)Back to main SAS-L pageJoin or leave SAS-L (or change settings)ReplyPost a new messageSearchProportional fontNon-proportional font
Date:   Wed, 7 Jun 2000 17:07:53 -0600
Reply-To:   Jamil Ibrahim <jibrahim@IR.UMSMED.EDU>
Sender:   "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From:   Jamil Ibrahim <jibrahim@IR.UMSMED.EDU>
Subject:   not initialized first.idd
Comments:   To: SAS-L@UGA.CC.UGA.EDU, Jamil Ibrahim <JIbrahim@umsmed.edu>
Content-Type:   text/plain; charset=US-ASCII

hi sas users: what is the problem here and how to fix it .

I want to assign a unique number by using a newly created var called idd. I enclose the log: 80 options nodate nonumber ; 81 dm "log;clear;out;clear" 81 ; 82 DATA srf1 ; 83 INFILE "c:\SONTEMP\cospr0.srf" lrecl=1000 MISSOVER pad ; Q+1; 84 85 INPUT @3 (Q1-Q3) ($1.) 86 @9 (Q4-Q6) ($1.) 87 @15 (Q7-Q9) ($1.) 88 @21 (Q12-Q15) ($1.) 89 @28 (Q10-Q11) ($1.) 90 @33 SEM $1. 91 @37 YR $1. 92 @41 CRSNUM $3. 93 @47 ID $5. 94 @55 CRSPRE $1. ; 95 RETAIN IDD ; 96 IF _N_ LT 9 THEN DELETE; 97 IDD=CRSPRE||CRSNUM||ID;

NOTE: The infile "c:\SONTEMP\cospr0.srf" is: FILENAME=c:\SONTEMP\cospr0.srf, RECFM=V,LRECL=1000

NOTE: 1007 records were read from the infile "c:\SONTEMP\cospr0.srf". The minimum record length was 19. The maximum record length was 327. NOTE: The data set WORK.SRF1 has 999 observations and 22 variables. NOTE: The DATA statement used 0.17 seconds.

98 DATA SRF2;SET SRF1; 99 KEEP Q1-Q15 SEM YR CRSNUM ID CRSPRE IDD RECNO; 100 RECN0=300; 101 IF FIRST.IDD THEN DO;RECNO+1; END; 102 FILE "C:\SONTEMP\MRGCODAT.DAT" ; 103 put @1 (q1-q15) ($1.) @18 crsnum $char3. @21 id $char5. 104 @26 crspre $char1. @27 idd $char9. @36 recno 3. ; 105 106 107 RUN;

NOTE: Variable FIRST.IDD is uninitialized. NOTE: The file "C:\SONTEMP\MRGCODAT.DAT" is: FILENAME=C:\SONTEMP\MRGCODAT.DAT, RECFM=V,LRECL=256

NOTE: 999 records were written to the file "C:\SONTEMP\MRGCODAT.DAT". The minimum record length was 38. The maximum record length was 38. NOTE: The data set WORK.SRF2 has 999 observations and 22 variables. NOTE: The DATA statement used 0.11 seconds.


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