summaryrefslogtreecommitdiff
path: root/sql
Commit message (Collapse)AuthorAgeFilesLines
* Manual merge of patch for bug #40552 into the team tree.Alexey Kopytov2009-03-161-1/+1
|\ | | | | | | | | Replaced a call to load_defaults() in sql_plugin.cc with its thread-safe version.
* | Fix for bug #42957: no results from Ramil Kalimullin2009-03-161-1/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | select where .. (col=col and col=col) or ... (false expression) Problem: optimizer didn't take into account a singular case when we eliminated all the predicates at the AND level of WHERE. That may lead to wrong results. Fix: replace (a=a AND a=a...) with TRUE if we eliminated all the predicates. mysql-test/r/select.result: Fix for bug #42957: no results from select where .. (col=col and col=col) or ... (false expression) - test result. mysql-test/t/select.test: Fix for bug #42957: no results from select where .. (col=col and col=col) or ... (false expression) - test case. sql/sql_select.cc: Fix for bug #42957: no results from select where .. (col=col and col=col) or ... (false expression) - replacing equality predicates by multiple equality items check if we eliminate all the predicates at the AND level and replace them with TRUE if so.
* | compilation(embedded server) failure fixSergey Glukhov2009-03-131-3/+1
| |
* | Bug#42610 Dynamic plugin broken in 5.1.31Sergey Glukhov2009-03-133-13/+33
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | --added ability to obtain plugin variables from my.cnf on INSTALL PLUGIN stage --option 'ignore-builtin-innodb' disables all InnoDB builtin plugins (including I_S plugins) sql/mysql_priv.h: --added ability to obtain plugin variables from my.cnf on INSTALL PLUGIN stage sql/mysqld.cc: --added ability to obtain plugin variables from my.cnf on INSTALL PLUGIN stage sql/sql_plugin.cc: --added ability to obtain plugin variables from my.cnf on INSTALL PLUGIN stage --option 'ignore-builtin-innodb' disables all InnoDB builtin plugins (including I_S plugins)
* | manual merge for 40657 beautificationTatiana A. Nurnberg2009-03-121-1/+1
|\ \
| * | Bug#36540: CREATE EVENT and ALTER EVENT statements fail with large server_idDavi Arnaut2009-03-111-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The problem is that creating a event could fail if the value of the variable server_id didn't fit in the originator column of the event system table. The cause is two-fold: it was possible to set server_id to a value outside the documented range (from 0 to 2^32-1) and the originator column of the event table didn't have enough room for values in this range. The log tables (general_log and slow_log) also don't have a proper column type to store the server_id and having a large server_id value could prevent queries from being logged. The solution is to ensure that all system tables that store the server_id value have a proper column type (int unsigned) and that the variable can't be set to a value that is not within the range. mysql-test/r/events_bugs.result: Add test case result for Bug#36540 mysql-test/r/log_tables.result: Update column type. mysql-test/r/system_mysql_db.result: Update column type. mysql-test/r/variables.result: Add test case result for server_id value range. mysql-test/suite/sys_vars/r/server_id_basic_64.result: Update test case results. mysql-test/t/events_bugs.test: Add test case for Bug#36540 mysql-test/t/log_tables.test: Fix column type. mysql-test/t/variables.test: Add test case for server_id value range. scripts/mysql_system_tables.sql: Columns that store the server_id value must be of type INT UNSIGNED, fix event (originator), general_log and slow_log (server_id) tables in accordance. scripts/mysql_system_tables_fix.sql: Columns that store the server_id value must be of type INT UNSIGNED, fix event (originator), general_log and slow_log (server_id) tables in accordance. sql/mysqld.cc: Set min and max values for the server_id variable. Unfortunately we can't easily change server_id variable type from ulong to uint32 because of the sys_var classes.
* | | Bug#40657: assertion with out of range variables and traditional sql_modeTatiana A. Nurnberg2009-03-111-2/+3
|/ / | | | | | | | | | | | | | | | | | | | | | | | | normalize error-messages mysql-test/r/variables.result: show that warning uses underscore (sysvar-name), not hyphens (option-name) mysql-test/t/variables.test: show that warning uses underscore (sysvar-name), not hyphens (option-name) sql/set_var.cc: normalize error-messages
* | merge of bug 42434 to 5.1-bugteamGeorgi Kodinov2009-03-112-8/+2
|\ \
| * | Bug #42434: license of mysys MD5 implementation is not GPL-compatibleGeorgi Kodinov2009-03-092-8/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Took the Xfree implementation (based on the same rewrite as the NDB one) and added it instead of the current implementation. Added a macro to make the calls to MD5 more streamlined. client/mysqlmanager-pwgen.c: Bug #42434: changed to call the macro include/my_md5.h: Bug #42434: use the Xfree implementation mysys/md5.c: Bug #42434: use the Xfree implementation sql/item_strfunc.cc: Bug #42434: changed to call the macro sql/table.cc: Bug #42434: changed to call the macro tools/mysqlmanager.c: Bug #42434: changed to call the macro
* | | merged bug 43354 to 5.1-bugteamGeorgi Kodinov2009-03-111-1/+2
|\ \ \ | |/ /
| * | Bug #43354: Use key hint can crash server in explain extended queryGeorgi Kodinov2009-03-111-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The copy of the original arguments of a aggregate function was not initialized until after fix_fields(). Sometimes (e.g. when there's an error processing the statement) the print() can be called with no corresponding fix_fields() call. Fixed by adding a check if the Item is fixed before using the arguments copy. mysql-test/r/explain.result: Bug #43354: test case mysql-test/t/explain.test: Bug #43354: test case sql/item_sum.cc: Bug #43354: use the argument list copy only if it's initialized
| * | fixed a typoGeorgi Kodinov2009-03-091-1/+1
| | |
| * | fixed a win32 compile warningGeorgi Kodinov2009-03-091-1/+2
| | |
| * | Manual mergeKristofer Pettersson2009-03-0657-748/+1718
| |\ \
| | * | BUG#37051 Replication rules not evaluated correctlyHe Zhenxing2009-03-056-25/+107
| | | | | | | | | | | | | | | | | | | | Backporting patch to 5.0.
| | * | Applying InnoDB snashot 5.0-ss4007, part 2. FixesTimothy Smith2009-03-021-0/+14
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Bug #18828: If InnoDB runs out of undo slots, it returns misleading 'table is full' This is a backport of code already in 5.1+. The error message change referred to in the detailed revision comments is still pending. Detailed revision comments: r3937 | calvin | 2009-01-15 03:11:56 +0200 (Thu, 15 Jan 2009) | 17 lines branches/5.0: Backport the fix for Bug#18828. Return DB_TOO_MANY_CONCURRENT_TRXS when we run out of UNDO slots in the rollback segment. The backport is requested by MySQL under bug#41529 - Safe handling of InnoDB running out of undo log slots. This is a partial fix since the MySQL error code requested to properly report the error condition back to the client has not yet materialized. Currently we have #ifdef'd the error code translation in ha_innodb.cc. This will have to be changed as and when MySQl add the new requested code or an equivalent code that we can then use. Given the above, currently we will get the old behavior, not the "fixed" and intended behavior. Approved by: Heikki (on IM)
| | * | Commit after merge from 5.0-bugteamStaale Smedseng2009-02-276-49/+83
| | |\ \
| * | | | Bug#40363 Bug 20023 is not fixed on 5.0Kristofer Pettersson2009-03-051-0/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is a back port from 5.1 to 5.0. Fix for BUG 20023: mysql_change_user() resets the value of SQL_BIG_SELECTS. The bug was that SQL_BIG_SELECTS was not properly set in COM_CHANGE_USER. The fix is to update SQL_BIG_SELECTS properly. sql/sql_class.cc: Update THD::options with the respect to SQL_BIG_SELECTS in COM_CHANGE_USER. tests/mysql_client_test.c: Add a test case BUG#20023.
| * | | | automergeKristofer Pettersson2008-11-071-0/+47
| |\ \ \ \
| | * | | | Bug#37416 When SQL_NO_CACHE is used, MySQL still lookup into the query cacheKristofer Pettersson2008-10-141-0/+47
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The query cache module did not check for the SQL_NO_CACHE keyword before attempting to query the hash lookup table. This had a small performance impact. By introducing a check on the query string before obtaining the hash mutex we can gain some performance if the SQL_NO_CACHE directive is used often.
* | | | | | manual mergeTatiana A. Nurnberg2009-03-0619-61/+234
|\ \ \ \ \ \
| * | | | | | Bug#41465: confusing error message when comment is too longDavi Arnaut2009-03-052-9/+16
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The problem was that the server was trying to use the unknown error format string (ER_UNKNOWN_ERROR) to print messages about comments being too long, but the said format string does not accept arguments and will always default to "Unknown error". The solution is to introduce new error messages which are specific to the error conditions so that server wants to signal -- this also means that it's possible to translate those messages. mysql-test/r/strict.result: Update test case result. mysql-test/t/strict.test: Update test case with new errors. sql/share/errmsg.txt: Introduce new errors for long comments. sql/unireg.cc: Use new errors.
| * | | | | | AutomergeKristofer Pettersson2009-03-0610-24/+70
| |\ \ \ \ \ \
| | * \ \ \ \ \ merging with mysql-5.1-bugteam treeNarayanan V2009-03-068-24/+59
| | |\ \ \ \ \ \
| | | * | | | | | BUG#39753: Replication failure on MIXED + bit + myisam + no PKLuis Soares2009-03-051-18/+16
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When using mixed mode the record values stored inside the storage engine differed from the ones computed from the row event. This happened because the prepare_record function was calling empty_record macro causing some don't care bits to be left set. Replacing the empty_record plus explicitly setting defaults with restore_record to restore the record default values fixes this.
| | | * | | | | | removed unused variableSergey Glukhov2009-03-051-1/+0
| | | | | | | | |
| | | * | | | | | automergeSergey Glukhov2009-03-053-2/+17
| | | |\ \ \ \ \ \
| | | | * \ \ \ \ \ Auto merged Guangbao Ni2009-03-052-2/+5
| | | | |\ \ \ \ \ \
| | | | * | | | | | | BUG#41980 SBL, INSERT .. SELECT .. LIMIT = ERROR, even when @@SQL_LOG_BIN is 0 !Guangbao Ni2009-03-053-2/+17
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When binlog_format is STATEMENT and the statement is unsafe before, the unsafe warning/error message was issued without checking whether the SQL_LOG_BIN was turned on or not. Fixed with adding a sql_log_bin_toplevel flag in THD to check whether SQL_LOG_BIN is ON in current session whatever the current is in sp or not. mysql-test/suite/binlog/r/binlog_unsafe.result: Test case result for unsafe warning/error message mysql-test/suite/binlog/t/binlog_unsafe.test: Test case for unsafe message warning/error sql/set_var.cc: Adding a function set_option_log_bin_bit() which specailly handles to the change of SQL_LOG_BIN bit in order to set sql_log_bin_toplevel according to SQL_LOG_BIN current value at the same time. sql/sql_class.cc: Initialize the flag sql_log_bin_toplevel in THD::init(), and add the condition to check whether unsafe ror message was issued. sql/sql_class.h: Add a sql_log_bin_toplevel flag in THD to indicate whether the toplevel SQL_LOG_BIN is
| | | * | | | | | | | Bug#41030 Wrong meta data (incorrect fieldlen)Sergey Glukhov2009-03-051-1/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | set user variable max length on fix_length_and_dec() stage using real value length. mysql-test/r/variables.result: test result mysql-test/t/variables.test: test case sql/item_func.cc: set user variable max length on fix_length_and_dec() stage using real value length.
| | | * | | | | | | | Bug#42758 INFORMATION_SCHEMA.COLUMNS is inconsistentSergey Glukhov2009-03-051-1/+12
| | | | |/ / / / / / | | | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | remove 'unsigned', 'zerofill' attributes from DATA_TYPE column value. mysql-test/suite/funcs_1/r/is_columns_innodb.result: result fix mysql-test/suite/funcs_1/r/is_columns_memory.result: result fix mysql-test/suite/funcs_1/r/is_columns_myisam.result: result fix sql/sql_show.cc: remove 'unsigned', 'zerofill' attributes from DATA_TYPE column value.
| | | * | | | | | | Addendum to previous patch for Bug#29458. A number Staale Smedseng2009-03-051-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | of system errnos when opening a table are masked as ER_FILE_NOT_FOUND. This patch handles this as "Operation failed" as well.
| | | * | | | | | | BUG#39526 sql_mode not retained in binary log for CREATE PROCEDURELeonard Zhou2009-02-281-1/+3
| | | |/ / / / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Set wrong sql_mode when creating a procedure. So that the sql_mode can't be writen into binary log correctly. Restore the current session sql_mode right before generating the binlog event when creating a procedure. mysql-test/suite/binlog/r/binlog_sql_mode.result: Test result mysql-test/suite/binlog/t/binlog_sql_mode.test: Test file for sql_mode testing sql/sp.cc: Restore the current session sql_mode right before generating the binlog event.
| | * | | | | | | Bug#42790 Test 'main.innodb' fails from "InnoDB: Error: in ALTER TABLE"Narayanan V2009-03-052-0/+11
| | |/ / / / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The problem here seem to be that when mysql is redirecting stderr to a file, stderr becomes buffered, whereas it is unbuffered by definition. The solution is to unbuffer it by setting buffer to null. sql/log.cc: use setbuf(stderr, NULL) to set the buffer to null. sql/mysqld.cc: use setbuf(stderr, NULL) to set the buffer to null.
| * | | | | | | AutomergeKristofer Pettersson2009-03-054-2/+46
| |\ \ \ \ \ \ \
| | * | | | | | | Bug#39843 DELETE requires write access to table in subquery in where clauseKristofer Pettersson2009-03-054-2/+46
| | |/ / / / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | An unnecessarily restrictive lock were taken on sub-SELECTs during DELETE. During parsing, a global structure is reused for sub-SELECTs and the attribute keeping track of lock options were not reset properly. This patch introduces a new attribute to keep track on the syntactical lock option elements found in a sub-SELECT and then sets the lock options accordingly. Now the sub-SELECTs will try to acquire a READ lock if possible instead of a WRITE lock as inherited from the outer DELETE statement. mysql-test/r/lock.result: Added test case for bug39843 mysql-test/t/lock.test: Added test case for bug39843 sql/sql_lex.cc: * Reset member variable lock_option on each new query. sql/sql_lex.h: * Introduced new member variable 'lock_option' which is keeping track of the syntactical lock option of a (sub-)select query. sql/sql_parse.cc: * Wrote comments to functions. sql/sql_yacc.yy: * Introduced an attribute to keep track of syntactical lock options in sub-selects. * Made sure that the default value TL_READ_DEFAULT is at the begining of each subselect-rule.
| * | | | | | | Bug#37416 When SQL_NO_CACHE is used, MySQL still lookup into the query cacheKristofer Pettersson2009-03-051-0/+47
| |/ / / / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The query cache module did not check for the SQL_NO_CACHE keyword before attempting to query the hash lookup table. This had a small performance impact. By introducing a check on the query string before obtaining the hash mutex we can gain some performance if the SQL_NO_CACHE directive is used often. sql/sql_cache.cc: * Introduced new helper function, has_no_cache_directive, for checking the existance of a SQL_NO_CACHE directive before actual parsing of the query.
| * | | | | | Commit after merge from 5.1-bugteamStaale Smedseng2009-02-273-31/+64
| |\ \ \ \ \ \
| | * \ \ \ \ \ merged the fix for bug 41610 to 5.1-bugteamGeorgi Kodinov2009-02-271-25/+32
| | |\ \ \ \ \ \ | | | | |_|_|/ / | | | |/| | | |
| | | * | | | | Bug #41610: key_infix_len can be overwritten causing some group by queries toGeorgi Kodinov2009-02-271-25/+32
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | return no rows The algorithm of determining the best key for loose index scan is doing a loop over the available indexes and selects the one that has the best cost. It retrieves the parameters of the current index into a set of variables. If the cost of using the current index is lower than the best cost so far it copies these variables into another set of variables that contain the information for the best index so far. After having checked all the indexes it uses these variables (outside of the index loop) to create the table read plan object instance. The was a single omission : the key_infix/key_infix_len variables were used outside of the loop without being preserved in the loop for the best index so far. This causes these variables to get overwritten by the next index(es) checked. Fixed by adding variables to hold the data for the current index, passing the new variables to the function that assigns values to them and copying the new variables into the existing ones when selecting a new current best index. To avoid further such problems moved the declarations of the variables used to keep information about the current index inside the loop's compound statement. mysql-test/r/group_min_max.result: Bug #41610: test case mysql-test/t/group_min_max.test: Bug #41610: test case sql/opt_range.cc: Bug #41610: copy the infix data for the current best index
| | * | | | | | MergeMagnus Svensson2009-02-271-0/+15
| | |\ \ \ \ \ \
| | | * | | | | | Bug#43215 6 error codes changed from 5.1 to 6.0Magnus Svensson2009-02-261-0/+15
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | sql/share/errmsg.txt: - Reserve released error codes in 5.1
| | * | | | | | | merged 5.0-bugteam -> 5.1-bugteam.Georgi Kodinov2009-02-271-1/+2
| | |\ \ \ \ \ \ \ | | | | |/ / / / / | | | |/| | | | | | | | | | | | | | | | | | | | | | | Fixed a warning in 5.1 caused by missing type cast.
| | | * | | | | | Bug #41354: Access control is bypassed when all columns Georgi Kodinov2009-02-262-7/+23
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | of a view are selected by * wildcard Backported a part of the fix for 36086 to 5.0 mysql-test/r/view_grant.result: Bug #41354: test case mysql-test/t/view_grant.test: Bug #41354: test case sql/sql_acl.cc: Bug #41354: return table error when no access and * sql/sql_base.cc: Bug #41354: backported the check in bug 36086 to 5.0
| * | | | | | | | Commit for merge and pushStaale Smedseng2009-02-271-1/+7
| |\ \ \ \ \ \ \ \ | | | |_|_|_|_|/ / | | |/| | | | | |
| | * | | | | | | Recommit for merging and pushingStaale Smedseng2009-02-271-1/+6
| | | | | | | | |
* | | | | | | | | Bug#40657: assertion with out of range variables and traditional sql_modeTatiana A. Nurnberg2009-03-051-9/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Some changes that make things more elegant in 6.0, backported so the code is mostly the same in 5.1, for easier maintainence. sql/set_var.cc: Backporting some changes to 5.1 so the code is mostly the same in both versions. Less to learn!
* | | | | | | | | automergeTatiana A. Nurnberg2009-02-271-74/+145
|\ \ \ \ \ \ \ \ \ | |_|_|/ / / / / / |/| | | | | | | |
| * | | | | | | | Bug#40657: assertion with out of range variables and traditional sql_modeTatiana A. Nurnberg2009-02-271-24/+42
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In STRICT mode, out-of-bounds values caused an error message to be queued (rather than just a warning), without any further error-like processing happening. (The error is queued during update, at which time it's too late. For it to be processed properly, it would need to be queued during check-stage.) The assertion rightfully complains that we're trying to send an OK while having an error queued. Changeset breaks a lot of tests out into check-stage. This also allows us to send more correct warnings/error messages. sql/set_var.cc: cleanup: fold get_unsigned() and fix_unsigned() into one, as well as all the semi-common code from the ::check functions.
| * | | | | | | | Bug#40657: assertion with out of range variables and traditional sql_modeTatiana A. Nurnberg2009-02-241-102/+80
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In STRICT mode, out-of-bounds values caused an error message to be queued (rather than just a warning), without any further error-like processing happening. (The error is queued during update, at which time it's too late. For it to be processed properly, it would need to be queued during check-stage.) The assertion rightfully complains that we're trying to send an OK while having an error queued. Changeset breaks a lot of tests out into check-stage. This also allows us to send more correct warnings/error messages. sql/set_var.cc: cleanup: fold get_unsigned() and fix_unsigned() into one, as well as all the semi-common code from the ::check functions.