SQL/MP Reference Manual
HP NonStop SQL/MP Reference Manual—523352-013
A-68
AS DATE/TIME Clause
"time-string"
is a string that specifies the method format a time value. It can include blanks,
commas, decimal points, hyphens, periods, slashes, alphanumeric characters
embedded in the time value enclosed in apostrophes and these keywords:
For example, the time formats in these list cause printing of one of the
corresponding values:
DA Monday, Tuesday, ... Sunday
DA3 Mon, Tue, ... Sun
D2 01, 02, ... 31
DB2 1, 2, ... 31
D3 001, 002, ... 366
DB3 1, 2, ... 366
DOB2 1st, 2nd, ... 31st
DAO First, Second, ... Thirty-First
Y2 00, 01, ... 86, 87, 88, ...
YB2 0, 1, ... 86, 87, 88, ...
Y4 1900, 1901, ... 1986, 1987, 1988, ... 2000, 2001, 2002, 2003,2004, ...
H[n] Specifies an hour
M[n] Specifies a minute
S[n] Specifies a second
C[n] Specifies hundredths of a second
T[n] Specifies thousandths of a second
P[n] Expresses the hour as modulo 12 with AM or PM
B[n] Suppresses leading zeros
n An integer that specifies the minimum number of digits to print. It can be
1 or 2 for all keywords but T, and 1 through 3 for T. The default is 1.
Format Values
HB 1, 2, ... 24
HP2 01, 02, ... 12AM or PM
HPB2 1, 2, ..., 12AM or PM
M2 00, 01, ... 59
MB2 0, 1, ... 59
S2 00, 01, ... 59
SB2 0, 1, ... 59
Format Values