07-29-2016 01:55 PM
I have created a .txt file and did .gz . After that used filename ftp statement
ftp was succesfull. but I am not able to unzip on other server. Please help
07-29-2016 03:26 PM
Please post your code.
Have you confirmed that it works via system commands?
Your server also has gzip? SAS doesn't provide a zip utility. If you use winzip you don't need to unzip the file...
07-29-2016 03:49 PM - edited 07-29-2016 03:49 PM
You'll likely be better off unzipping the file after ftp to local computer and then read the results. If you do not have WINZIP then reading the zipped file will fail as far as I know.
07-29-2016 04:32 PM
That's nice. It still doesn't help illustrate what code he actually used.
And again, those are system commands. Verify your system commands first, then pass them to SAS.
07-30-2016 02:42 AM - edited 07-31-2016 04:45 AM
So from what you tell us:
1. zipping in the source system works
2. sending the zipped file via FTP works and the target system receives the zipped file
3. unzipping in the target environment doesn't work.
What you need to do is a bit of an analytical approach to get to the point where something goes wrong.
a. once you've zipped your file in the source environment: can you unzip it again in the source environment?
b. have you tried to simply ftp the file via command prompt ftp commands (without any SAS involved)?
c. WHAT does not work for unzipping? There is no tool available to do the job? Or you get an error message when trying to unzip? Or you can unzip but then the content is "garbled"?
d. What's the source OS (Unix, Windows, ...) and what's the target OS?
e. Which tool/software are you using in the target environment for unzipping? If you can try 7-zip as it deals with quite a number of different archive formats.