Example #1
0
  /**
   * Binds the value in the specified update descriptor corresponding with the specified column
   * reference to the specified statement.
   *
   * @param stmt the statement
   * @param columnRef the column reference
   * @param updateDesc the update descriptor
   * @throws SQLException thrown by setter methods on java.sql.PreparedStatement
   */
  private void bindInputColumn(
      DBStatement stmt,
      ColumnRef columnRef,
      UpdateObjectDescImpl updateDesc,
      boolean getBeforeValue)
      throws SQLException {

    Object inputValue = getInputValue(updateDesc, columnRef, getBeforeValue);
    stmt.bindInputColumn(
        columnRef.getIndex(), inputValue, columnRef.getColumnElement(), vendorType);
  }
Example #2
0
 public boolean exceedsBatchThreshold(Transaction tran) {
   synchronized (dbStatementCache) {
     DBStatement dbStatement = (DBStatement) dbStatementCache.get(tran);
     return (dbStatement != null) && dbStatement.exceedsBatchThreshold();
   }
 }