Logo Search packages:      
Sourcecode: mysql-connector-java version File versions  Download package

void com::mysql::jdbc::ConnectionImpl::unsetMaxRows ( StatementImpl  stmt  )  throws SQLException [inline, package]

Called by statements on their .close() to let the connection know when it is safe to set the connection back to 'default' row limits.

Parameters:
stmt the statement releasing it's max-rows requirement
Exceptions:
SQLException if a database error occurs issuing the statement that sets the limit default.

Definition at line 5291 of file ConnectionImpl.java.

Referenced by com::mysql::jdbc::StatementImpl::realClose(), com::mysql::jdbc::ServerPreparedStatement::rePrepare(), and com::mysql::jdbc::StatementImpl::setMaxRows().

                                                                {
            synchronized (this.mutex) {
                  if (this.statementsUsingMaxRows != null) {
                        Object found = this.statementsUsingMaxRows.remove(stmt);

                        if ((found != null)
                                    && (this.statementsUsingMaxRows.size() == 0)) {
                              execSQL(null, "SET OPTION SQL_SELECT_LIMIT=DEFAULT", -1,
                                          null, java.sql.ResultSet.TYPE_FORWARD_ONLY,
                                          java.sql.ResultSet.CONCUR_READ_ONLY, false, 
                                          this.database, null, false);

                              this.maxRowsChanged = false;
                        }
                  }
            }
      }


Generated by  Doxygen 1.6.0   Back to index