Portal | Manuals | References | Downloads | Info | Programs | JCLs | Mainframe wiki | Quick Ref
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Profile Log in to check your private messages Log in
 
Question on Syncsort OUTREC option

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> JCL & VSAM
View previous topic :: :: View next topic  
Author Message
janmejay
Warnings : 1

New User


Joined: 22 Jun 2007
Posts: 81
Location: bangalore

PostPosted: Tue Jul 29, 2008 10:50 am    Post subject: Question on Syncsort OUTREC option
Reply with quote

I have an input file with record length of 600. In the output file I want , only the coln position 1-2 should be skipped and the remaining fields should be copied.
By using outrec we can do this , but in this case we need to specify every fields that to be come in the output file .
is it possible only the coln posn 1-2 is skipped and remaining should copied to output file by using outrec.
i tried outrec=(1:3,600)

but its showing error 'OUTREC FIELD OUTSIDE RANGE'
Back to top
View user's profile Send private message

krisprems

Active Member


Joined: 27 Nov 2006
Posts: 649
Location: India

PostPosted: Tue Jul 29, 2008 11:02 am    Post subject:
Reply with quote

Try the below sort card,
Code:
 outrec=(1:3,600,2X)


i have padded 2 blanks at the end of each record to compensate the record length to be 600 after removing column 1-2.

If you are still facing problems the post your sysout messages
Back to top
View user's profile Send private message
Prasanthhere

Active User


Joined: 03 Aug 2005
Posts: 306

PostPosted: Tue Jul 29, 2008 11:06 am    Post subject: Reply to: Doubt on OUTREC option
Reply with quote

When you are skipping 2 fields the output file will be 598 ie, you are getting an error .

OUTREC FIELDS=(1:3,598) will work fine. If you need the o/p file as 600 itself you have pad the 2 extra spaces
Back to top
View user's profile Send private message
janmejay
Warnings : 1

New User


Joined: 22 Jun 2007
Posts: 81
Location: bangalore

PostPosted: Tue Jul 29, 2008 11:32 am    Post subject: Reply to: Doubt on OUTREC option
Reply with quote

OUTREC=(1:3,600,2X) its also showing same error.
OUTREC=(1:3,598) its working fine.
Back to top
View user's profile Send private message
expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8666
Location: Back in jolly old England

PostPosted: Tue Jul 29, 2008 11:49 am    Post subject:
Reply with quote

Isn't the syntax (1:pos,length,......)

Which means that there will be an error using 3,600 for a 600 byte records, as there can not be 600 bytes of record left from pos 3 onwards.
Back to top
View user's profile Send private message
krisprems

Active Member


Joined: 27 Nov 2006
Posts: 649
Location: India

PostPosted: Tue Jul 29, 2008 12:21 pm    Post subject:
Reply with quote

yes, expat that's true
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 -> JCL & VSAM All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts OUTREC OVERLAY different to INCREC ge... Joerg.Findeisen SYNCSORT 8 Fri Apr 27, 2018 2:11 am
No new posts Reformatting and adding additional fi... Badbeef SYNCSORT 6 Thu Apr 05, 2018 4:45 pm
No new posts VALIDATE option in BIND jcl Poha Eater DB2 2 Mon Feb 26, 2018 7:08 pm
No new posts JES2 EXIT 6 QUESTION Randy Horowitz All Other Mainframe Topics 30 Tue Feb 06, 2018 5:47 pm
No new posts OUTREC with ALter Command scorp_rahul23 DFSORT/ICETOOL 1 Wed Nov 22, 2017 3:10 pm

Facebook
Back to Top
 
Job Vacancies | Forum Rules | Bookmarks | Subscriptions | FAQ | Polls | Contact Us