IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

syncsort trailer problem


IBM Mainframe Forums -> JCL & VSAM
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
CICS fan

New User


Joined: 03 Apr 2008
Posts: 82
Location: United States

PostPosted: Mon Oct 26, 2009 1:42 pm
Reply with quote

Hello i asked this in dfsort forum and later realised we have syncsort running in our system.

the problem is:

i have an input file of a particular layout:

thru syncsort i want to add a trailer record whose layout will be:

hardcoded '2' --record type
date --- this will be run date(system date) minus one day in ccyymmdd format
record count--integer 9--total no of records excluding trailer

please suggest.
Back to top
View user's profile Send private message
Anuj Dhawan

Superior Member


Joined: 22 Apr 2006
Posts: 6250
Location: Mumbai, India

PostPosted: Mon Oct 26, 2009 4:22 pm
Reply with quote

What version of Syncsort you are running on?
Back to top
View user's profile Send private message
CICS fan

New User


Joined: 03 Apr 2008
Posts: 82
Location: United States

PostPosted: Mon Oct 26, 2009 4:25 pm
Reply with quote

Anuj,

I tried this:

SORT FIELDS=COPY
INCLUDE COND=(1,1,CH,EQ,C'1')
OUTFIL FILES=01,OUTREC=(1,178),REMOVECC,
TRAILER1=('2',2:&DATE-1,COUNT=(M11,LENGTH=9))

and its working fine, but i want the trailer date as CCYYMMDD and its coming as MM/DD/YY
Back to top
View user's profile Send private message
Alissa Margulies

SYNCSORT Support


Joined: 25 Jul 2007
Posts: 496
Location: USA

PostPosted: Mon Oct 26, 2009 9:21 pm
Reply with quote

CICS fan,

Here are the SyncSort for z/OS 1.3 control statements that will produce the requested output:
Code:
//SYSIN DD *
   SORT FIELDS=COPY
   INCLUDE COND=(1,1,CH,EQ,C'1')
   OUTFIL FILES=01,OUTREC=(1,178),REMOVECC,
   TRAILER1=('2',2:&DATENS=(4MD)-1,COUNT=(M11,LENGTH=9))
/*
Back to top
View user's profile Send private message
CICS fan

New User


Joined: 03 Apr 2008
Posts: 82
Location: United States

PostPosted: Tue Oct 27, 2009 2:03 pm
Reply with quote

Alissa,

Thanks a ton! It works and my headcahe is over! Thanks again!
Back to top
View user's profile Send private message
Alissa Margulies

SYNCSORT Support


Joined: 25 Jul 2007
Posts: 496
Location: USA

PostPosted: Tue Oct 27, 2009 10:31 pm
Reply with quote

You're very welcome, and thanks for letting us know.
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic View Bookmarks
All times are GMT + 6 Hours
Forum Index -> JCL & VSAM

 


Similar Topics
Topic Forum Replies
No new posts Compare only first records of the fil... SYNCSORT 7
No new posts Map Vols and Problem Dataset All Other Mainframe Topics 2
No new posts Insert trailer for non empty file only DFSORT/ICETOOL 6
No new posts z/vm installation problem All Other Mainframe Topics 0
No new posts Comparing Header and Trailer. DFSORT/ICETOOL 7
Search our Forums:

Back to Top