mainframe zip

2010-08-13 Thread Jim McAlpine
Are there any free zip programs that will compress a number of mvs text
files which are compatible with winzip.

Jim McAlpine

--
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO
Search the archives at http://bama.ua.edu/archives/ibm-main.html


Re: mainframe zip

2010-08-13 Thread Andy Robertson
Use jar files?  Needs JAVA in batch, but I think they can be read by zip.



  Andy Robertson   telephone mobile 0777 214 9545 home 01308 420797
Subject: mainframe zip

Are there any free zip programs that will compress a number of mvs text
files which are compatible with winzip.

Jim McAlpine

**
This email is confidential and may contain copyright material of the John Lewis 
Partnership. 
If you are not the intended recipient, please notify us immediately and delete 
all copies of this message. 
(Please note that it is your responsibility to scan this message for viruses). 
Email to and from the
John Lewis Partnership is automatically monitored for operational and lawful 
business reasons.
**

John Lewis plc
Registered in England 233462
Registered office 171 Victoria Street London SW1E 5NN
 
Websites: http://www.johnlewis.com 
http://www.waitrose.com 
http://www.greenbee.com
http://www.johnlewispartnership.co.uk
 
**

--
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO
Search the archives at http://bama.ua.edu/archives/ibm-main.html


Re: mainframe zip

2010-08-13 Thread Michael Knigge

Jim McAlpine schrieb:

Are there any free zip programs that will compress a number of mvs text
files which are compatible with winzip.


Try   ftp://ftp.info-zip.org/pub/infozip/mvs/


bye,
Michael

--
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO
Search the archives at http://bama.ua.edu/archives/ibm-main.html


Re: mainframe zip

2010-08-13 Thread Leopold Strauss

 On 13.08.2010 11:54, Jim McAlpine wrote:

Are there any free zip programs that will compress a number of mvs text
files which are compatible with winzip.

Jim McAlpine

--
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO
Search the archives at http://bama.ua.edu/archives/ibm-main.html



Try gzip ( GNU.zip).

rg

Leo Strauss

--
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO
Search the archives at http://bama.ua.edu/archives/ibm-main.html


Re: mainframe zip

2010-08-13 Thread Jim McAlpine
On Fri, Aug 13, 2010 at 11:00 AM, Michael Knigge <
michael.kni...@set-software.de> wrote:

> Jim McAlpine schrieb:
>
> Are there any free zip programs that will compress a number of mvs text
>> files which are compatible with winzip.
>>
>
> Try   ftp://ftp.info-zip.org/pub/infozip/mvs/
>
>
> bye,
> Michael
>
>
>

It looks like infozip only allows you to zip a single file and not to use a
wildcard list which is what I require.

Thanks anyway.

Jim McAlpine

--
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO
Search the archives at http://bama.ua.edu/archives/ibm-main.html


Re: mainframe zip

2010-08-13 Thread Jim McAlpine
I ran the following to archive 2 files at once -


> //ZIP EXEC PGM=ZIP,
> //  PARM='/ -v -a  dd:archive -@'
> //STEPLIB  DD DSN=INFOZIP.LOAD,DISP=SHR
> //SYSPRINT DD SYSOUT=*
> //SYSOUT   DD SYSOUT=*
> //CEEDUMP  DD SYSOUT=*
> //ARCHIVE  DD DSN=INFOZIP.ARCHIVE,DISP=(NEW,CATLG),
> //SPACE=(CYL,(10,10),RLSE),.
> //SYSINDD *
> 'SEQ.DATASET1.TXT'
> 'SEQ.DATASET2.TXT'

and downloaded it to my pc in binary and unzipped it but the resultant files
have no end of line separators and I'm left with files of just a single
line.  Is there a parameter to fix that behaviour.

Jim McAlpine

--
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO
Search the archives at http://bama.ua.edu/archives/ibm-main.html


Re: mainframe zip

2010-08-13 Thread Kirk Wolf
Check the files... they probably have only newline as line separators.

Kirk Wolf
Dovetailed Technologies
http://dovetail.com

FWIW, there is a sample program in JZOS (in the IBM Java SDK) that I
wrote called "ZipDatasets" which will create Zip files from/to
datasets, PDS members, etc.
Unfortunately, it suffers the same fate (files are converted from
EBCDIC to ASCII with newlines and not CR/NL ).

You can download the source code, class files, and javadoc from here:

http://www-03.ibm.com/systems/z/os/zos/tools/java/products/jzos/jzossamp.html

This can be run in batch using the JZOS Batch Launcher.  Here are some details:
===

