Chapter Contents

Previous

Next
S370FPDw.d

S370FPDw.d



Writes packed decimal data in IBM mainframe format

Category: Numeric
Alignment: left


Syntax
Syntax Description
Details
Comparisons
Examples

Syntax

S370FPDw.d

Syntax Description

w
specifies the width of the output field.
Default: 1
Range: 1-16

d
optionally specifies to multiply the number by 10d.


Details

Use S370FPDw.d in other operating environments to write packed decimal data in the same format as on an IBM mainframe computer.


Comparisons

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


Examples

y=put(x,s370fpd4.);
put y $hex8.;

Values 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.


Chapter Contents

Previous

Next

Top of Page

Copyright 1999 by SAS Institute Inc., Cary, NC, USA. All rights reserved.