Re: Time problem

[email protected]
Newsgroups gmane.comp.db.oracle.devel
Message-ID <LYRIS-1796914-786976-2002.12.02-09.52.27--gcdod-oracle#[email protected]>
if you minus one date field from one other then you get the time difference
in days.

like this

  1* create table mydates ( xxx date)
SQL> /

Table created.

SQL> insert into mydates values ( to_date('02-dec-2002 09:55','dd-mon-yyyy
hh24:mi'));

1 row created.

SQL> select sysdate - xxx from mydates;

SYSDATE-XXX
-----------
 -.00407407


then you can do some formating on the number returned




                                                                                                 
                      waseem altaf                                                               
                      <[email protected].        To:       "Oracle" <[email protected]>          
                      pk>                      cc:                                               
                                               Subject:  [oracle] Time problem                   
                      30/11/2002 07:22                                                           
                      Please respond to                                                          
                      "Oracle"                                                                   
                                                                                                 
                                                                                                 




hi
 i am new to oracle. how i get the difference between two time in query.
 if two field "fromtime" and "totime" store the  time corecectly and field
type is date. but problem is how i get the difference between two time any
seggestion or code
                           thanks


_____________________________________________________________
Get 100% private, FREE email for life!
Visit http://inbox.com.pk

_____________________________________________________________
Select your own custom email address for FREE! Get [email protected] w/No
Ads, 6MB, POP & more! http://www.everyone.net/selectmail?campaign=tag

---
Change your mail options at http://p2p.wrox.com/manager.asp or
to unsubscribe send a blank email to %%email.unsub%%.






---
Change your mail options at http://p2p.wrox.com/manager.asp or 
to unsubscribe send a blank email to [email protected].
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.