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: Convert date into timestamp before runnin the a query

Re: Convert date into timestamp before runnin the a query

From: leoh <leonardomachado_at_gmail.com>
Date: 28 Apr 2007 08:44:12 -0700
Message-ID: <1177775052.377473.73400@l77g2000hsb.googlegroups.com>

Thank you very much!

On 26 abr, 00:54, DA Morgan <damor..._at_psoug.org> wrote:
> leoh wrote:
> > Hello,
>
> > ==> I have to run the following query
>
> > ---------------
> > select * from tec_t_evt_rep where (date_reception> $begin and
> > date_reception< $end) or (last_modified_time > $begin and
> > last_modified_time < $end)
> > ----------------
>
> > $begin => first timestamp
> > $end => last timestamp
>
> > ==> The problem is, last_modified_time is VARCHAR in the date format
> > dd/mm/yy
>
> > Is it possible to create a query where last_modified_time is converted
> > to timestamp before the query execution? Somenting like :
>
> > select (...) or (convert_timestamp(last_modified_time,'dd/mm/yy')
> > and ...)
>
> It would be better to fix the bad design. But have you looked at
> TO_TIMESTAMP?www.psoug.org
> Click on Morgan's Library
> Click on Built-in Functions at the top of the page
> --
> Daniel A. Morgan
> University of Washington
> damor..._at_x.washington.edu
> (replace x with u to respond)
> Puget Sound Oracle Users Groupwww.psoug.org
Received on Sat Apr 28 2007 - 10:44:12 CDT

Original text of this message

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