Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.misc -> Re: Time difference between records
Assume time has both time and date stamp. I'm working with 9i.
"Hans Forbrich" <forbrich_at_yahoo.net> wrote in message
news:iTD1d.25738$XP3.5894_at_edtnps84...
> Scott Johnson wrote:
>
> > I need to find a method (sql, plsql) to find the time difference between
> > records
> >
> > Example,
> > Ticket# Operation Time
> > A1 Modify 1000
> > A1 Modify 1100
> > A1 Modify 1300
> > A2 Modify 0900
> > A2 Modify 0930
> >
> > Should produce something like:
> >
> > A1 1 hour
> > A1 2 hours
> > A2 30 minutes
> >
> > Has anyone done this before?
>
> 1) Ain't going nowhere if you don't capture a 'modified date/time' stamp.
>
> 2) Different database version provide different capabilities to help here.
>
> 3) In 10g look up the time interval datatype, otherwise look up date
> arithmetic, both in the SQL Reference manual.
Received on Tue Sep 14 2004 - 10:35:06 CDT
![]() |
![]() |