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

Home -> Community -> Usenet -> c.d.o.server -> Time-only column techniques

Time-only column techniques

From: Rick Jones <rick.jones_at_kaisertwd.com>
Date: 1998/02/04
Message-ID: <886462155.1739194378@dejanews.com>#1/1

Since Oracle doesn't support a "TIME" datatype, I'm wondering whether there is a commonly-used workaround within the Oracle community.

My goal is for the columns to be eligible for datetime arithmetic, date functions, and for the optimizer to be able to use indexes when evaluating "time" predicates. I don't believe the "columnname - trunc(columname)" technique for extracting just the "TIME" portion of any DATE column would be a good solution.

With that in mind, I'm assuming we should use a DATE datatype and store a locally agreed upon constant (eg, 01-JAN-0001) into the "date" portion. However, I would appreciate hearing other suggestions.

-------------------==== Posted via Deja News ====-----------------------
      http://www.dejanews.com/     Search, Read, Post to Usenet
Received on Wed Feb 04 1998 - 00:00:00 CST

Original text of this message

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