Date: Wed, 23 Feb 2011 11:33:58 -0500
Reply-To: Mike Rhoads <RHOADSM1@WESTAT.COM>
Sender: "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From: Mike Rhoads <RHOADSM1@WESTAT.COM>
Subject: NOFMTERR no longer needed when formats are unavailable?
Content-Type: text/plain; charset="us-ascii"
Folks,
For many years now, I have been under the impression that the NOFMTERR system option was the only practical way to deal with situations where a SAS data set had user-created formats associated with some or all variables, and the corresponding format catalog was not available.
However, one of my Westat colleagues recently brought the following to my attention:
JOB 1 (create a data set and associate a user-written format with a variable)
libname library 'c:\junk\';
proc format library=library;
value $sexf
'M' = 'Male'
'F' = 'Female'
;
data library.class;
set sashelp.class;
format sex $sexf.;
run;
JOB 2
1 libname junk 'c:\junk\';
NOTE: Libref JUNK was successfully assigned as follows:
Engine: V9
Physical Name: c:\junk
2
3 %PUT Value of FMTERR option is %sysfunc(getoption(fmterr));
Value of FMTERR option is FMTERR
4 data tempclass;
5 set junk.class;
6 format _ALL_;
7 run;
NOTE: There were 19 observations read from the data set JUNK.CLASS.
NOTE: The data set WORK.TEMPCLASS has 19 observations and 5 variables.
As the saying might go, "Look, Ma, no errors or warnings!" format sex; also works.
Did this always work, meaning that I am losing brain cells much more rapidly than I had feared? Or is this a relatively new development? (This was run using SAS 9.1.3 under WinXP.)
Mike Rhoads
RhoadsM1@Westat.com