Previous Page | Next Page

SAS Formats under Windows

ZDw.d Format: Windows



Writes zoned decimal data.
Category numeric
Width range: 1-32
Default width: 1
Decimal range: 1-10
Alignment: left
Windows specifics: Last byte includes the sign.
See: ZDw.d in SAS Language Reference: Dictionary

Syntax
Details
Examples
Example 1: Processing a Number That Is Too Large To Format
See Also

Syntax

ZDw.d

w

specifies the number of bytes (not the number of digits).

d

specifies the number of digits to the right of the decimal point in the numeric value.


Details

The ZDw.d format writes zoned decimal data. This method is also known as an overprint trailing numeric format. In the Windows operating environment, the last byte of the field contains the sign information of the number. The following table gives the conversion for the last byte.

Digit ASCII Character Digit ASCII Character
0 { -0 }
1 A -1 J
2 B -2 K
3 C -3 L
4 D -4 M
5 E -5 N
6 F -6 O
7 G -7 P
8 H -8 Q
9 I -9 R


Examples


Example 1: Processing a Number That Is Too Large To Format

When a numeric value is too large to format, as in this example

data a;
   x = 1e308;
   y = put(x, ZD32.2);
   put y = hex16.;
run;

the result is a sequence of 39s:

y=3939393939393939


See Also

Previous Page | Next Page | Top of Page