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

Home -> Community -> Usenet -> c.d.o.misc -> Re: Date datatype in index - performance

Re: Date datatype in index - performance

From: Maarten Geurts <mgeurts_at_tip.nl>
Date: Wed, 15 Jul 1998 23:11:29 +0200
Message-ID: <35AD1B00.94980BB5@tip.nl>


In you example it is converted once. And the lookup can still happen through the index. The only thing to watch out for is the fact that the date field is really an date-time field. If you insert using to_date('19980709','YYYYMMDD') always there is no problem, insert ...,sysdate,.... includes time so the primary key is seldom unique.

success.

bbristol_at_my-dejanews.com wrote:

> We have tables that have 50-80 million rows in them that have a seven-column
> concatenated primary key.

> Example:
>
> select * from my_table
> where table_date = to_date('19980709','YYYYMMDD');
>
> Wouldn't Oracle simply convert the to_date piece once?
>
> Thank you!
>
> -Bruce Bristol
> bbristol_at_oanservices.com
>
> -----== Posted via Deja News, The Leader in Internet Discussion ==-----
> http://www.dejanews.com/rg_mkgrp.xp Create Your Own Free Member Forum
Received on Wed Jul 15 1998 - 16:11:29 CDT

Original text of this message

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