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

Formating the Input file


IBM Mainframe Forums -> DFSORT/ICETOOL
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
sreekusr
Warnings : 1

New User


Joined: 28 Aug 2006
Posts: 54
Location: Madrid

PostPosted: Fri Feb 17, 2017 10:40 pm
Reply with quote

Hi All,

Requirement -
Input file record - (FB file)
Code:
NAMEA ADDRESSA1 ADDRESSA2
NAMEB ADDRESSB1 ADDRESSB2


Expected output
Code:
<FIELD1>NAMEA<FIELD2>ADDRESSA1<FIELD3>ADDRESSA2
<FIELD1>NAMEB<FIELD2>ADDRESSB1<FIELD3>ADDRESSB2


And there could be thousands of input record, So please someone help to figure out a SORT to deal with this?

Thanks and Regards,
Sree
Back to top
View user's profile Send private message
Bill Woodger

Moderator Emeritus


Joined: 09 Mar 2011
Posts: 7309
Location: Inside the Matrix

PostPosted: Sat Feb 18, 2017 12:29 am
Reply with quote

From your example, the data is always in fixed positions. Simple to reformat with BUILD.

However, probably things are not so clear as that. Is the data always in fixed positions? Are trailing spaces OK on fields in the output?
Back to top
View user's profile Send private message
sergeyken

Senior Member


Joined: 29 Apr 2008
Posts: 2010
Location: USA

PostPosted: Sat Feb 18, 2017 3:01 am
Reply with quote

If input file positions are not fixed but varying, then additionally use
Code:
INREC PARSE=...,BUILD=...


For details - RTFM please
Back to top
View user's profile Send private message
sreekusr
Warnings : 1

New User


Joined: 28 Aug 2006
Posts: 54
Location: Madrid

PostPosted: Mon Feb 20, 2017 2:41 pm
Reply with quote

Thanks a lot for the quick response.
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 -> DFSORT/ICETOOL

 


Similar Topics
Topic Forum Replies
No new posts Extracting Variable decimal numbers f... DFSORT/ICETOOL 17
No new posts SFTP Issue - destination file record ... All Other Mainframe Topics 2
No new posts Access to non cataloged VSAM file JCL & VSAM 18
No new posts Need help for File Aid JCL to extract... Compuware & Other Tools 23
No new posts Using Dynamic file handler in the Fil... COBOL Programming 2
Search our Forums:

Back to Top