teiiddes-2224

Added logic to check for compilation errors and changed connection, resultset, properties, and statement variables from class level to local scope.