SAS Writing
Previous Topic  Next Topic 

Write PROC FORMAT program


Stat/Transfer can optionally write a PROC FORMAT program that you can use to import value labels from other systems into SAS.  To turn on this option, check the Write a Proc Format Program box.


The program file will by default be written to the same directory as your output data file, with the same name as your output file, but with the extension .sas.  You can change this default in the Filename edit box. You can type in a complete file specification, or you can use the macros below as part of the file specification.


%opath%  The path, including the directory of the output file

%oname%  The name, without the extension, of the output file

%oext%  The extension, without the dot, of the output file

Write SAS Catalog


Stat/Transfer can write value labels to native Windows SAS catalog files. To turn on this option, check the Write SAS Catalog box.


The program file will by default be written to the same directory as your output data file, with the same name as your output file, but with the extension .sas7bcat.  You can change this default in the Filename edit box. You can type in a complete file specification, or you can use the macros below as part of the file specification.


%opath%  The path, including the directory of the output file

%oname%  The name, without the extension, of the output file

%oext%  The extension, without the dot, of the output file


Note that if your catalog has the same name as your file (the default) you will need to tell SAS how to find it.   Alternatively, if you name it formats.sas7bcat, SAS will find it automatically, but you should be cautious not to over-write an existing format file with the default name.


SAS Data Representation


SAS files differ depending on the platform on which they are written.  Although SAS can generally read files written on platforms other than the one on which it is running, such reads are generally less efficient than reading the native format.  Stat/Transfer lets you chose from  a variety of "output representations".  The value for these are equivalent to those used by the SAS OUTREP= command.


You should chose the one that is most appropriate for the platform on which you are using your output file.


Date, Time and DateTime Formats


You can choose the formats that Stat/Transfer will use when writing date, time, datetime variables.  You can enter a value for each of these formats.  The formats will be validated when click on another tab and the widths will be set to the SAS default width for each valid format.

Write SAS Extended Attributes

If this option is checked and the input file contains extended attributes, Stat/Transfer will write them to a SAS  an additional file that contains the extended attribute.  This file will have the extension  .sas7xdat and have the same name and path as the output SAS file.   Extended attributes are supported by SAS version 9.4 and above.