Usage Note 4885: The TRANSPOSE procedure creates variable names that begin with numbers
When using the TRANSPOSE procedure prior to SAS® 8, if an ID variable's value starts with a number, the output data set variable names begin with an underscore (_).
The VALIDVARNAME=ANY system option now allows the creation of variables that start with numbers. These are called name literals. When referencing these variables, the following syntax is employed: 'xxxx'n (where xxxx is a number like 5001). If the system option is set to VALIDVARNAME=ANY and PROC TRANSPOSE encounters an ID variable whose value starts with a number, the resulting variable name will not be preceded with the underscore character.
If you want the variables that are created by the TRANSPOSE procedure to conform to the rules that were in place prior to SAS 8, set the option to either VALIDVARNAME=V7 or VALIDVARNAME=V6 before the TRANSPOSE procedure step, or add PREFIX=_ to your PROC TRANSPOSE statement. Using VALIDVARNAME=V7 will allow variable names up to 32 characters long, but it will still require that all variable names begin with an alphabetic or an underscore character. Using VALIDVARNAME=V6 will add the additional requirement that variable names be no longer than 8 characters.
Operating System and Release Information
SAS System | Base SAS | Solaris | 8 TSD1 | |
OpenVMS VAX | 8 TSD1 | |
64-bit Enabled Solaris | 8 TSD1 | |
IRIX | 8 TSD1 | |
HP-UX | 8 TSD1 | |
ABI+ for Intel Architecture | 8 TSD1 | |
z/OS | 8 TSD1 | |
CMS | 8 TSD1 | |
64-bit Enabled AIX | 8 TSD1 | |
64-bit Enabled HP-UX | 8 TSD1 | |
OpenVMS Alpha | 8 TSD1 | |
Tru64 UNIX | 8 TSD1 | |
AIX | 8 TSD1 | |
*
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: | |
Topic: | SAS Reference ==> Procedures ==> TRANSPOSE
|
Date Modified: | 2001-05-29 15:14:22 |
Date Created: | 2001-05-02 15:02:19 |