Previous Page | Next Page

Informats

DATEw. Informat



Reads date values in the form ddmmmyy or ddmmmyyyy.
Category: Date and Time

Syntax
Syntax Description
Details
Examples
See Also

Syntax

DATEw.

Syntax Description

w

specifies the width of the input field.

Default: 7
Range: 7-32
Tip: Use a width of 9 to read a 4-digit year.

Details

The date values must be in the form ddmmmyy or ddmmmyyyy, where

dd

is an integer from 01 through 31 that represents the day of the month.

mmm

is the first three letters of the month name.

yy or yyyy

is a two-digit or four-digit integer that represents the year.

You can separate the year, month, and day values by blanks or by special characters. Make sure the width of the input field allows space for blanks and special characters.

Note:   SAS interprets a two-digit year as belonging to the 100-year span that is defined by the YEARCUTOFF= system option.  [cautionend]


Examples

input calendar_date date11.; 

Data Line Results
----+----1----+

16mar99
14319
16 mar 99
14319
16-mar-1999
14319


See Also

Format:

DATEw. Format

Function:

DATE Function

System Option:

YEARCUTOFF= System Option

Previous Page | Next Page | Top of Page