Portal | Manuals | References | Downloads | Info | Programs | JCLs | Master the Mainframes
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Usergroups Profile Log in to check your private messages Log in
 

 

How to include a Header & Trailer In a sort o/p file

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> DFSORT/ICETOOL
View previous topic :: :: View next topic  
Author Message
vivekbalokhra
Warnings : 1

New User


Joined: 15 Jul 2005
Posts: 6

PostPosted: Sat Dec 03, 2005 11:15 am    Post subject: How to include a Header & Trailer In a sort o/p file
Reply with quote

In a sort o/p file, how to include a Header & Trailer?
Back to top
View user's profile Send private message

radhakrishnan82

Active User


Joined: 31 Mar 2005
Posts: 436
Location: chennai, India

PostPosted: Sat Dec 03, 2005 11:25 am    Post subject:
Reply with quote

Including Header and Trailer was already discussed earlier in this forum.
Please search the previous posts.
Back to top
View user's profile Send private message
Frank Yaeger

DFSORT Moderator


Joined: 15 Feb 2005
Posts: 7130
Location: San Jose, CA

PostPosted: Sat Dec 03, 2005 10:07 pm    Post subject:
Reply with quote

You can include a report header and report trailer using DFSORT's HEADER1 and TRAILER1 operands of the OUTFIL statement, respectively. For example:

Code:

//S1 EXEC PGM=ICEMAN
//SYSOUT DD SYSOUT=*
//SORTIN DD DSN=...  input file
//SORTOUT DD DSN=...  output file w/header/trailer
//SYSIN DD *
   OPTION COPY
   OUTFIL REMOVECC,HEADER1=('This is a header'),
      TRAILER1=('This is a trailer')
/*


REMOVECC tells DFSORT not to include ANSI carriage control characters in the output file (e.g. '1' for new page). If you want ANSI carriage control characters, don't specify REMOVECC.

You can use many different options in HEADER1 (e.g. date/time in various forms, character and hexadecimal strings, input fields, etc) and in TRAILER1 (e.g. date/time in various forms, character and hexadecimal strings, input fields, counts, statistics, etc).

There's also HEADER2/TRAILER2 for the page header/trailer and HEADER3/TRAILER3 for the section header/trailer.

If you're not familiar with DFSORT and DFSORT's ICETOOL, I'd suggest reading through "z/OS DFSORT: Getting Started". It's an excellent tutorial, with lots of examples, that will show you how to use DFSORT, DFSORT's ICETOOL and DFSORT Symbols. You can access it online, along with all of the other DFSORT books, from:

www.ibm.com/servers/storage/support/software/sort/mvs/srtmpub.html
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> DFSORT/ICETOOL All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts Changing sort Card Dynamically vickey_dw DFSORT/ICETOOL 1 Sat Aug 19, 2017 2:33 pm
No new posts Match two files using multiple keys a... santoshks1987 SYNCSORT 10 Fri Aug 18, 2017 10:50 am
No new posts Multiple VSAM files single output fil... Mohan Kothakota DFSORT/ICETOOL 11 Wed Aug 09, 2017 7:57 pm
This topic is locked: you cannot edit posts or make replies. rexx code to create a ps file Bharath Vikraman CLIST & REXX 4 Mon Aug 07, 2017 10:30 am
No new posts Split file based on comparsion to 2 f... Div Grad DFSORT/ICETOOL 3 Thu Jul 27, 2017 9:16 pm


Facebook
Back to Top
 
Mainframe Wiki | Forum Rules | Bookmarks | Subscriptions | FAQ | Tutorials | Contact Us