Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.misc -> Re: Alternative to a correlated query?
HI Conan
>Create a cursor that returns a rows for
>that partner, sorted by date descending.
>Fetch the first row. you now have
>the rowid of the record you need.
I tried using rowid (rownum) but it seems that in oracle, the row num is deciphered *while* the SELECT is executing, so row ids are assigned before the ordering of the records! Which means that once the returned rows are ordered, row ids become mangled and hence, useless.
I havent tried creating a "cursor" or a function -- would it be possible for you to gimme a small example of what kind of a function you wrote? I also wonder if something on the DB server side would really help me too much as I am using a visual IDE to access this SQL! (Powerbuilder)
Much appreciated!
Regards
Shanx
Its better to waste your youth than to do nothing with it.
Shashank Tripathi
http://shanx.com
Received on Wed Oct 27 1999 - 20:19:10 CDT
![]() |
![]() |