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: trunc

Re: trunc

From: Mark Gumbs <mgumbs--AT--hotmail.com>
Date: Wed, 12 May 1999 16:44:09 +0100
Message-ID: <37399fa6.0@145.227.194.253>


First of all it should be 'HH:MI:SS'. MM is a month format! Also, when using a combination of trunc and the to_char function, the time defaults to 12.00pm

  1* select to_char(trunc(sysdate),'HH:MI:SS') from dual SQL> / TO_CHAR(



12:00:00

HTH Mark

G.H VITTAL wrote in message <373972BE.CB63D362_at_india.hp.com>...
>Whenever we do date comparison I remember using trunc
>command
>if i say
>
>select to_char(trunc(date_field),'HH:MM:SS') from table1
>
>I see only second portion is truncated. But i want to truncate the
>entire time portion i mean i should expect 00:00:00 as the result. How
>do i do this ?
>
>regards
>vittal
>
>
>
Received on Wed May 12 1999 - 10:44:09 CDT

Original text of this message

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