Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.server -> Re: hi all
On Oct 3, 11:26 pm, "fitzjarr..._at_cox.net" <fitzjarr..._at_cox.net> wrote:
> <cacophony snipped>
> It appears from this:
>
> java.sql.SQLException: Exhausted Resultset
>
> you likely haven't gotten the first row and the pointer is sitting at
> the on-before-first element. A next() call should fix the problem.
David! You're still thinking procedurally!
What he needs is an iterator class with polymorphic
capability, so that he can very simply do:
ResultSet
rs=stmt.next.row.in.Query.without.any.concern.for.reality(query);
of course, it is highly recommended that a specific framework be specially developed for for all queries of this type of SQL which
may return more than one row. In fact, the ideal would be a specific: ResultSet rs=stmt.row.number. (var).in.Query.of.very.large.table(query);then the iterator simply calls the appropriate value of var while it is
then again, the ideal would be to cache the whole lot: any of this database stuff only slows down the code!
</tongue-in-cheek> Received on Thu Oct 04 2007 - 08:51:05 CDT
![]() |
![]() |