File [filename] was created for a different operating system.

Accepted Solution Solved
Reply
Occasional Contributor
Posts: 8
Accepted Solution

File [filename] was created for a different operating system.

Hi -- I am using SAS University Edition (essentially UNIX operating environment), and am trying to apply a previous formats.sasb7cat file to a new library....

libname current_lib '/folders/myfolders/current_lib/';

proc format library=current_lib cntlin=currentlib_lib.formats;

run;


I get the error that the formats file was created for a different operating system:


ERROR: File LIBRARY.FORMATS.CATALOG was created for a different operating system.

I've been told, however, that if the file is in .sasb7cat format, it should be UNIX/Linux, but it is still not... importing? for the new library.

I already referenced this SAS page, last block of code, to try to answer this question, but it was a little vague on how referencing the libraries worked. 

I want to get the formats file from the current library and source it back in to that same library, so I only defined one library, instead of two, as in the example.

Thanks so much,
Kim


Accepted Solutions
Solution
‎07-11-2015 02:31 AM
Super User
Posts: 10,023

Re: File [filename] was created for a different operating system.

That is to say this format is build under another OS. You should run cntlout= at the same machine which creating this format .

View solution in original post


All Replies
Super User
Posts: 10,023

Re: File [filename] was created for a different operating system.

If I am right , Using proc cimport + proc cport to transport format .

Another way is using proc format + cntlout=  to make a dataset , then move it to your UE and run again proc format + cntlin= .

Occasional Contributor
Posts: 8

Re: File [filename] was created for a different operating system.

Hi Xia -- thanks for answering!

I tried the second method:

  libname testlib  '/PATH/';

  proc format library=testlib cntlout=testlib.formats2;  * reads formats.sasb7cat and writes to formats2.sasb7cat for export;

  proc format library=testlib cntlin=testlib.formats2; run; *imports formats2.sasb7cat as new format file for library;

For line 2 (cntlout) I basically get the same error:

ERROR: File TESTLIB.FORMATS.CATALOG was created for a different operating system.

It could be because I am trying to read and write the formats files in the same library, but I suspect it isn't that....

I will try the first method now....  Smiley Happy

Solution
‎07-11-2015 02:31 AM
Super User
Posts: 10,023

Re: File [filename] was created for a different operating system.

That is to say this format is build under another OS. You should run cntlout= at the same machine which creating this format .

Occasional Contributor
Posts: 8

Re: File [filename] was created for a different operating system.

Thanks, Xia!!  Well, that is a problem, since I don't have access to the old machine.  Now I know I have to find another way....

Thanks again!

🔒 This topic is solved and locked.

Need further help from the community? Please ask a new question.

Discussion stats
  • 4 replies
  • 958 views
  • 3 likes
  • 2 in conversation