PKUNZIP in mainframe



Post anything related to mainframes (IBM & UNISYS) if not fit in any of the above categories

PKUNZIP in mainframe

Postby satlab » Tue Oct 07, 2008 11:17 pm

Hi,

I am using pkunzip to retrieve a specific file from the zip file by using the following instructions.

-ARCHINDD(ZIPFILE)
-OUTFILE_DD(UNZIPFL)
R*
-DATA_TYPE(TEXT)

The input file is in binary mode, but i want the output file to be in text mode so that i can make modifications to it. The file, which i want to retrieve starts with "R". When i run my jcl, the entire content is coming in single line in output file. Actually the content looks like an xml file. I gave the record length as 80 and recfm as fb. Is there any way to get the output in multiple lines. Do we need to specify any other option for this? Please let me know.
Thanks for your help.
satlab
 
Posts: 12
Joined: Tue Oct 07, 2008 11:04 pm
Has thanked: 0 time
Been thanked: 0 time

Re: PKUNZIP in mainframe

 

Re: PKUNZIP in mainframe

Postby MrSpock » Tue Oct 07, 2008 11:48 pm

You have to tell PKUNZIP what the codes are for EOL and EOF. You specify them as the proper sequence of CR (Carriage Return) LF (Line Feed) and CZ (Control Z) or as nothing (Null).

-DATA_DELIMITER(CRLF) or -DELIM(CRLF)
-FILE_TERMINATOR(CRLFCZ) or -TERM(CRLFCZ)
User avatar
MrSpock
Global moderator
 
Posts: 810
Joined: Wed Jun 06, 2007 9:37 pm
Location: Raleigh NC USA
Has thanked: 0 time
Been thanked: 2 times

Re: PKUNZIP in mainframe

Postby satlab » Wed Oct 08, 2008 12:01 am

Hi,

I tried including these options, but it is giving the same result.
satlab
 
Posts: 12
Joined: Tue Oct 07, 2008 11:04 pm
Has thanked: 0 time
Been thanked: 0 time

Re: PKUNZIP in mainframe

Postby satlab » Wed Oct 08, 2008 12:13 am

Hi,

Actually the output file would be ftp'ed to Unix server. I verified it on unix server and it is showing up as a single record. That means i am fine with having the entire content in single line. Sorry for posting this without checking properly.

I have one more issue with this. The unzipped file size varies for different executions. Here file size is nothing but the number of bytes, as we have only one record in the file. But how can i specify the record length when i am running pkunzip as i am not sure about the size of output file. What should be the record format type as the size varies from time to time? Please let me know.
satlab
 
Posts: 12
Joined: Tue Oct 07, 2008 11:04 pm
Has thanked: 0 time
Been thanked: 0 time

Re: PKUNZIP in mainframe

Postby satlab » Wed Oct 08, 2008 12:57 am

I should have told length of the file instead of size of the file. Please treat it as length of the file.
satlab
 
Posts: 12
Joined: Tue Oct 07, 2008 11:04 pm
Has thanked: 0 time
Been thanked: 0 time

Re: PKUNZIP in mainframe

Postby satlab » Fri Nov 14, 2008 11:02 pm

I achieved this with the option -CRLF(N). It is working fine.

Thanks
satlab
 
Posts: 12
Joined: Tue Oct 07, 2008 11:04 pm
Has thanked: 0 time
Been thanked: 0 time


Return to All other Mainframe Topics

 


  • Related topics
    Replies
    Views
    Last post