How to import the Zip files into SAS? If it is possible in
SAS? If it is posible write the code...
Answers were Sorted based on User's Feedback
Answer / sushil nayak
Yes, reading a ZIP file in Windows SAS is possible. Use the Winzip Command Line Support Add-on and a FILENAME statement to read zipped files into a SAS data set.
Check out this link :: Sample 26011: Reading zipped files on Windows :: http://support.sas.com/kb/26/011.html#
Is This Answer Correct ? | 10 Yes | 1 No |
Answer / vinod kumar
We can read the zipped files in to SAS by using the SASZIPAM
option.
filename file1 saszipam 'd:\Myfiles\dumps.zip';
data dset;
infile file1(dumps1.csv) dlm=','; *-dumps1.csv is one of
the file in zipped file;
input email $ name $ address $ city $ zip $;
put _infile_;
run;
Is This Answer Correct ? | 4 Yes | 2 No |
Answer / paul
to read zip files SAS has special keyword i.e., SASZIPAM
eg:
FILENAME myzipfile SASZIPAM 'd:\filelocation\6100Txn.zip';
data _null_;
infile myzipfile(sales_JAN);
input;
put _infile_;
run;
/*here iam extracting sales_JAN file from 6100Txn.zip file
since we don't know the file structure put everything to log.
to see the file names in zip, physically access the zip file
without extracting the file contents. */
Is This Answer Correct ? | 3 Yes | 2 No |
Answer / sanjay
filename foo pipe '"c:\program files\winzip\wzunzip.exe"
-o -c
c:\sample01584_1_data.zip
testfile.txt';
/* The zip file, sample01584_1_data.zip, is flat file
created */
/* from PROC Export and SASHELP.CLASS.
*/
data test;
/* Use FIRSTOBS= to skip the first 8 records related to
zip */
/* information, and the 9th record which contains a header
*/
/* record of variable names from SASHELP.CLASS.
*/
infile foo firstobs=10 truncover dsd;
input name :$9. sex :$1. age height weight;
run;
proc print;
run;
Is This Answer Correct ? | 3 Yes | 3 No |
Answer / no no no noooo
PROC IMPORT OUT= WORK.ALL
DATAFILE= "C:\Users\1234Documents\SENTHIL\dmp3split.zip"
DBMS=CSV REPLACE;
GETNAMES=YES;
DATAROW=2;
RUN;
Is This Answer Correct ? | 4 Yes | 6 No |
What are the functions done while Compilation...?
what is p-value
3 Answers Accenture, Quintiles, Sristek,
Hi Friends, My name is Priya,am new to this Forum. am looking for SAS Platform Administration Interview Questions.I searched every where but I couldn't find any where.please can anyone help me with the FAQ's. It would be a great favor to me if you can email the Interview Questions to priyafeb84@gmail.com
Which is the best place to learn SAS clinicals and Oracle clinical in hyderabad?
What are the different versions of sas that you have used until now? : sas-grid-administration
What is the role of administrative users? : sas-grid-administration
I need help in merging two different datasets. I am merging by date and I want to propagate observations from one dataset to the corresponding dates. One dataset has a unique date for each day of the month, while the other dataset has same date for different patient visits. For example I want to spread an observation on the 31DEC2008 from one dataset to several observations with the same date on a second dataset for all the patients who visited on that date. I have tried to merge the two and the result is not what I wanted. Instead I get a dataset whereby all the dates have missing values where observations from the first datset should have spread.
what cause the "error: connect:" and "error in the libname statement" when there weren't any such problems?
What is _n_?
What report output formats can you generate using SAS?
Which are the statements whose placement in the data step is critical?
How do you read in the variables that you need?