JDBC Caution

    {warning} This online page relates to the latest released JChem PostgreSQL Cartridge. Find the version specific documentation in your installed package in /opt/jchem-psql/doc/ directory.

    Closing statements

    During chemical operations, JChem sessions are opened, closed and assigned to PostgreSQL sessions. In order to release JChem sessions properly, PostgreSQL statements must be closed when using JDBC.

    This can be done either by setting up autocommit in JDBC session or by calling commit or rollback after every statement execution (even query statements).

    Cleaning SQL log

    Setting SQL log level to debug may produce high amount of log entries. JDBC keeps these log messages connected to Statements, Connections, and ResultSets which may fill the JVM heap causing memory or GC problems.

    To avoid this problem use the clearWarnings() methods of the classes above.