Java Solaris Communities Sun Store Join SDN My Profile Why Join?
 
Bug Database
Bug Detail
Quick Lists
Top 25 Bugs
Top 25 RFE's
Recently Closed Bugs
Printable Page Printable Page


Bug Database
Bug ID: 6459029
Votes 0
Synopsis Attempt to close Query object after closing DataSet throws NPE
Category jdbc:eod
Reported Against
Release Fixed mustang(b98)
State 10-Fix Delivered, bug
Priority: 2-High
Related Bugs
Submit Date 10-AUG-2006
Description
After closing a DataSet, an attempt to close the associated Query  customer  throws a NPE, even though the isClosed() method of the Query  customer  returns false.

The attached test case produces the following output:

Dropping table...
Creating table...
Closing DataSet addressesDS.
Is addressesDS closed? true
Is Query  customer  aq closed? false
Closing Query  customer  aq.
Exception in thread "main" java.sql.SQLRuntimeException: java.lang.NullPointerException
        at com.sun.sql.QueryObjectGeneratorImpl.deregisterAllDataSets(Unknown Source)
        at com.sun.sql.QueryObjectGeneratorImpl.invoke(Unknown Source)
        at $Proxy0.close(Unknown Source)
        at CloseTest.main(CloseTest.java:67)
Caused by: java.lang.NullPointerException
        at com.sun.sql.DataSetImpl$DataSetItr.<init>(Unknown Source)
        at com.sun.sql.DataSetImpl.iterator(Unknown Source)
        at java.util.AbstractList.hashCode(AbstractList.java:524)
        at java.util.WeakHashMap.remove(WeakHashMap.java:543)
        at java.util.WeakHashMap$HashIterator.remove(WeakHashMap.java:779)
        ... 4 more
Posted Date : 2006-08-10 17:18:46.0
Work Around
N/A
Evaluation
After DataSet is closed, the hashCode for that DataSet results in NullPointerException. Need to ignore closed DataSet.
Posted Date : 2006-08-24 11:47:02.0
Comments
  
  Include a link with my name & email   


PLEASE NOTE: JDK6 is formerly known as Project Mustang