BookmarkSubscribeRSS Feed
zimu94681
Fluorite | Level 6

I am trying to import SPSS files into SAS. SPSS automatically generated a SAS dataset and also a code file of all formats.

 

I wanted to run the format codes to apply all formats to the dataset. The formats codes are like this:

 

libname library '\xxxxxxx' ;

proc format library = library ;

value followup

0 = 'Baseline'

1 = '1st Followup'

2 = '2nd Followup'

3 = '3rd Followup'

4 = '4th Followup'

5 = '5th Followup'

6 = '6th Followup'

7 = '7th Followup'

8 = '8th Followup'

9 = '9th Followup' ;

proc datasets library = library ;

modify dataset;

format followup followup.;

quit;

 

I just used one format for illustration purpose.

 

However, I got an error like this:

"ERROR: File LIBRARY.DATASET cannot be updated because its encoding does not match the

session encoding or the file is in a format native to another host, such as WINDOWS_32."

 

Can anyone help me to solve the problem?

Thank you very much!!

1 REPLY 1

sas-innovate-white.png

🚨 Early Bird Rate Extended!

Join us for SAS Innovate 2025, our biggest and most exciting global event of the year, in Orlando, FL, from May 6-9.

 

Lock in the best rate now before the price increases on April 1.

Register now!

Mastering the WHERE Clause in PROC SQL

SAS' Charu Shankar shares her PROC SQL expertise by showing you how to master the WHERE clause using real winter weather data.

Find more tutorials on the SAS Users YouTube channel.

Discussion stats
  • 1 reply
  • 690 views
  • 0 likes
  • 2 in conversation