Usage Note 22189: Is it possible to edit an existing user-defined format?
User-defined formats cannot be edited. You will need to re-create the format with the changes in place. The easiest way to do this is to edit and submit the original source code. If you no longer have the original source code, create an output data set from PROC FORMAT using the CNTLOUT= option. You can then make the appropriate changes to this data set and use it to rebuild the format with the CNTLIN= option.
The following example uses the CNTLOUT= and CNTLIN= options to update a format:
/* Create a sample format */
proc format;
value id 1='Mary'
2='Tom'
3='Joe';
run;
/* The CNTLOUT= option creates an output data set from an existing format */
proc format cntlout=outfmt;
select id;
run;
/* Create a new data set that includes the values */
/* from OUTFMT as well as a new format label. */
data newfmt;
length label $ 20;
retain start;
set outfmt end=last;
output;
if last then do;
start=4;
end=4;
label='New Employee';
output;
end;
run;
/* The format is re-created using the CNTLIN= option to point to the */
/* new data set containing the updated information for the old format */
proc format cntlin=newfmt fmtlib;
run;
Operating System and Release Information
*
For software releases that are not yet generally available, the Fixed
Release is the software release in which the problem is planned to be
fixed.
Type: | Usage Note |
Priority: | low |
Topic: | SAS Reference ==> Procedures ==> FORMAT
|
Date Modified: | 2014-05-02 13:46:11 |
Date Created: | 2002-12-16 10:56:34 |