DTYYQCw. Format

Writes the date part of a SAS datetime value as the year and the quarter, and separates them with a colon (:).

Category: Date and Time
Alignment: Right

Syntax

DTYYQCw.

Arguments

w

specifies the width of the output field.

Default 4
Range 4–6

Details

The DTYYQCw. format writes SAS datetime values in the form yy or yyyy, followed by a colon (:) and the numeric value for the quarter of the year.

Example

The example table uses as input the value 1678898894, which is the SAS datetime value that corresponds to March 14, 2013, at 04:48:52 PM.
Statements
Results
----+----1
select put(1678898894,dtyyqc.);
13:1
select put(1678898894,dtyyqc4.);
13:1
select put(1678898894,dtyyqc5.);
 13:1
select put(1678898894,dtyyqc6.);
2013:1

See Also