protected SQLException closeQuery ( ) { SQLException sqlException = closeQueryResultSets ( ) ; if ( statement != null ) { try { statement . close ( ) ; } catch ( SQLException sex ) { if ( sqlException == null ) { sqlException = sex ; } else { sqlException . setNextException ( sex ) ; } } statement = null ; } query = null ; queryState = CLOSED ; return sqlException ; }
Closes all assigned result sets and then closes the query . Query becomes closed .