| Class to execute SQL statements.
Typical examples would be:
StatementExecutor se = new StatementExecutor();
se.execute("insert into test values(12, 'test', 'test data')");
which would then print the result: "1 row affected."; of course, when
the table test would not exist, or would have a different structure this
statement would result in a
java.sql.SQLException being thrown.
'Special statements' like for instance commit or rollback
should be passed through the StatementExecutor as wel:
se.execute("rollback");
See Also: QueryExecutor |