Reputation: 17
Attached here is my very simple code to read in .sav files into SAS for analysis.
PROC IMPORT
DATAFILE='C:\Users\Desktop\Iliu_SAS_Files_Relocated\0310_HPV-Boys\SPSS Files\BoyVacuptake.sav'
OUT=work.BoyVacuptake
DBMS=SAV REPLACE;
The error code that I keep getting is:
ERROR: DBMS type SAV not valid for import.
I am running SAS 9.4 which should allow me to import/export SPSS files using the DBMS=SAV option. Does anyone know why I may be getting this error? Or any fixes?
I've tried using the DBMS=SPSS option as well, same error. Probably going to try to just read everything into R and export into SAS from there. Need to convert everything to a .sas7bdat file. The .sav files are from an external partner, I do not have access to SPSS to just save the data in a different format.
Upvotes: 0
Views: 338
Reputation: 51581
First make sure you have SAS/Access to PC Files licensed and installed. Run PROC SETINIT to see what you have licensed.
Second try using SPSS as the DBMS= setting as this documentation page says: https://documentation.sas.com/doc/en/pgmsascdc/9.4_3.5/acpcref/n1h6b01uh0dm2yn1fpq85gjgwcfs.htm
Importing and Exporting SPSS Files
SPSS Files (DBMS=SPSS)
The IMPORT and EXPORT procedures support two DBMS= identifiers for SPSS .sav files. The DBMS=SPSS specification uses SPSS file formats to access data in SPSS .sav files on UNIX and Microsoft Windows operating platforms.
Upvotes: 0