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 (August 2007, week 3)Back to main SAS-L pageJoin or leave SAS-L (or change settings)ReplyPost a new messageSearchProportional fontNon-proportional font
Date:         Fri, 17 Aug 2007 14:16:47 +0000
Reply-To:     toby dunn <tobydunn@HOTMAIL.COM>
Sender:       "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From:         toby dunn <tobydunn@HOTMAIL.COM>
Subject:      Re: external file name problem
Comments: To: kid20100@GMAIL.COM
In-Reply-To:  <>
Content-Type: text/plain; format=flowed

Vince ,

The problem is you broke up ia perfectly good data set for no good reason. SAS can use by group processing ( Ie. By Statements ). This means you can keep your data together in one program and then use that in say a proc Report or Tabulate or etc.... and produce different reports for different people or what eveyr group you like.

Toby Dunn

Two wrongs are only the beginning.

Success always occurs in private and failure in full view.

Experience is something you don't get until just after you need it.

From: vince dubois <kid20100@GMAIL.COM> Reply-To: vince dubois <kid20100@GMAIL.COM> To: SAS-L@LISTSERV.UGA.EDU Subject: Re: external file name problem Date: Fri, 17 Aug 2007 07:09:50 -0700

well, here is what i did :

%macro cut_fi ; %do i=&prem_fic %to &memcount; /*first file to analyse to total number of file*/ %do j=1 %to &&NLOBS&i; /* 1 to nb of patients */

data cut&i&j ; infile "U:\testfin\Resutext00&i..txt" lrecl=200 truncover scanover pad; retain fileno 1; length line $ 200; input line $ 1-200 @@; if substr(line, 1, 15) = 'FIN then fileno+1; else if fileno = &j then output cut&i&j; input; drop fileno; run; data nfic_pat&i&j; file "U:\testfin\Resutext00&i..txt"; set cut&i&j; put @1 line $char100.; run; %end; %end; %mend cut_fi; %cut_fi ;

_________________________________________________________________ Booking a flight? Know when to buy with airfare predictions on MSN Travel.

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