Writes date values in the form <yy>yyMmm, where M is a
character separator to indicate that the month number
follows the M and the year appears as either 2 or 4 digits.
Category: |
Date and Time
|
Alignment: |
right
|
-
w
-
specifies the width of the output field.
Default: |
7 |
Range: |
5-32 |
Interaction: |
When w has a value of 5 or 6, the date appears with only the last
two digits of the year. When w is 7 or more,
the date appears with a four-digit year. |
The YYMMw.
format writes SAS date values in the form <yy>yyMmm,
where
-
<yy>yy
-
is a two-digit or four-digit integer that
represents the year.
-
M
-
is the character separator to indicate that
the number of the month follows..
-
mm
-
is an integer that represents the month.
The following examples use the input value of 16734,
which is the SAS date value that corresponds to October 25, 2005.
SAS Statement
|
Result |
|
----+----1----+
|
put date yymm5.;
|
05M10
|
put date yymm6.;
|
05M10
|
put date yymm.;
|
2005M10
|
put date yymm7.;
|
2005M10
|
put date yymm10.;
|
2005M10
|
Copyright © 2011 by SAS Institute Inc., Cary, NC, USA. All rights reserved.