FrontBase logo

FrontBase Documentation

FrontBase logo

Backtrack:
  Welcome!
    5. SQL 92
      5.1. SQL 92 Primer
Updated: 20-Nov-2000
prevnext
Table of Contents

5.1.5. Date and Time Types

SQL 92 has an elaborate time concept which includes the following datatypes:

DATE
TIME
TIME WITH TIME ZONE
TIMESTAMP
TIMESTAMP WITH TIME ZONE

DATE holds year, month and day, i.e. NO time components.
TIME holds hour, minute, and second.
TIMESTAMP holds year, month, day, hour, minute, and second.

When a TIME or TIMESTAMP literal is inserted into a database, the server's time zone is added to the literal. Example: If the server is running in Denmark and it is August, the server's time zone is GMT+02:00. If TIMESTAMP '1999-08-02 11:49:00' is inserted, the literal is thus adjusted with +02:00. If, however, TIMESTAMP '1999-01-02 11:49:00' is inserted, the literal is adjusted with +01:00 (because there is no daylight savings in January).

If you want to be in full control over the time zones, you should use the TIMESTAMP WITH TIME ZONE datatype. Example: TIMESTAMP '1999-08-02 11:49:00-08:00'.

The same comments apply to TIME and TIME WITH TIME ZONE.


If you have feedback or questions on this document, please send e-mail to doc-feedback@frontbase.com. Please reference the section number and topic. Thanks!!

©2000 FrontBase, Inc. All rights reserved.