LISTSERV at the University of Georgia
Menubar Imagemap
Home Browse Manage Request Manuals Register
Previous (more recent) messageNext (less recent) messagePrevious (more recent) in topicNext (less recent) in topicPrevious (more recent) by same authorNext (less recent) by same authorPrevious page (January 2006, week 3)Back to main SAS-L pageJoin or leave SAS-L (or change settings)ReplyPost a new messageSearchProportional fontNon-proportional font
Date:         Mon, 16 Jan 2006 09:49:23 -0800
Reply-To:     notawahoo@GMAIL.COM
Sender:       "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From:         notawahoo@GMAIL.COM
Organization: http://groups.google.com
Subject:      Re: List DD names for concatenated files
Comments: To: sas-l@uga.edu
Content-Type: text/plain; charset="iso-8859-1"

I went on to try to print the filename at the top of each page, and am having a problem upon the change of the filename (SAS v8, z/os batch). Can anyone tell me why the new page heading isn't happening after TESTDAT1 LINE4 instead of after TESTDAT2 LINE1 ? Thanks, Nancy

//PRT EXEC SAS //MYFILE DD DSN=XYZ.SRC.DATA(TESTDAT1),DISP=SHR // DD DSN=XYZ.SRC.DATA(TESTDAT2),DISP=SHR //SYSIN DD * DATA _NULL_; LENGTH MYINFILE $ 40; INFILE MYFILE FILENAME=MYINFILE; RETAIN SAVEFILE;

IF _N_ = 1 THEN SAVEFILE = MYINFILE;

IF SAVEFILE NOT = MYINFILE THEN DO; FILE PRINT; PUT _PAGE_; SAVEFILE = MYINFILE; END;

INPUT @ 1 RECORD $CHAR75.; FILE PRINT NOTITLES HEADER=SPEC PAGESIZE=45; PUT _N_ @ 5 RECORD $CHAR75.;

RETURN;

SPEC: PUT @ 1 "PAGE HEADING " MYINFILE _N_; RETURN; // XYZ.SRC.DATA(TESTDAT1): TESTDAT1 LINE 1 TESTDAT1 LINE 2 TESTDAT1 LINE 3 TESTDAT1 LINE 4

XYZ.SRC.DATA(TESTDAT2): TESTDAT2 LINE 1 TESTDAT2 LINE 2 TESTDAT2 LINE 3

RESULTS: PAGE HEADING F678.SRC.SAS(TESTDAT1) 1 1 TESTDAT1 LINE 1 2 TESTDAT1 LINE 2 3 TESTDAT1 LINE 3 4 TESTDAT1 LINE 4 5 TESTDAT2 LINE 1 PAGE HEADING F678.SRC.SAS(TESTDAT2) 6 6 TESTDAT2 LINE 2 7 TESTDAT2 LINE 3


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