B8601DAw. Informat

Reads date values that are specified using the ISO 8601 base notation yyyymmdd.
Categories: Date and Time

ISO 8601

Alignment: left
Alias: ND8601DA
Restriction: UTC time zone offset values are not supported.
Supports: ISO 8601 Element 5.2.1.1, complete representation

Syntax

B8601DAw.

Syntax Description

w
specifies the width of the input field.
Default:10
Requirement:The width of the output field must be 10.

Details

The B8601DA informat reads date values that are specified using the ISO 8601 basic date notation yyyymmdd:
yyyy
is a four-digit year.
mm
is a two-digit month (zero padded) between 01 and 12.
dd
is a two-digit day of the month (zero padded) between 01 and 31.
If the month or day values are omitted, SAS uses a value of 1 for the month or day. If the hour, minute, or second values are omitted, SAS uses a value of 0 for the hour, minute, or second.

Example

input @1 bda b8601da.;
Data Line
Result
Formatted Using B8601DA Format
----+----1
20120915
19251
20120915
2012
18993
20120101