Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.tools -> Re: cunning SQL query required
"Mathew" <sheemat_at_yahoo.com> wrote in message
news:3AA52B78.90303_at_yahoo.com...
> Hope I understood this correctly.
> If use an inline view to get the "current" view of the table, that
> probably should help
>
> thats
> select <whatever>
> from
> (select oid,status from table1 A
> where time = (select max(time) from Table1 B where A.oid=B.oid)))
> where condition.
>
> Will this work?
<big smile>you're a star!</big smile>
I was having trouble getting my head round the reflexive joining and kept getting either nothing or everything returned.
cheers, you've definitely won a pint if you're ever near Cambridge UK. Received on Tue Mar 06 2001 - 12:57:53 CST