| Transforming Data with SAS Functions | |
| Converting Data with Functions |
|
| Automatic Numeric-to-Character Conversion
The automatic conversion of numeric data to character data is very similar
to character-
For example, the numeric values of the variable
Numeric-to-character conversion also causes a message to be written to the
SAS log indicating that the conversion has occurred. |
SAS Log
4 data hrd.newtemp;
5 set hrd.temp;
6 SiteCode=site||department;
7 run;
---> NOTE: Numeric values have been converted
to character values at the
places given by: (Line):(Column).
11:13
|
| But remember, it's best not to rely on automatic conversion. When you know that numeric data must be converted to character data, perform an explict conversion by including a PUT function in your SAS program. We look at the PUT function in the next section. |
![]() ![]() |
|
Copyright © 2002 SAS Institute Inc.,
Cary, NC, USA. All rights reserved.