Closes the SQLExecutor's statement object (releasing database and JDBC resources immediately instead of
waiting for this to happen when the SQLExecutor object is garbage collected).
SQLExecutor class is an easy to use wrapper for executing JDBC queries, updates, and
stored procedure calls for Oracle and mySQL (other databases can be supported by
extending the DatabaseException class for a new database).
The framework doesn't throw any checked exceptions, so you aren't forced
to write try-catch blocks around all your code.
Illustrates creating a database connection using standard JDBC and then using this
connection to create a ConnectionPool and execute a select statement.
This method tests the jdbc framework with a call to the following Oracle stored function:
CREATE OR REPLACE FUNCTION jdbc_test1 RETURN NUMBER IS
cnt_jdbc_test NUMBER;
BEGIN
dbms_output.put_line ('starting jdbc_test1...');
cnt_jdbc_test := 0;
SELECT COUNT(*) INTO cnt_jdbc_test FROM JDBC_TEST;
RETURN cnt_jdbc_test;
EXCEPTION
WHEN NO_DATA_FOUND THEN
Null;
WHEN OTHERS THEN
-- Consider logging the error and then re-raise
RAISE;
END jdbc_test1;
/