In SAS under Windows, character values are sorted using the ASCII collating sequence. As an alternative to the numeric dummy variables discussed previously, you can choose a character variable with a length of 1 byte to serve the same purpose.
The maximum number of variables in a single SAS data set under Windows is 32,767. In addition, an observation under Windows cannot be longer than 5M. Therefore, if you want your data set to contain 32,767 character variables, the longest each variable can be is 160 bytes.
However, a DATA step can reference more than 32,767 variables, if you write only 32,767 or fewer variables to the data set. For example, you could drop some variables with a DROP= data set option. The maximum number of variables a DATA step can reference under Windows is 2,147,483,647.