Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Time Calculation

Status
Not open for further replies.

zee1527

Programmer
May 20, 2003
5
GB
Hi Friends

I need a bit of a help from the scratch i want to substract time e.g 1:25pm -5:00am can i any body help me and told me how i suppose to do it in form6i i'll really appreciate
Thanks
 
There's no such thing as TIME in Oracle. Though, if both dates are within the same day, I suppose the result may suit your needs. You may explicitly subtract DATEs and obtain result in days. Just multiply it by 24, and it will represent the period in hours, etc.

to_date('1:25pm','hh:miAM')-
to_date('5:00am','hh:miAM')=,350694444

,350694444*24=8,41666667
,41666667*60=25

Regards, Dima
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top