SAS XML versus Transport File Differences

Data files exported to SAS XML format are generally the same as data exported to the SAS Transport file format, with the following exceptions:

  • XML files are compatible with SAS v8 and higher and support variables names up to 32 characters.
  • For Date variables that are “Year-Month Only” where the respondent entered a month, the composite variable is exported as “Month-Year”—e.g., Feb1999—and is displayed in SAS XML file format as 01Feb1999, instead of a date 60 years in the future.
  • For Date variables that are “Full Date” or “Year-Month Only” and either day, or both month and day, are missing, the composite variable is exported as a missing value, “.”, instead of as a date 60 years in the future.
  • For Date and Time variables that contain special codes, the composite variable is exported as a missing value, “.” Rather than a numeric value, such as 2097 or 28Sep1965. These responses can also be output as “.D” or “.R”, by using the appropriate recode option before exporting.
  • The naming of value labels in the <filename>_Fmt file is similar to the approach used in the Design Studio when generating the Codebook values .CSV file where the label name matches the name of the first variable in the survey that contains the specific set of values.
  • The SAS file is very similar to the .SAS file that’s generated by the SAS Format Library Program option; however, each variable is on its own line with the corresponding format name.