cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Check out the JMP® Marketplace featured Capability Explorer add-in
Choose Language Hide Translation Bar
LNitz
Level IV

Instructions in JSL manual do not quite transfer SAS formats when importing file to JMP

I followed TXNelson's suggested strategy for importing formatted SAS files to JMP.

 

I have a formatted SAS file of a Canadian census.  The SAS program is open, and the file and the format library are indicated in the library contents list.  The file, when opened in the browser, shows all the formats that have been generated and archived in the format library.

I import from  JMP with the following statement, in  a JMP script window:

sas import data("Canada","pumf2016",convertcustomformats(1))

 

The file imports, and the ColumnInfo shows that there is a format assigned, but the formats do not appear as JMP value labels. I am clearly doing something wrong, but cannot quite figure out what.  I am using the instructions on p. 224 of the  JSL syntax reference.  Thanks!

1 ACCEPTED SOLUTION

Accepted Solutions
LNitz
Level IV

Re: Instructions in JSL manual do not quite transfer SAS formats when importing file to JMP

I found this script to work:

From JSL window:

sas connect("", connect libraries(1));

current sas connection()

sas assign lib refs("canada","C:\Users\lnitz\NewDownloads\2016_Ind_98M0001X")

sas get lib refs();

*sas options fmtsearch=(Canada work library);      /* stop before this line */

sas import data("Canada","pumf2016",convertcustomformats(1))

 

Submit the "sas options line, starting with 'opltions' to the SAS program window.  Then come back and run the import line.   The target file was already created in the Canada directory.   Most of the grief of the procedure was due to dozens of error calls that 127.0.0.1 could not be found, did not have SAS, or that the machine name was wrong.  By giving no machine name in the connect statement, the procedure ran.  I suspect that there may be something wrong with my installation, but the error call for 127.0.0.1 is very common, so it may not just be my machine.

View solution in original post

2 REPLIES 2
Phil_Kay
Staff

Re: Instructions in JSL manual do not quite transfer SAS formats when importing file to JMP

@txnelson - can you help?

LNitz
Level IV

Re: Instructions in JSL manual do not quite transfer SAS formats when importing file to JMP

I found this script to work:

From JSL window:

sas connect("", connect libraries(1));

current sas connection()

sas assign lib refs("canada","C:\Users\lnitz\NewDownloads\2016_Ind_98M0001X")

sas get lib refs();

*sas options fmtsearch=(Canada work library);      /* stop before this line */

sas import data("Canada","pumf2016",convertcustomformats(1))

 

Submit the "sas options line, starting with 'opltions' to the SAS program window.  Then come back and run the import line.   The target file was already created in the Canada directory.   Most of the grief of the procedure was due to dozens of error calls that 127.0.0.1 could not be found, did not have SAS, or that the machine name was wrong.  By giving no machine name in the connect statement, the procedure ran.  I suspect that there may be something wrong with my installation, but the error call for 127.0.0.1 is very common, so it may not just be my machine.