LISTSERV at the University of Georgia
Menubar Imagemap
Home Browse Manage Request Manuals Register
Previous messageNext messagePrevious in topicNext in topicPrevious by same authorNext by same authorPrevious page (September 2002, week 2)Back to main SAS-L pageJoin or leave SAS-L (or change settings)ReplyPost a new messageSearchProportional fontNon-proportional font
Date:         Wed, 11 Sep 2002 14:13:12 +1000
Reply-To:     Philip_Crane@WORKCOVER.VIC.GOV.AU
Sender:       "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From:         Philip_Crane@WORKCOVER.VIC.GOV.AU
Subject:      Re: ZIP Utility
Content-type: text/plain; charset=us-ascii

Muhammad

The following code used another command 'gzip' to zip up a file on Unix. Winzip has no trouble extracting the file when it has been ftp'd as a BINARY file. By adding other options you should be able to extract files from an archive.

Hope this helps

Philip

51 /* Zip up a data file. */ 52 53 data _null_; 54 rc = system('/usr/contrib/bin/gzip /apps/reports/dat/stcodes.dat'); 55 if rc = 0 56 then put "Zip sucessful"; 57 else put "Zip failed"; 58 run;

Bob Burnham <robert.a.burnham@DAR To: SAS-L@LISTSERV.UGA.EDU TMOUTH.EDU> cc: Sent by: "SAS(r) Subject: Re: ZIP Utility Discussion" <SAS-L@LISTSERV.UGA.E DU>

10/09/2002 11:14 PM Please respond to Bob Burnham

MKhan@OXHP.COM (Khan, Muhammad Z.) writes:

+---------------------------------------------------------------- | Is there a zip utility that would convert PC based zipped files | (created by WINZIP) on UNIX SUNOS 5.8? +----------------------------------------------------------------

Most Solaris boxes that I've been on have 'zip' and 'unzip' installed. Here is a brief exerpt from the unzip man page:

NAME unzip - list, test and extract compressed files in a ZIP archive

SYNOPSIS unzip [-Z] [-cflptuvz[abjnoqsCLMVX$]] file[.zip] [file(s) ...] [-x xfile(s) ...] [-d exdir]

DESCRIPTION unzip will list, test, or extract files from a ZIP archive. The default behavior (with no options) is to extract into the current directory (and subdirectories below it) all files from the specified ZIP archive. A companion program, zip (available from http://www.cdrom.com/pub/infozip/), creates ZIP archives; both programs are compatible with archives created by PKWARE's PKZIP and PKUNZIP for MS-DOS, but in many cases the program options or default behaviors differ.

Best regards to list,

Bob

-- Bob Burnham bburnham@dartmouth.edu http://www.dartmouth.edu/~bburnham


Back to: Top of message | Previous page | Main SAS-L page