Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Mailing Lists -> Oracle-L -> Re: Handling Daylight Savings Time -Reply

Re: Handling Daylight Savings Time -Reply

From: Powel Crosley <eclipse_at_USIT.NET>
Date: Mon, 29 Jan 1996 12:07:43 -0500
Message-Id: <9601292340.AA13229@alice.jcc.com>


At 08:36 AM 1/29/96 -0600, Andrew McAllister wrote:
>This one is easy:
>
>Quit using compound primary keys (or unique keys)
>and switch to an arbitrary primary key.
>

        I concur with PRIMARY KEYS, but there may be a need for UNIQUENESS
        based on datetime!  PRIMARY KEYS that are arbitrary sequences simplify
        table joins and reduce space requirements (usually).  AND they eliminate
        ALL database ripples that result from a key field update! (Of course
that
        should never happen anyway?)

>
>Add an arbitrary number generated with a sequence
>and a trigger to your unique constraint (in
>addition to or instead of the time column) and you
>won't have to worry about any time screw up.
>

        BE SURE TO HAVE THE ORDER CLAUSE ON THE CREATE SEQUENCE STATEMENT IF THAT IS
        IMPORTANT! Otherwise numbers are not guaranteed in order!

>>>> TSAWMILL.US.ORACLE.COM
><TSAWMILL_at_US.ORACLE.COM> 01/24/96 03:58pm >>>
>Has anybody come up with a good method to handle
>Daylight Savings Time
>"anomalies"?

        How about including timezone in the key?

Regards,

Powel Crosley                                 423.483.1939 Voice
Eclipse Technology, Inc.                      423.483.1873 Fax
118 East Division Rd., Oak Ridge, TN 37830 Received on Mon Jan 29 1996 - 18:40:11 CST

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US