06-10-2012 11:21 PM
I have one .gz file in unix server location /aaa/dddd/ssss/file.gz
file.gz having .csv file inside.
Can any one provide me the command to gzip this file use in DI studio 3.4 job. Thanks in advance.
06-11-2012 06:26 AM
gzip files are unzipped with the gunzip UNIX command.
You can call it in the pre-code of the job using the X statement (make sure that AllowXCommand is set in the workspace/batch server).
06-11-2012 09:43 PM
Thank you for the valuable suggetion LinusH.
I have given below code in job preprocess, job successful however file not uncompressed.
Please advise. Thanks in advance.
/* Access the data library */
LIBNAME xxx "/aaa/dddd/ssss/file.gz" ;
/* gunzip file */
x gunzip "file.gz";
06-12-2012 02:19 AM
The X statement does not unfortunately give a returnrn code.
If you are using the filename file pipe "gunzip file.gz"; you will be able to see the return code when called from a data step.
I don't that the file name should have any quotation...?
And, are you sure that the file resists in the current directory on the server?