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 (April 2004, week 4)Back to main SAS-L pageJoin or leave SAS-L (or change settings)ReplyPost a new messageSearchProportional fontNon-proportional font
Date:         Mon, 26 Apr 2004 15:02:37 -0400
Reply-To:     "Fehd, Ronald J. (PHPPO)" <rjf2@CDC.GOV>
Sender:       "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
Comments:     cc: jim.groeneveld@VITATRON.COM
From:         "Fehd, Ronald J. (PHPPO)" <rjf2@CDC.GOV>
Subject:      Re: Reverse PROC CONTENTS
Content-Type: multipart/mixed;

Jim: thanx for the nudge of your question so that I could get the code on a page before I actually had to write it myself for my own application:

Ron Fehd the macro maven CDC Atlanta GA USA RJF2@cdc.gov --> cheerful provider of TESTED SAS code from the Clue?Gee!Wrx <--

PROC Format;value $TypeCN 'C'='$' other = ' ';

DATA _Null_; retain header 1; if header then do; call execute('DATA Structure;attrib '); header = 0; end; infile Cards eof = EndoFile; input @1 Name $char8. @12 TypeCN $char1. @14 Length 2. @19 Format $char10. @30 Label $char40. Type = put(TypeCN,$TypeCN.); statement = trim(Name) !! ' length = ' !! trim(Type) !! put(Length,2.) !! ' format = ' !! trim(Format) !! ' label = "' !! trim(Label) !! '"'; call execute(Statement); ;return; EndoFile: call execute(';stop;run;');stop; * + 1 + 2 + 3 + 4 1234567890123456789012345678901234567890;cards; TPEPNum N:4 5. ID-1 TPEP Number BatchNo C:8 $char8. Batch Number MailStat C:2 $char2. USPS Abbreviation for Mailing address. ShipStat C:2 $char2. USPS Abbreviation for Shipping address. Q03LABTP C:1 $q03lt. Primary classification of the laboratory Q04TBYR N:4 q04tbyr. M.tb tests in last calendar year ; run;

%Contents(data = Work.Structure)

> -----Original Message----- > From: Fehd, Ronald J. (PHPPO) > Perhaps the following idea is what is wanted:

> DATA Child; > if 0 then > set <Library.>Structure; > do until(EndoFile); > *set SomeOtherData > end = EndoFile > or > input etc.; > end;%*read loop; > stop;


This e-mail and any files transmitted with it are for the sole use of the intended recipient(s) and may contain confidential and privileged information. If you are not the intended recipient, please contact the sender by reply e-mail and destroy all copies of the original message. Any unauthorised review, use, disclosure, dissemination, forwarding, printing or copying of this email or any action taken in reliance on this e-mail is strictly prohibited and may be unlawful.

Visit us at http://www.cognizant.com


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