con = getConnection();
con = JDBCUtil.getDBConnection(dataSource);
    private boolean preCheck() {        debug(">preCheck");        boolean ret = false;        Connection con = null;        PreparedStatement ps = null;        try {            con = getConnection();            // Check if cAId in the table admingroupdata is present. It is present only in ejbca 3, not 2.            ps = con.prepareStatement("select * from admingroupdata");            ResultSet rs = ps.executeQuery();            ResultSetMetaData md = rs.getMetaData(); // MySQL does not implement getMetaData directly from ps            debug("preCheck: no of columns="+md.getColumnCount());            // Ejbca 3 has three columns, ejbca 2 only one            if (md.getColumnCount() == 1) {            	ret = true;            }        } catch (Exception e) {        	error("Database error during preCheck: ", e);        } finally {            JDBCUtil.close(ps);            JDBCUtil.close(con);        }        debug("<preCheck("+ret+")");        return ret;    }