Usage: com.ibm.jzos.sample.ZipDatasets [-t targetEncoding] outfile indsname...
  where:
  -t targetEncoding can optionally specify the codepage name to encode the
  text data as it is written to the Zip file.  If not specified,
  this defaults to ISO8859-1 (Latin/ASCII)
  and outfile is either:
- a Unix file path name: /path/to/some/file.zip
- a dataset name:  //A.B.C
- a PDS member name:  //A.B.C(MEM)
- a DD name: //DD:XYZ
- a DD name and member:  //DD:XYZ(MEM)
  and each (at least one) indsname is either:
- a dataset name:  //A.B.C
- a dataset pattern:  //A.*.D
- a PDS member name:  //A.B.C(MEM)
- a PDS member pattern:  //A.B.C(D*X)
- a DD name: //DD:XYZ
- a DD name and member:  //DD:XYZ(MEM)
- a DD name and member pattern:  //DD:XYZ(D*X)
  // prefixes may be omitted from indsnames 
  All dataset names are assumed to be fully qualified.

Example: Zip several partitioned datasets to a Unix zip file:

com.ibm.jzos.sample.ZipDatasets test.zip sys1.proclib(asm*) hlq.**.jcl

Example: Zip all datasets matching two patterns to a dataset:

com.ibm.jzos.sample.ZipDatasets //hlq.backup.zip payroll.*.data gl.**.dat*

Example: Zip data using DDs and input and output:

com.ibm.jzos.sample.ZipDatasets //DD:ZIPOUT //DD:INSEQ1
//DD:INPDS1 //DD:INPDS2(FOO*)



On Fri, Aug 13, 2010 at 10:05 AM, Jim McAlpine  wrote:
> I ran the following to archive 2 files at once -
>
>
>> //ZIP     EXEC PGM=ZIP,
>> //  PARM='/ -v -a  dd:archive -@'
>> //STEPLIB  DD DSN=INFOZIP.LOAD,DISP=SHR
>> //SYSPRINT DD SYSOUT=*
>> //SYSOUT   DD SYSOUT=*
>> //CEEDUMP  DD SYSOUT=*
>> //ARCHIVE  DD DSN=INFOZIP.ARCHIVE,DISP=(NEW,CATLG),
>> //            SPACE=(CYL,(10,10),RLSE),.
>> //SYSIN    DD *
>> 'SEQ.DATASET1.TXT'
>> 'SEQ.DATASET2.TXT'
>
> and downloaded it to my pc in binary and unzipped it but the resultant files
> have no end of line separators and I'm left with files of just a single
> line.  Is there a parameter to fix that behaviour.
>
> Jim McAlpine
>
> --
> For IBM-MAIN subscribe / signoff / archive access instructions,
> send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO
> Search the archives at http://bama.ua.edu/archives/ibm-main.html
>

--
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO
Search the archives at http://bama.ua.edu/archives/ibm-main.html


Re: mainframe zip

2010-08-13 Thread Jim McAlpine
On Fri, Aug 13, 2010 at 4:05 PM, Jim McAlpine wrote:

> I ran the following to archive 2 files at once -
>
>
> > //ZIP EXEC PGM=ZIP,
> > //  PARM='/ -v -a  dd:archive -@'
> > //STEPLIB  DD DSN=INFOZIP.LOAD,DISP=SHR
> > //SYSPRINT DD SYSOUT=*
> > //SYSOUT   DD SYSOUT=*
> > //CEEDUMP  DD SYSOUT=*
> > //ARCHIVE  DD DSN=INFOZIP.ARCHIVE,DISP=(NEW,CATLG),
> > //SPACE=(CYL,(10,10),RLSE),.
> > //SYSINDD *
> > 'SEQ.DATASET1.TXT'
> > 'SEQ.DATASET2.TXT'
>
> and downloaded it to my pc in binary and unzipped it but the resultant
> files have no end of line separators and I'm left with files of just a
> single line.  Is there a parameter to fix that behaviour.
>
> Jim McAlpine
>
>
Eventually found the doc and as a result added the -l parameter which fixed
he problem.  The files now contain CRLF instaed of  LF (or NL or whatever it
is).

Jim McAlpine

--
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO
Search the archives at http://bama.ua.edu/archives/ibm-main.html


Re: mainframe zip

2010-08-13 Thread Subscribe Ibm-Main Sam
Try info-zip.  It works, but is somewhat dated with respect to the newer zOS 
file systems and is a little difficult to setup.

Once up and running it handles text files great.  It will do EBCDIC to ASCII 
conversion just fine.  Then just do a binary download and winzip will handle 
the zip file just fine.

