Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.server -> Help needed with Date Functions
Hi
Can someone tell me how to find the difference in seconds between two dates - is there an equivalent to the Transact SQL function:
datediff(ss,date1,date2).
By the way I fell in to the nasty trap of thinking
to_number(to_char(date1,'ss')) - to_number(to_char(date2,'ss'))
would do the trick but soon released that this only looks at the seconds of each date and calculates the difference between that!
Help appreciated.
Paul Received on Mon Apr 19 1999 - 06:08:03 CDT