- 27 May, 2010 1 commit
-
-
Alexey Kopytov authored
-
- 26 May, 2010 1 commit
-
-
unknown authored
-
- 25 May, 2010 3 commits
-
-
Alexey Kopytov authored
bitmap_is_set(table->read_set, field_index)) UPDATE on an InnoDB table modifying the same index that is used to satisfy the WHERE condition could trigger a debug assertion under some circumstances. Since for engines with the HA_PRIMARY_KEY_IN_READ_INDEX flag set results of an index scan on a secondary index are appended by the primary key value, if a query involves only columns from the primary key and a secondary index, the latter is considered to be covering. That tricks mysql_update() to mark for reading only columns from the secondary index when it does an index scan to retrieve rows to update in case a part of that key is also being updated. However, there may be other columns in WHERE that are part of the primary key, but not the secondary one. What we actually want to do in this case is to add index columns to the existing WHERE columns bitmap rather than replace it. mysql-test/r/innodb_mysql.result: Test case for bug #53830. mysql-test/t/innodb_mysql.test: Test case for bug #53830. sql/sql_update.cc: Add index columns to the read_set bitmap, don't replace it. sql/table.cc: Added a new add_read_columns_used_by_index() function to st_table. sql/table.h: Added a new add_read_columns_used_by_index() function to st_table.
-
Mattias Jonsson authored
-
unknown authored
-
- 24 May, 2010 3 commits
-
-
Alexander Nozdrin authored
in mysql-trunk-merge). There were two problems: - a mistake during merge of a patch for Bug 52629 from 5.1; - MTR treated auxilary output of newer valgrind as an error. The fixes are: - Fix merge error; - Teach MTR to skip 'HEAP summary' section of valgrind output.
-
Alexey Kopytov authored
-
unknown authored
Some of the test cases reference to binlog position and these position numbers are written into result explicitly. It is difficult to maintain if log event format changes. There are a couple of cases explicit position number appears, we handle them in different ways A. 'CHANGE MASTER ...' with MASTER_LOG_POS or/and RELAY_LOG_POS options Use --replace_result to mask them. B. 'SHOW BINLOG EVENT ...' Replaced by show_binlog_events.inc or wait_for_binlog_event.inc. show_binlog_events.inc file's function is enhanced by given $binlog_file and $binlog_limit. C. 'SHOW SLAVE STATUS', 'show_slave_status.inc' and 'show_slave_status2.inc' For the test cases just care a few items in the result of 'SHOW SLAVE STATUS', only the items related to each test case are showed. 'show_slave_status.inc' is rebuild, only the given items in $status_items will be showed. 'check_slave_is_running.inc' and 'check_slave_no_error.inc' and 'check_slave_param.inc' are auxiliary files helping to show running status and error information easily. mysql-test/extra/binlog_tests/binlog.test: It only cares whether current binlog file index is changed, so it is ok with 'show_master_status.inc' instead of 'show mater status'. mysql-test/extra/binlog_tests/blackhole.test: Use 'show_binlog_events.inc' instead of 'show binlog events' statement. mysql-test/extra/rpl_tests/rpl_deadlock.test: Use 'check_slave_is_running.inc' instead of 'show_slave_status2.inc'. mysql-test/extra/rpl_tests/rpl_extraMaster_Col.test: Use 'check_slave_is_running.inc' instead of 'show slave status' statement. mysql-test/extra/rpl_tests/rpl_extraSlave_Col.test: Use 'wait_for_slave_sql_error.inc' and 'ait_for_slave_sql_error_and_skip.inc' instead of 'show slave status'. mysql-test/extra/rpl_tests/rpl_flsh_tbls.test: Use 'show_binlog_events.inc' instead of 'show binlog events' statement. mysql-test/extra/rpl_tests/rpl_get_master_version_and_clock.test: It is need now to give a error number, so use 'wait_for_slave_io_to_stop.inc' instead of 'wait_for_slave_io_error.inc'. mysql-test/extra/rpl_tests/rpl_insert_delayed.test: Use 'show_binlog_events.inc' instead of 'show binlog events' statement. mysql-test/extra/rpl_tests/rpl_log.test: Use 'show_binlog_events.inc' instead of 'show binlog events' statement. se 'check_slave_is_running.inc' instead of 'show slave status' statement. mysql-test/extra/rpl_tests/rpl_max_relay_size.test: se 'check_slave_is_running.inc' instead of 'show slave status' statement. mysql-test/extra/rpl_tests/rpl_ndb_apply_status.test: Use 'show_binlog_events.inc' instead of 'show binlog events' statement. mysql-test/extra/rpl_tests/rpl_reset_slave.test: Use 'show_slave_status.inc' instead of 'show_slave_status2.inc' statement. Use 'check_slave_no_error.inc' to simplify the check that there is no error. mysql-test/extra/rpl_tests/rpl_row_basic.test: Use 'check_slave_is_running.inc' to verify that Slave threads are running well. Use 'wait_for_slave_sql_error.inc' to wait the given sql thread error happening. mysql-test/extra/rpl_tests/rpl_row_tabledefs.test: Use 'show_slave_error_status_and_skip.inc' instead of 'show slave status'. mysql-test/include/check_slave_is_running.inc: To make sure both sql and io thread are running well. If not, the test will be aborted. mysql-test/include/check_slave_no_error.inc: To make sure both sql and io thread have no error. If not, the test will be aborted. mysql-test/include/get_relay_log_pos.inc: According to the position of a log event in master binlog file, find the peer position of a log event in relay log file. mysql-test/include/rpl_stmt_seq.inc: Use 'show_binlog_events.inc' instead of 'show binlog events' statement. mysql-test/include/show_binlog_events.inc: Add two options $binlog_file and $binlog_limit for showing binlog events from different binlog files or/and given different limits on position or row number. mysql-test/include/show_rpl_debug_info.inc: Add 'SELECT NOW()' in the debug information. mysql-test/include/show_slave_status.inc: It's more clean and tidy Only the given columns of slave status are printed. mysql-test/include/test_fieldsize.inc: Use 'wait_for_slave_sql_error.inc' to wait the given sql thread error happening. There is no need to print the result of 'show slave stutus'. mysql-test/include/wait_for_binlog_event.inc: Use show_rpl_debug_info.inc instead of 'SHOW BINLOG EVENTS'. mysql-test/include/wait_for_slave_io_error.inc: Add $slave_io_errno and $show_slave_io_error, it waits only a given error. mysql-test/include/wait_for_slave_param.inc: Use die instead of exit. mysql-test/include/wait_for_slave_sql_error.inc: Add $slave_sql_errno and $show_slave_sql_error, it waits only a given error. mysql-test/include/wait_for_status_var.inc: Use die instead of exit. mysql-test/r/flush_block_commit_notembedded.result: It checks whether somethings are binlogged, so we using 'show_binlog_event.inc' instead of 'show master status'. mysql-test/r/multi_update.result: It checks whether somethings are binlogged, so we using 'show_binlog_event.inc' instead of 'show master status'. mysql-test/suite/binlog/r/binlog_innodb.result: It checks whether somethings are binlogged, so we using 'show_binlog_event.inc' instead of 'show master status'. mysql-test/suite/binlog/r/binlog_row_binlog.result: Position in the result of 'show master status' is replaced by '#'. mysql-test/suite/binlog/r/binlog_stm_binlog.result: Position in the result of 'show master status' is replaced by '#'. mysql-test/suite/binlog/t/binlog_innodb.test: It checks whether somethings are binlogged, so we use 'show_binlog_event.inc' instead of 'show master status'. mysql-test/suite/binlog/t/binlog_stm_binlog.test: Use 'show_binlog_events.inc' instead of 'show binlog events' statement. mysql-test/suite/bugs/r/rpl_bug36391.result: Position in the result of 'show master status' is replaced by '#'. mysql-test/suite/bugs/t/rpl_bug12691.test: Use 'show_binlog_events.inc' instead of 'show binlog events' statement. mysql-test/suite/bugs/t/rpl_bug36391.test: 'show master status' is replaced by 'show_master_status.inc'. Position in the result of 'show master status' is replaced by '#'. mysql-test/suite/engines/funcs/r/rpl_000015.result: It checks whether somethings are binlogged, so we using 'show_binlog_event.inc' instead of 'show master status'. mysql-test/suite/engines/funcs/t/rpl_000015.test: Use 'check_slave_is_running.inc' to verify that Slave threads are running well. mysql-test/suite/engines/funcs/t/rpl_REDIRECT.test: Use 'query_vertical SHOW SLAVE STATUS' instead of 'show slave status'. There is no status columns in the result file, for no slave exists on master's server. mysql-test/suite/engines/funcs/t/rpl_change_master.test: This test just care whether Read_Master_Log_Pos is equal to Exec_Master_Log_Pos after 'CHANGE MASTER ..'. So 'show slave status' is removed and just check the value of Read_Master_Log_Pos and Exec_Master_Log_Pos. mysql-test/suite/engines/funcs/t/rpl_empty_master_crash.test: We doesn't really need the statement. mysql-test/suite/engines/funcs/t/rpl_flushlog_loop.test: Just show Relay_Log_File, running status and error informations. Use 'check_slave_is_running.inc' to verify that Slave threads are running well. mysql-test/suite/engines/funcs/t/rpl_loaddata_s.test: Use 'show_binlog_events.inc' instead of 'show binlog events' statement. mysql-test/suite/engines/funcs/t/rpl_log_pos.test: Mask the explicit positions in the result file. Use 'check_slave_no_error.inc' to simplify the check that there is no error. Use 'wait_for_slave_sql_error.inc' to wait the given sql thread error happening. There is no need to print the result of 'show slave stutus'. mysql-test/suite/engines/funcs/t/rpl_rbr_to_sbr.test: Use 'show_binlog_events.inc' instead of 'show binlog events' statement. mysql-test/suite/engines/funcs/t/rpl_row_drop.test: Use 'show_binlog_events.inc' instead of 'show binlog events' statement. mysql-test/suite/engines/funcs/t/rpl_row_inexist_tbl.test: Use 'wait_for_slave_sql_error.inc' to wait the given sql thread error happening. There is no need to print the result of 'show slave stutus'. mysql-test/suite/engines/funcs/t/rpl_row_until.test: Use 'check_slave_param.inc' to check whether SQL Thread stop at a right position, and use binlog position variables instead of explicit number in the 'CHANGE MASTER' statements. Mask the explicit binary log positions in the result file. mysql-test/suite/engines/funcs/t/rpl_server_id1.test: Use 'wait_for_slave_sql_error.inc' to wait the given sql thread error happening. There is no need to print the result of 'show slave stutus'. Use 'check_slave_no_error.inc' to simplify the check that there is no error. mysql-test/suite/engines/funcs/t/rpl_server_id2.test: It doesn't really need in this test. mysql-test/suite/engines/funcs/t/rpl_slave_status.test: Use 'wait_for_slave_sql_error.inc' to wait the given sql thread error happening. There is no need to print the result of 'show slave stutus'. mysql-test/suite/engines/funcs/t/rpl_switch_stm_row_mixed.test: Use 'show_binlog_events.inc' instead of 'show binlog events' statement. mysql-test/suite/manual/t/rpl_replication_delay.test: Use 'show_slave_status.inc' instead of 'show slave status'. mysql-test/suite/parts/t/rpl_partition.test: Use 'check_slave_is_running.inc' instead of 'show slave status' statement. mysql-test/suite/rpl/include/rpl_mixed_ddl.inc: Use 'show_binlog_events.inc' instead of 'show binlog events' statement. mysql-test/suite/rpl/include/rpl_mixed_dml.inc: Use 'show_binlog_events.inc' instead of 'show binlog events' statement. mysql-test/suite/rpl/t/rpl_000015.test: Use 'show_slave_status.inc' instead of 'show_slave_status2.inc'. mysql-test/suite/rpl/t/rpl_binlog_grant.test: Use 'wait_for_binlog_event.inc' instead of 'show binlog events' statement. mysql-test/suite/rpl/t/rpl_bug33931.test: Use 'wait_for_slave_sql_error.inc' to wait the given sql thread error happening. There is no need to print the result of 'show slave stutus'. mysql-test/suite/rpl/t/rpl_change_master.test: This test just care whether Read_Master_Log_Pos is equal to Exec_Master_Log_Pos after 'CHANGE MASTER ..'. So 'show slave status' is removed and just check the value of Read_Master_Log_Pos and Exec_Master_Log_Pos. mysql-test/suite/rpl/t/rpl_critical_errors.test: Use 'wait_for_slave_sql_error.inc' to wait the given sql thread error happening. There is no need to print the result of 'show slave stutus'. mysql-test/suite/rpl/t/rpl_dual_pos_advance.test: Mask the explicit position numbers in result file. It is restricted running on SBR, for it want to binlog 'set @A=1' statement. mysql-test/suite/rpl/t/rpl_empty_master_crash.test: It doesn't need in this test. mysql-test/suite/rpl/t/rpl_flushlog_loop.test: UUse 'check_slave_is_running.inc' and 'show_slave_status.inc' instead of 'show slave status' statement. mysql-test/suite/rpl/t/rpl_get_master_version_and_clock.test: Use 'wait_for_slave_io_error.inc' to wait the given io thread error happening. mysql-test/suite/rpl/t/rpl_grant.test: It doesn't need in this test. mysql-test/suite/rpl/t/rpl_incident.test: Use 'check_slave_is_running.inc' instead of 'show slave status' statement. mysql-test/suite/rpl/t/rpl_known_bugs_detection.test: Use 'wait_for_slave_sql_error.inc' to wait the given sql thread error happening. There is no need to print the result of 'show slave stutus'. mysql-test/suite/rpl/t/rpl_loaddata_fatal.test: Use 'wait_for_slave_sql_error_and_skip.inc' to wait the given sql thread error happening and then skip the event. There is no need to print the result of 'show slave stutus'. mysql-test/suite/rpl/t/rpl_log_pos.test: Use 'wait_for_slave_io_error.inc' to wait the given io thread error happening. There is no need to print the result of 'show slave status'. mysql-test/suite/rpl/t/rpl_rbr_to_sbr.test: Use 'show_binlog_events.inc' instead of 'show binlog events' statement. mysql-test/suite/rpl/t/rpl_replicate_do.test: Use 'show_slave_status.inc' instead of 'show slave status'. mysql-test/suite/rpl/t/rpl_rotate_logs.test: Use 'show_slave_status.inc' instead of 'show_slave_status2.inc'. mysql-test/suite/rpl/t/rpl_row_basic_11bugs.test: Use 'show_binlog_events.inc' instead of 'show binlog events' statement. mysql-test/suite/rpl/t/rpl_row_create_table.test: Use 'show_binlog_events.inc' instead of 'show binlog events' statement. mysql-test/suite/rpl/t/rpl_row_drop.test: Use 'show_binlog_events.inc' instead of 'show binlog events' statement. mysql-test/suite/rpl/t/rpl_row_until.test: Use 'check_slave_param.inc' to check whether SQL Thread stop at a right position, and use binlog position variables instead of explicit number in the 'CHANGE MASTER' statements. mysql-test/suite/rpl/t/rpl_skip_error.test: Use 'check_slave_is_running.inc' instead of 'show slave status' statement. mysql-test/suite/rpl/t/rpl_slave_load_remove_tmpfile.test: Use 'wait_for_slave_sql_error.inc' to wait the given sql thread error happening. There is no need to print the result of 'show slave status'. mysql-test/suite/rpl/t/rpl_slave_skip.test: Use 'check_slave_param.inc' to check whether SQL Thread stop at a right position, and mask the explicit position number in the 'CHANGE MASTER' statements. mysql-test/suite/rpl/t/rpl_sp.test: Use 'show_binlog_events.inc' instead of 'show binlog events' statement. mysql-test/suite/rpl/t/rpl_ssl.test: Use 'show_slave_status.inc' instead of 'show slave status'. mysql-test/suite/rpl/t/rpl_ssl1.test: Use 'show_slave_status.inc' instead of 'show slave status'. mysql-test/suite/rpl/t/rpl_stm_until.test: Use 'check_slave_param.inc' to check whether SQL Thread stop at a right position, and use binlog position variables instead of explicit number in the 'CHANGE MASTER' statements. mysql-test/suite/rpl/t/rpl_temporary_errors.test: Use 'check_slave_is_running.inc' instead of 'show slave status' statement. mysql-test/suite/rpl_ndb/t/rpl_ndb_basic.test: Use 'wait_for_slave_sql_error.inc' to wait the given sql thread error happening. There is no need to print the result of 'show slave status'. mysql-test/suite/rpl_ndb/t/rpl_ndb_circular.test: Use 'check_slave_is_running.inc' instead of 'show slave status' statement. mysql-test/suite/rpl_ndb/t/rpl_ndb_circular_simplex.test: Use 'check_slave_is_running.inc' instead of 'show slave status' statement. mysql-test/suite/rpl_ndb/t/rpl_ndb_idempotent.test: Use 'check_slave_is_running.inc' instead of 'show slave status' statement. mysql-test/suite/rpl_ndb/t/rpl_ndb_multi.test: Mask master_log_pos and master_log_file mysql-test/suite/rpl_ndb/t/rpl_ndb_sync.test: Use 'check_slave_is_running.inc' instead of 'show slave status' statement. mysql-test/suite/rpl_ndb/t/rpl_truncate_7ndb.test: Use 'show_binlog_events.inc' instead of 'show binlog events' statement. mysql-test/t/alter_table-big.test: Use 'show_binlog_events.inc' instead of 'show binlog events' statement. mysql-test/t/create-big.test: Use 'show_binlog_events.inc' instead of 'show binlog events' statement. mysql-test/t/ctype_cp932_binlog_stm.test: Use 'show_binlog_events.inc' instead of 'show binlog events' statement. mysql-test/t/flush_block_commit_notembedded.test: It checks whether somethings are binlogged, so we using 'show_binlog_event.inc' instead of 'show master status'. mysql-test/t/multi_update.test: It checks whether somethings are binlogged, so we using 'wait_binlog_event.inc' instead of 'show master status'. mysql-test/t/sp_trans_log.test: Use 'show_binlog_events.inc' instead of 'show binlog events' statement.
-
- 23 May, 2010 2 commits
-
-
Alexey Kopytov authored
Conflicts: conflict Makefile.am conflict mysql-test/suite/rpl/r/rpl_stm_mixing_engines.result conflict mysql-test/suite/rpl/t/rpl_tmp_table_and_DDL.test conflict sql/opt_sum.cc conflict sql/set_var.cc conflict sql/sql_base.cc conflict sql/sql_priv.h conflict sql/sql_show.cc
-
Mattias Jonsson authored
-
- 21 May, 2010 2 commits
-
-
Gleb Shchepa authored
data directory name command The check_db_name function has been modified to validate tails of #mysql50#-prefixed database names for compliance with MySQL 5.0 database name encoding rules (the check_table_name function call has been reused). mysql-test/r/renamedb.result: Updated test case. mysql-test/r/upgrade.result: Test case for bug #53804. mysql-test/t/renamedb.test: Updated test case. mysql-test/t/upgrade.test: Test case for bug #53804. sql/mysql_priv.h: Bug #53804: serious flaws in the alter database .. upgrade data directory name command The check_mysql50_prefix has been added. sql/sql_table.cc: Bug #53804: serious flaws in the alter database .. upgrade data directory name command - The check_mysql50_prefix has been added. - The check_n_cut_mysql50_prefix function has been refactored to share code with new check_mysql50_prefix function. sql/table.cc: Bug #53804: serious flaws in the alter database .. upgrade data directory name command The check_db_name function has been modified to validate tails of #mysql50#-prefixed database names for compliance with MySQL 5.0 database name encoding rules.
-
Mattias Jonsson authored
sql/ha_partition.cc: Bug#49477, added safety that a partitioned table cannot be temporary.
-
- 20 May, 2010 4 commits
-
-
Sven Sandberg authored
Problem: The test case mysqldump reads a file that must be world-readable. The test did not force the file to be world-readable, so if the tree was branched with a umask of 0077, the test would fail. Fix: chmod the file. mysql-test/t/mysqldump.test: Added chmod so that the file is guaranteed to be world-readable.
-
Alexander Nozdrin authored
Conflicts: - mysql-test/r/partition.result - mysql-test/r/variables_debug.result - mysql-test/t/partition.test - mysql-test/t/variables_debug.test
-
Alexander Nozdrin authored
-
Sergey Glukhov authored
Server crashes on 64bit linux with 'double free or corruption' message, on 32bit mysql-test-run silently fails on bootstrap stage. The problem is that FreeState() is called twice for init_settings struct in _db_end_ function. The fix is to remove superfluous FreeState() call. Additional fix: fixed discrepancy of result file when debug & valgrind options are enabled for MTR. dbug/dbug.c: The problem is that FreeState() is called twice for init_settings struct in _db_end_ function. The fix is to remove superfluous FreeState() call. mysql-test/r/variables_debug.result: fixed discrepancy of result file when debug & valgrind options are enabled for MTR. mysql-test/t/variables_debug.test: fixed discrepancy of result file when debug & valgrind options are enabled for MTR. sql/set_var.cc: fixed discrepancy of result file when debug & valgrind options are enabled for MTR.
-
- 19 May, 2010 7 commits
-
-
Luis Soares authored
-
Luis Soares authored
-
Luis Soares authored
-
Alexander Nozdrin authored
(make relies GNU extentions). The patch was partially backport from 6.0. Original comment: bug#30708: make relies GNU extensions. Now that we no longer use BitKeeper we can safely remove the SCCS handling with no loss of functionality.
-
Alexander Nozdrin authored
-
Alexander Nozdrin authored
from 6.0 to trunk-bugfixing.
-
Tor Didriksen authored
Bug #50087 Interval arithmetic for Event_queue_element is not portable. Subtraction of two unsigned months yielded a (very large) positive value. Conversion of this to a signed value was not necessarily well defined. Solution: do the subtraction on signed values. mysql-test/r/events_scheduling.result: Add test case. mysql-test/t/events_scheduling.test: Add test case. sql/event_data_objects.cc: Convert month to signed before doing the subtraction.
-
- 18 May, 2010 4 commits
-
-
Andrei Elkin authored
-
Sergey Glukhov authored
Analysis showed that in case of accessing I_S table ROUTINES we perform unnecessary allocations with get_field() function for every processed row that in their turn causes significant memory growth. the fix is to avoid use of get_field(). sql/sql_show.cc: Functions store_schema_proc() are changed to avoid use of get_field() function.
-
Andrei Elkin authored
-
Andrei Elkin authored
-
- 17 May, 2010 2 commits
-
-
Alexander Nozdrin authored
That was a pure test issue -- filter implementation in Perl did not work on some platform (the bug occurred on Windows Server 2008 with Cygwin Perl 5.10.0).
-
Alexander Nozdrin authored
in a multiquery packet): fix NDB test failures.
-
- 16 May, 2010 5 commits
-
-
Andrei Elkin authored
removing disabled line for rpl_row_create_table due to Bug#45576. Anyway, the test is still there because of Bug#51574
-
Andrei Elkin authored
pushing to next-mr-bugfixing from working branch
-
Andrei Elkin authored
-
Alfranio Correia authored
mode Post-push fix after backporting the patch to 5.1-bugteam: 1 - changed the name of some variables to be equivalent to pe. 2 - fixed that patch to mark a statement as unsafe when both a self-logging eng. and regular eng. are accessed and one of them is updated.
-
Alfranio Correia authored
Post-fix: Updated a test case after the patch for BUG#50410, because the patch makes ndb to run in the row format and as such unsafe warning messages are not printed out.
-
- 14 May, 2010 3 commits
-
-
Alexander Nozdrin authored
multiquery packet). Background: - a query can contain multiple SQL statements; - the server frees resources allocated to process a query when the whole query is handled. In other words, resources allocated to process one SQL statement from a multi-statement query are freed when all SQL statements are handled. The problem was that the parser allocated a buffer of size of the whole query for each SQL statement in a multi-statement query. Thus, if a query had many SQL-statements (so, the query was long), but each SQL statement was short, ther parser tried to allocate huge amount of memory (number of small SQL statements * length of the whole query). The memory was allocated for a so-called "cpp buffer", which is intended to store pre-processed SQL statement -- SQL text without version specific comments. The fix is to allocate memory for the "cpp buffer" once for all SQL statements (once for a query).
-
Gleb Shchepa authored
ha_myisam::index_first(uchar*)") at assert.c:81 Single-table DELETE crash/assertion similar to single-table UPDATE bug 14272. Same resolution as for the bug 14272: Don't run index scan when we should use quick select. This could cause failures because there are table handlers (like federated) that support quick select scanning but do not support index scanning. mysql-test/r/delete.result: Test case for bug #53450. mysql-test/t/delete.test: Test case for bug #53450. sql/sql_delete.cc: Bug #53450: Crash / assertion "virtual int ha_myisam::index_first(uchar*)") at assert.c:81 The mysql_delete function has been modified to not to use init_read_record_idx instead of init_read_record for the quick select.
-
Alexander Nozdrin authored
for ALTER TABLE, LOAD DATA). ROW_COUNT is now assigned according to the following rules: - In my_ok(): - for DML statements: to the number of affected rows; - for DDL statements: to 0. - In my_eof(): to -1 to indicate that there was a result set. We derive this semantics from the JDBC specification, where int java.sql.Statement.getUpdateCount() is defined to (sic) "return the current result as an update count; if the result is a ResultSet object or there are no more results, -1 is returned". - In my_error(): to -1 to be compatible with the MySQL C API and MySQL ODBC driver. - For SIGNAL statements: to 0 per WL#2110 specification. Zero is used since that's the "default" value of ROW_COUNT in the diagnostics area. sql/protocol.cc: Fix a typo. sql/sql_class.h: - Introduce THD::get_row_count_func() / THD::set_row_count_func(); - Remove the CF_HAS_ROW_COUNT define sql/sql_parse.cc: CF_HAS_ROW_COUNT was eliminated.
-
- 13 May, 2010 1 commit
-
-
Luis Soares authored
MTR sporadically reported that rpl_do_grant does not clean up after itself. We fix this by backporting BUG 50984 fix. This deploys missing synchronization between master and slave. Additionally, it also fixes the check_testcase for rpl_tmp_table_and_DDL.
-
- 12 May, 2010 2 commits
-
-
Ramil Kalimullin authored
NULL from outer join query Problem: optimising MIN/MAX() queries without GROUP BY clause by replacing the aggregate expression with a constant, we may set it to NULL disregarding the fact that there may be outer joins involved. Fix: don't replace MIN/MAX() with NULL if there're outer joins. Note: the fix itself is just - if (!count) + if (!count && !outer_tables) set to NULL The rest of the patch eliminates repeated code to improve speed and for easy maintenance of the code. mysql-test/r/group_by.result: Fix for bug#52051: Aggregate functions incorrectly returns NULL from outer join query - test result. mysql-test/t/group_by.test: Fix for bug#52051: Aggregate functions incorrectly returns NULL from outer join query - test case. sql/opt_sum.cc: Fix for bug#52051: Aggregate functions incorrectly returns NULL from outer join query - optimising MIN/MAX() queries without GROUP BY clause by replacing them with a constant, take into account that there're may be outer joins involved. - repeated code for MIN/MAX optimization in the opt_sum_query() eliminated by introducing new functions that read MIN/MAX values using index and combining MIN/MAX cases to one.
-
Jonathan Perkin authored
-