code: public int executeUpdate(final String sql, final int autoGeneratedKeys) throws SQLException {
      if (executeInternal(sql, fetchSize, autoGeneratedKeys)) {
        return 0;
      }
      return getUpdateCount();
    }
docs: Executes the given SQL statement and signals the driver with the given flag about whether the
  auto-generated keys produced by this <code>Statement</code> object should be made available for
  retrieval.  The driver will ignore the flag if the SQL statement is not an
  <code>INSERT</code> statement, or an SQL statement able to return auto-generated keys (the
  list of such statements is vendor-specific).
  
  @param sql               an SQL Data Manipulation Language (DML) statement, such as
  <code>INSERT</code>,
  <code>UPDATE</code> or <code>DELETE</code>; or an
  SQL statement that returns nothing, such as a DDL statement.
  @param autoGeneratedKeys a flag indicating whether auto-generated keys should be made available
  for retrieval; one of the following constants:
  <code>Statement.RETURN_GENERATED_KEYS</code> <code>Statement.NO_GENERATED_KEYS</code>
  @return either (1) the row count for SQL Data Manipulation Language (DML) statements or (2) 0
  for SQL statements that return nothing
  @throws SQLException                    if a database access error occurs, this method is
  called on a closed
  <code>Statement</code>, the given SQL
  statement returns a <code>ResultSet</code> object, or
  the given constant is not one of those allowed