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
 

 

need a column of a large file to put in a new file

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

New User


Joined: 16 May 2008
Posts: 36
Location: Kolkata,India

PostPosted: Wed Feb 10, 2010 1:59 pm    Post subject: need a column of a large file to put in a new file
Reply with quote

Hi,

I need to put a particular column of an I/P file to a new file (from 201th column of length 6 )
I am using the below SYSIN for the sort card but getting an error.

Code:
//SYSIN DD *             
  SORT FIELDS=COPY       
  OUTREC FIELDS=(1:201,6)
/*                       


error
Code:
WER235A  INREC    RDW NOT INCLUDED
Back to top
View user's profile Send private message

expat

Global Moderator


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

PostPosted: Wed Feb 10, 2010 2:03 pm    Post subject:
Reply with quote

1) This is SYNCSORT so should be posted in the JCL forum.

2) The error message tells you exactly what the problem is. Have you bothered to read the product documentation for yourself.
Back to top
View user's profile Send private message
Alissa Margulies

SYNCSORT Support


Joined: 25 Jul 2007
Posts: 500
Location: USA

PostPosted: Thu Feb 18, 2010 1:04 am    Post subject:
Reply with quote

Kamlesh,

Assuming your original input file was variable length and you want a variable length output file, then you can code the following:
Code:
//SYSIN DD *             
  INREC FIELDS=(1,4,5:201,6)
  SORT FIELDS=COPY       
/*         

However, if you want a fixed-length output file, then you can code this instead:
Code:
//SYSIN DD *   
  SORT FIELDS=COPY       
  OUTREC FIELDS=(201,6),CONVERT
/*         

or
Code:
//SYSIN DD *   
  SORT FIELDS=COPY       
  OUTREC FIELDS=(201,6),VTOF
/*         
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 SORTJOIN - Copy Matched and Unmatched... Steve Ironmonger DFSORT/ICETOOL 5 Tue Jan 17, 2017 4:26 pm
No new posts DB2 query Using Recursion, Converting... smilewithashu2 DB2 1 Tue Jan 03, 2017 12:50 pm
No new posts Copy RECFM =VB TO FB file with RECL =... sahil41352 DFSORT/ICETOOL 3 Wed Dec 28, 2016 11:29 pm
No new posts Add PD field from 2nd file to PD in 1st Sushant Garje DFSORT/ICETOOL 6 Thu Dec 01, 2016 4:32 pm
No new posts File Aid to File Manager conversion murali3955 IBM Tools 4 Thu Nov 24, 2016 3:41 pm


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