Writes packed decimal data in IBM mainframe format.
Category: |
Numeric
|
Alignment: |
left
|
-
w
-
specifies the width of the output field.
-
d
-
specifies to multiply the number by 10d. This argument is optional.
Use S370FPDw.d in other operating environments to write packed decimal
data
in the same format as on an IBM mainframe computer.
The following table shows the notation
for equivalent packed decimal formats in several programming languages:
Language |
Packed Decimal Notation |
SAS |
S370FPD4. |
PL/I |
FIXED DEC(7,0) |
COBOL |
COMP-3 PIC S9(7) |
IBM 370 assembler |
PL4 |
y=put(x,s370fpd4.);
put y $hex8.;
Value of x |
Results |
|
----+----1
|
128
|
0000128C
|
*
The result is a hexadecimal representation of a binary
number written in packed decimal format. Each byte occupies one column of
the output field. |
Copyright © 2011 by SAS Institute Inc., Cary, NC, USA. All rights reserved.