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
 

 

How to display data in separate lines in ASCII file.

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

New User


Joined: 26 Jan 2016
Posts: 5
Location: india

PostPosted: Tue Jan 26, 2016 9:49 pm    Post subject: How to display data in separate lines in ASCII file.
Reply with quote

I have used ICE TOOL to convert EBCDIC file to ASCII file for file transfer from zOS to zOS UNIX Directory. Mainframe file has four lines. But when user views the ASCII file, all four lines are displayed in single. Could you please help me to know if we can transfer the file sin such a way that in ASCII file data is displayed in four lines instead of single line. Thanks,

We are doing file transfer to USS directory using the sample code available over internet as below. but all data appear in single line

//COPYSTEP EXEC PGM=IKJEFT01
//INMVS DD DSN=EV6946.USS.TO.MVS,DISP=OLD
//OUTHFS DD PATH='/SYSTEM/tmp/EV6946.MVS.TO.USS2',
// PATHOPTS=(OCREAT,OWRONLY),PATHMODE=(SIRUSR,SIWUSR)
//SYSTSPRT DD SYSOUT=*
//SYSPRINT DD SYSOUT=*
//SYSTSIN DD *
OCOPY INDD(INMVS) OUTDD(OUTHFS) BINARY CONVERT(NO)
/*

Input file has details in following format:
Header
dataline1
dataline2
trailer

But ASCII file at USS directory is displayed as
Header dataline1 dataline2 trailer
Thanks

Can I have a link where supporting document is available to apply it in our JCL.
Back to top
View user's profile Send private message

kranthikumarb

Active User


Joined: 02 Jan 2009
Posts: 114
Location: Hyderabad

PostPosted: Wed Jan 27, 2016 12:01 pm    Post subject:
Reply with quote

I faced a similar issue some time back. What I learned was, there is no record concept in USS in Z/OS. Imagine it like a buffer. So you may not be able to see the data in records. But when you send the same file back to TSO, it is clever enough to split it into records.

I may be wrong or there could be a way to do it. But that was my experience.

Just give a try with this card

Code:

ocopy indd(INMVS) outdd(OUTHFS) TEXT CONVERT((BPXFX311)) FROM1047
Back to top
View user's profile Send private message
Robert Sample

Global Moderator


Joined: 06 Jun 2008
Posts: 7997
Location: Bellevue, IA

PostPosted: Wed Jan 27, 2016 6:37 pm    Post subject:
Reply with quote

USS in z/OS sort of recognizes records. OCOPY will add a newline character to the end of each line -- but only for a TEXT file. When using BINARY on the OCOPY, no newline will be added anywhere. If you must use BINARY on your OCOPY, you can either add the newlines yourself to the data, or you can live with all the data in one line.
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
No new posts Data replication from multiple Db2 ta... kishpra DB2 5 Mon Mar 27, 2017 9:58 pm
No new posts Changing of LRECL of a file abdulrafi DFSORT/ICETOOL 2 Fri Mar 24, 2017 3:25 pm
No new posts splitting a file abdulrafi DFSORT/ICETOOL 4 Fri Mar 24, 2017 11:51 am
No new posts Count the length of the record & ... sreekusr DFSORT/ICETOOL 4 Thu Mar 23, 2017 7:52 pm
No new posts Receive a file using PCOMM macro Harald.v.K IBM Tools 0 Thu Mar 23, 2017 6:50 pm


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