Sam
--Original Message--
From: Jim McAlpine
Sender: IBM Mainframe Discussion List
To: IBM-MAIN@bama.ua.edu
ReplyTo: IBM Mainframe Discussion List
Subject: mainframe zip
Sent: Aug 13, 2010 2:54 AM

Are there any free zip programs that will compress a number of mvs text
files which are compatible with winzip.

Jim McAlpine

--
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO
Search the archives at http://bama.ua.edu/archives/ibm-main.html


Sent from my Verizon Wireless BlackBerry

--
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO
Search the archives at http://bama.ua.edu/archives/ibm-main.html


Re: mainframe zip

2010-08-13 Thread Paul Gilmartin
On Fri, 13 Aug 2010 12:06:18 +0200, Leopold Strauss wrote:

>  On 13.08.2010 11:54, Jim McAlpine wrote:
>> Are there any free zip programs that will compress a number of mvs text
>> files which are compatible with winzip.
>>
>Try gzip ( GNU.zip).
>
Errr... no.  gzip is something different.  The name was badly
chosen, and the authors have apologized.

But will WinZip handle a tar.Z or a pax.Z?  Wikipedia (which
is always right) says:

http://en.wikipedia.org/wiki/Comparison_of_file_archivers#Reading

... Yes.

-- gil

--
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO
Search the archives at http://bama.ua.edu/archives/ibm-main.html


Re: mainframe zip

2010-08-15 Thread Shmuel Metz (Seymour J.)
In , on
08/13/2010
   at 03:07 PM, Jim McAlpine  said:

>It looks like infozip only allows you to zip a single file and not to
>use a wildcard list which is what I require.

Not unless the MVS version is radically different from the OS/2
version. The zip command takes a list of files, and if you are calling
it from the shell then you can use file globbing. With the -@ option
it will take a list of file names from STDIN.
 
-- 
 Shmuel (Seymour J.) Metz, SysProg and JOAT
 ISO position; see  
We don't care. We don't have to care, we're Congress.
(S877: The Shut up and Eat Your spam act of 2003)

--
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO
Search the archives at http://bama.ua.edu/archives/ibm-main.html


Re: mainframe zip

2010-08-18 Thread Jim McAlpine
On Sun, Aug 15, 2010 at 1:35 PM, Shmuel Metz (Seymour J.) <
shmuel+ibm-m...@patriot.net > wrote:

> In 
> >,
> on
> 08/13/2010
>
> Not unless the MVS version is radically different from the OS/2
> version. The zip command takes a list of files, and if you are calling
> it from the shell then you can use file globbing. With the -@ option
> it will take a list of file names from STDIN.
>
> --
> Shmuel (Seymour J.) Metz, SysProg and JOAT
> ISO position; see 
> We don't care. We don't have to care, we're Congress.
> (S877: The Shut up and Eat Your spam act of 2003)
>
>
>

Thanks for letting me know about the list of files option.  That works via
SYSIN in batch.  The next problem I have is that I can't get the zip command
to just treat the file names as names without creating a directory
structure.  For instance, if I have a list of files like so -

H30D.QED.SJE.T47996.SZJRSH.SYSP
H30D.QED.SJE.T47997.SZJRSH.SYSP
The zip command treats the first 4 levels as directories and the zip output
looks like thsi -

Translating to ASCII...
  adding: H30D/QED/SJE/T47996/SZJRSH.SYSP   (in=428)
(out=229) (deflated 46%)
  adding: H30D/QED/SJE/T47997/SZJRSH.SYSP   (in=456)
(out=243) (deflated 47%)
total bytes=884, compressed=472 -> 47% savings
and when I ftp and unzip the archive I get a directory structure created of
the first 4 levels.  I've checked the doc but I can't see any way round
this.  Is there some option I've missed or am I stuck with that behaviour.

Jim McAlpine

--
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO
Search the archives at http://bama.ua.edu/archives/ibm-main.html


Re: mainframe zip

2010-08-19 Thread Shmuel Metz (Seymour J.)
In , on
08/18/2010
   at 03:26 PM, Jim McAlpine  said:

>The next problem I have is that I can't get the zip command to just
>treat the file names as names without creating a directory structure.

What happens if you restore them on an MVS system?
 
-- 
 Shmuel (Seymour J.) Metz, SysProg and JOAT
 ISO position; see  
We don't care. We don't have to care, we're Congress.
(S877: The Shut up and Eat Your spam act of 2003)

--
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO
Search the archives at http://bama.ua.edu/archives/ibm-main.html