Class 'instanceof' fails for org.jboss.jca.adapters.jdbc.jdk6.WrappedResultSetJDK6 in EAP 6
Issue
- A result set retrieved from a query execution cannot be accessed as a
WrappedResultSetJDK6 - The class name is reported correctly, but
instanceoffails to match the class
java.sql.ResultSet results = statement.executeQuery();
System.out.println(results.getClass().getName()); // displays org.jboss.jca.adapters.jdbc.jdk6.WrappedResultSetJDK6
if (results instanceof org.jboss.jca.adapters.jdbc.jdk6.WrappedResultSetJDK6) {
... // execution never enters this code block
}
Environment
- Red Hat JBoss Enterprise Application Platform (EAP) 6
Subscriber exclusive content
A Red Hat subscription provides unlimited access to our knowledgebase of over 48,000 articles and solutions.
Welcome! Check out the Getting Started with Red Hat page for quick tours and guides for common tasks.
