SQL/MX 2.x Installation and Management Guide (G06.24+, H06.03+)

Creating an SQL/MX Database
HP NonStop SQL/MX Installation and Management Guide523723-004
7-26
Managing Table Data
The maximum value of DAY depends on the length of the month.
A column value of type INTERVAL is made up of these contiguous fields:
An INTERVAL column is defined to have a range of these contiguous fields, specified
by a required start-date-time field and an optional end-date-time field. You can specify
a precision for any start-date-time field.
Guidelines for Date and Time Interval Data
When you define a column to hold date and time, date, time, or time interval values,
use these general guidelines:
A column of the DATE, TIME, or TIMESTAMP type holds a value that represents a
date or an instant in time, and a column of the INTERVAL type holds a value that
represents a time interval, or duration.
MINUTE Minutes of hour 00 to 59
SECOND
*
Second of minute 00 to 59
*
The SECONDS field can have an optional fractional part of from zero to
six digits in length.
YEAR Number of years Not constrained
MONTH Number of months Constrained to 01 through 12 if
a YEAR field value is present
but is otherwise not
constrained
or
DAY Number of days Not constrained
HOUR Number of hours 00 to 23. Constrained only if
the DAY field value is present.
MINUTE Number of minutes 00 to 59. Constrained only if
the HOUR field value is
present.
SECOND
*
Number of seconds 00 to 59. Constrained only if
MINUTE field value is present.
*
The SECOND field can have an optional fractional part of from zero to six
digits in length.
Note. NonStop SQL/MX does not support the use of columns of the SQL/MP type DATETIME
in SQL/MX tables or views. However, you can use SQL/MX datetime functions to select
individual fields from any DATETIME column in an SQL/MP table except FRACTION-only. For
information about using SQL/MX datetime functions on DATETIME data, see the SQL/MX
Reference Manual.