Writes numeric data in zoned decimal format
| Category: |
Numeric
|
| Alignment: |
left
|
-
w
-
specifies the width of the output field.
-
d
-
optionally specifies to multiply the number
by 10d.
The zoned decimal format is similar to standard numeric
format in that every digit requires one byte. However, the value's sign is
in the last byte, along with the last digit.
Note:
Different
operating environments store zoned decimal values in different ways. However,
the ZDw.d format
writes zoned decimal values with consistent results if the values are created
in the same kind of operating environment that you use to run SAS.
The following table compares the zoned decimal format
with notation in several programming languages:
y=put(x,zd4.);
put y $hex8.;
|
Values |
Results* |
120
|
F0F1F2C0
|
| *The result is a hexadecimal representation of a binary
number in zoned decimal format on an IBM mainframe computer. Each byte occupies
one column of the output field. |
Copyright © 1999 by SAS Institute Inc., Cary, NC, USA. All rights reserved.