SAS OnlineTutor HomeFAQ PageSuggested Learning PathsContents+Searchback||next

Basic Concepts
SAS Data Sets


Variable Attributes: Name

Each variable has a name that conforms to SAS naming conventions. Variable names must

  • be 1 to 32 characters in length
  • begin with a letter (A-Z, including mixed case characters) or an underscore (_)
  • continue with any combination of numbers, letters, or underscores.

In the example below, the variable names are Policy, Total, and Name.


Variable Type Length Format Informat Label
Policy Num
8

Policy Number

Total Num
8
DOLLAR8.2 COMMA10. Total Balance
Name Char
20
Patient Name


These are additional examples of valid variable names:

  • Height
  • GLUCOSE_TOLERANCE_READING
  • AmountBudgeted_1999

Note: Your site may choose to restrict variables names to those valid in Version 6 SAS software, to uppercase variable names automatically, or to remove all restrictions on variable names.


back||next


Copyright © 2002 SAS Institute Inc., Cary, NC, USA. All rights reserved.

Terms of Use & Legal Information | Privacy Statement