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
 

 

Convrt unload file to o/p readable format file using SORT

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

New User


Joined: 03 Jun 2010
Posts: 1
Location: Hyderabad

PostPosted: Sat Jun 12, 2010 11:43 pm    Post subject: Convrt unload file to o/p readable format file using SORT
Reply with quote

I have unloaded data from multiple tables to a file. This unload file is not in a readable format, because some of the fields are declared in COMP, decimal etc.

How to convert this to a readable format file.
I want an output file in a readable format with each field separated by comma.


What is the SORT condition for this?
Back to top
View user's profile Send private message

dick scherrer

Site Director


Joined: 23 Nov 2006
Posts: 19270
Location: Inside the Matrix

PostPosted: Sun Jun 13, 2010 12:04 am    Post subject:
Reply with quote

Hello and welcome to the forum,

Before anyone can help you, you have to provide the information needed to help you.

Post the recfm and lrecl of the input and output files (prefereably one that is only a few fields and covers the datatypes you need to deal with).

Show some sample input data and the output you want from that input.
Back to top
View user's profile Send private message
CICS Guy

Senior Member


Joined: 18 Jul 2007
Posts: 2150
Location: At my coffee table

PostPosted: Sun Jun 13, 2010 12:05 am    Post subject:
Reply with quote

If you can identify the individual fields in each record, yes, sort can do this.

Are you familiar with the inrec/outrec reformatting functions?
For instance: 10,4,BI,TO=ZD,LENGTH=8 which takes a four byte comp field beginning at the 10th byte of the file and converts it to an eight digit displayable decimal number.
The only trick is that you need to know exactly where each field is in order to convert it.

Sticking commas between the converted fields is very simple.
Back to top
View user's profile Send private message
Skolusu

Senior Member


Joined: 07 Dec 2007
Posts: 2205
Location: San Jose

PostPosted: Mon Jun 14, 2010 9:26 pm    Post subject:
Reply with quote

Radhika N,

Look at DB2 High performance unload utility which lets you unload the data into a readable format automatically along with delimiter between each field.

Check this link which explains in detail about the utility

http://publibz.boulder.ibm.com/cgi-bin/bookmgr_OS390/BOOKS/INZUGC21/CCONTENTS
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
This topic is locked: you cannot edit posts or make replies. Fetching data from BAI File arunsoods JCL & VSAM 1 Wed Jul 19, 2017 4:28 pm
No new posts Write out NODUPS but just from one file Jay Villaverde DFSORT/ICETOOL 8 Fri Jul 14, 2017 12:44 am
No new posts SORT to unpack a feild shr_amar DFSORT/ICETOOL 7 Fri Jul 07, 2017 4:32 am
No new posts How to add header with Date(YYMMDD) i... Rajan Moorthy DFSORT/ICETOOL 2 Thu Jul 06, 2017 11:44 pm
No new posts How to write Specific Fields from Mul... Padhu SYNCSORT 6 Thu Jul 06, 2017 10:26 am


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