db-derby-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Bernt M. Johnsen" <Bernt.John...@Sun.COM>
Subject Re: [PATCH] (DERBY-276) ResultSet.relative(int row) cannot be called when the cursor is not positioned on a row.
Date Fri, 27 May 2005 13:00:26 GMT
Comment: EmbeddedDriver relative() gives exception when the resultset
is empty, but this was not introduced by this patch:

Exception in thread "main" org.apache.derby.iapi.services.sanity.AssertFailure: ASSERT FAILED
hashRowArray expected to be non-null
    at org.apache.derby.iapi.services.sanity.SanityManager.ASSERT(SanityManager.java:121)
   at org.apache.derby.impl.sql.execute.ScrollInsensitiveResultSet.getRowFromHashTable(ScrollInsensitiveResultSet.java:911)
        at org.apache.derby.impl.sql.execute.ScrollInsensitiveResultSet.getRelativeRow(ScrollInsensitiveResultSet.java:340)
     at org.apache.derby.impl.jdbc.EmbedResultSet.movePosition(EmbedResultSet.java:366)
      at org.apache.derby.impl.jdbc.EmbedResultSet.relative(EmbedResultSet.java:1840)
 at Relative.main(Relative.java:30)

Correct behvaiour would most likely be to return false (as long as
relative() should be equivalent to next()/previous().


-- 
Bernt Marius Johnsen, Database Technology Group, 
Sun Microsystems, Trondheim, Norway

Mime
View raw message