EUROXw.d Format
Writes numeric values with a leading euro symbol
(E), a period that separates every three digits, and a comma that
separates the decimal fraction.
Category: |
Numeric |
Alignment: |
right |
Syntax
Syntax Description
- w
-
specifies the width
of the output field.
Default:6
Range:1-32
Tip:If you want the euro symbol to be part of the output,
be sure to choose an adequate width.
- d
-
specifies the number
of digits to the right of the decimal point in the numeric value.
Default:0
Range:0-31
Requirement:must be less than w
Comparisons
-
The EUROX
w.
d format is similar to the
EURO
w.
d format, but EURO
w.
d format reverses the roles of the comma and
the decimal point. This convention is common in English–speaking
countries.
-
The EUROX
w.
d format is similar to the
DOLLARX
w.
d format, except that DOLLARX
w.
d format
writes a leading dollar sign instead of the euro symbol.
Example
These examples use 1254.71
as the value of amount.
|
|
|
----+----1----+----2----+----3
|
|
|
|
|
|
|
|
|
data _null_;
input x;
put x eurox10.2;
put x eurox5.;
put x eurox9.2;
put x eurox15.3;
datalines;
1254.71
; run;
SAS Log:
E1.254,71
1.255
E1.254,71
E1.254,710
/* This code determines the default length. */
data _null_;
input x;
put x eurox.;
datalines;
1
22
333
4444
55555
666666
7777777
88888888
999999999
1234561234
;run;
SAS Log:
E1
E22
E333
E4.444
55.555
666666
7.78E6
8.89E7
1E9
1.23E9
Note: At least one W.D format was
too small for the number to be printed. The decimal may be shifted
by the "BEST" format.