View previous topic :: View next topic
|
Author |
Message |
peyush
New User
Joined: 29 Sep 2008 Posts: 6 Location: United Kingdom
|
|
|
|
I am trying to transfer a zip file using C;D from mainframe to windows machine. When I am trying to open the zip file i am getting the following error "Cannot open file. It does not appear to be a valid archive ".
The proc which I am using is as follows
ABCPRO PROC SNODE=&&CDNODE -
PNODE=PNODE -
RETAIN=NO -
CLASS=10 PRTY=10 -
&INDSN = &&DSN1
SYMBOL &OUTDSN = &&DSN2
COPYSTEP COPY FROM -
(PNODE -
DSN=&INDSN -
DISP=(SHR) -
) -
TO -
(SNODE -
DSN=&OUTDSN -
DISP=RPL -
SYSOPTS="DATATYPE(BINARY)" -
) |
|
Back to top |
|
|
dick scherrer
Moderator Emeritus
Joined: 23 Nov 2006 Posts: 19244 Location: Inside the Matrix
|
|
|
|
Hello and welcome to the forum,
Can the archive be successfully unzipped on the mainframe?
Is the file on the target system the same size as the mainframe zipped file?
Sugest you work with a very, very small test file to work out the process and then go for the real file. |
|
Back to top |
|
|
peyush
New User
Joined: 29 Sep 2008 Posts: 6 Location: United Kingdom
|
|
|
|
Answer to your queries
1) When I try to transfer this file using quick 3270 in binary mode and i was able to open the file in zip fromat.
2) The file which was zipped would be having the same size once it was unzipped on the windows machine.
I tried testing it but no sucess. is there anything wrong with the procs. |
|
Back to top |
|
|
dick scherrer
Moderator Emeritus
Joined: 23 Nov 2006 Posts: 19244 Location: Inside the Matrix
|
|
|
|
Hello,
It may help if you post the informational messages generated when the process was executed. |
|
Back to top |
|
|
superk
Global Moderator
Joined: 26 Apr 2004 Posts: 4652 Location: Raleigh, NC, USA
|
|
|
|
My first instinct is to go to the location of the file in question (on the Windows machine) and run a hex dump of the good file vs. the problem file (presuming, of course, that they are the same file) and try to find where there are discrepencies in the coding bits. |
|
Back to top |
|
|
peyush
New User
Joined: 29 Sep 2008 Posts: 6 Location: United Kingdom
|
|
|
|
Hi,
I am able to transfer the file. Thanks for taking time off to put your valuable suggestions here.
Thanks
Peyush |
|
Back to top |
|
|
dick scherrer
Moderator Emeritus
Joined: 23 Nov 2006 Posts: 19244 Location: Inside the Matrix
|
|
|
|
Hello,
Quote: |
I am able to transfer the file. |
Good to hear it is working
What was changed to make it work? |
|
Back to top |
|
|
peyush
New User
Joined: 29 Sep 2008 Posts: 6 Location: United Kingdom
|
|
|
|
The utility which was used to zip this dataset is converting it into GZIP rather than zip. I changed the extension of destination file to .GZ and it worked. I also checked by cnverting the dataset into zip and received it with the file having extension as .zip. It worked fine as well.
Thanks |
|
Back to top |
|
|
dick scherrer
Moderator Emeritus
Joined: 23 Nov 2006 Posts: 19244 Location: Inside the Matrix
|
|
|
|
Thank you for posting the resolution
d |
|
Back to top |
|
|
|