into pilot.blaudden:/home/msvensson/mysql/mysql-5.0-maint
mysql-test/t/mysql.test:
Auto merged
mysql-test/t/mysqlbinlog.test:
Auto merged
sql/share/errmsg.txt:
Auto merged
extra/comp_err.c:
Manual merge
"INSERT... ON DUPLICATE KEY UPDATE skips auto_increment values"
didn't make it into 5.0.36 and 5.1.16,
so we need to adjust the bug-detection-based-on-version-number code.
Because the rpl tree has a too old version, rpl_insert_id cannot pass,
so I disable it (like is already the case in 5.1-rpl for the same reason),
and the repl team will re-enable it when they merge 5.0 and 5.1 into
their trees (thus getting the right version number).
mysql-test/t/disabled.def:
rpl_insert_id tests statement-based replication of INSERT ON
DUPLICATE KEY UPDATE. This type of INSERT had BUG#24432, which is
fixed in 5.0.38; we made the slave detect if it is connected to a
<5.0.38 master and if so refuse to replicate.
The problem is that this 5.0-rpl tree, even though it will produce
the 5.0.38 release, still has a 5.0.36 version in configure.in.
Thus rpl_insert_id fails. So I disable it. As soon as the 5.0-rpl
tree gets the changesets from the main 5.0, its version will change
to 5.0.38 and so the repl team will re-enable the test.
sql/slave.cc:
the fix for BUG#24432 didn't make it into 5.0.36 and 5.1.16,
so we need to adjust the bug-detection-based-on-version-number code.
- Return empty string also if count is unsigned and value is 0
mysql-test/r/func_str.result:
Update test result
mysql-test/t/func_str.test:
Add test case for using an unsigned value as count parameter
for REPEAT
sql/item_strfunc.cc:
The repeat function should return the emptystring if
count is unsigned and equal to zero or
count is signed and less than or equal to zero
into mysql.com:/home/my/mysql-5.0
mysys/my_thr_init.c:
Auto merged
ndb/include/util/OutputStream.hpp:
Auto merged
ndb/src/common/debugger/EventLogger.cpp:
Auto merged
ndb/src/kernel/blocks/cmvmi/Cmvmi.cpp:
Auto merged
ndb/src/kernel/blocks/dbdih/Dbdih.hpp:
Auto merged
ndb/src/kernel/blocks/dblqh/Dblqh.hpp:
Auto merged
ndb/src/kernel/blocks/dblqh/DblqhMain.cpp:
Auto merged
ndb/src/kernel/blocks/dbtc/Dbtc.hpp:
Auto merged
ndb/src/kernel/blocks/dbtc/DbtcMain.cpp:
Auto merged
ndb/src/kernel/blocks/dbtup/Dbtup.hpp:
Auto merged
ndb/src/kernel/blocks/ndbcntr/Ndbcntr.hpp:
Auto merged
ndb/src/kernel/blocks/ndbcntr/NdbcntrMain.cpp:
Auto merged
ndb/src/kernel/blocks/qmgr/Qmgr.hpp:
Auto merged
ndb/src/kernel/blocks/qmgr/QmgrMain.cpp:
Auto merged
ndb/src/mgmapi/mgmapi.cpp:
Auto merged
ndb/src/mgmsrv/InitConfigFileParser.cpp:
Auto merged
ndb/src/mgmsrv/MgmtSrvr.cpp:
Auto merged
ndb/src/mgmsrv/MgmtSrvr.hpp:
Auto merged
ndb/src/mgmsrv/Services.cpp:
Auto merged
ndb/src/ndbapi/ClusterMgr.hpp:
Auto merged
ndb/src/ndbapi/SignalSender.cpp:
Auto merged
sql/ha_ndbcluster.cc:
Auto merged
sql/mysqld.cc:
Auto merged
it doesn't select.
This bug was fixed along with bug #16861: User defined variable can
have a wrong value if a tmp table was used.
There the fix consisted of Item_func_set_user_var overloading the method
Item::save_in_field. Consider the query from the test case:
INSERT INTO foo( bar, baz )
SELECT
bar,
@newBaz := 1 + baz
FROM
foo
WHERE
quux <= 0.1;
Here the assignment expression '@newBaz := 1 + baz' is represented by an
Item_func_set_user_var. Its member method save_in_field, which writes the
value of this assignment into the result field, writes the val_xxx() value,
which is not updated at this point. In the fix introduced by the patch,
the save_in_field method reads the actual variable value instead.
See also comment for
ChangeSet@1.2368.1.3, 2007-01-09 23:24:56+03:00, evgen@moonbone.local +4 -0
and comment for
Item_func_set_user_var::save_in_field (item_func.cc)
mysql-test/r/update.result:
BUG#24010
The correct, and expected, result
mysql-test/t/update.test:
BUG#24010
The test case for this bug. When the bug is active, the INSERT ... SELECT
statement will try to insert the values <1, 2> which gives an error
into moonbone.local:/mnt/gentoo64/work/23800-bug1-5.0-opt-mysql
sql/item.cc:
Auto merged
sql/item.h:
Auto merged
sql/mysql_priv.h:
Auto merged
sql/sql_select.cc:
Auto merged
created for sorting.
Any outer reference in a subquery was represented by an Item_field object.
If the outer select employs a temporary table all such fields should be
replaced with fields from that temporary table in order to point to the
actual data. This replacement wasn't done and that resulted in a wrong
subquery evaluation and a wrong result of the whole query.
Now any outer field is represented by two objects - Item_field placed in the
outer select and Item_outer_ref in the subquery. Item_field object is
processed as a normal field and the reference to it is saved in the
ref_pointer_array. Thus the Item_outer_ref is always references the correct
field. The original field is substituted for a reference in the
Item_field::fix_outer_field() function.
New function called fix_inner_refs() is added to fix fields referenced from
inner selects and to fix references (Item_ref objects) to these fields.
The new Item_outer_ref class is a descendant of the Item_direct_ref class.
It additionally stores a reference to the original field and designed to
behave more like a field.
sql/item.cc:
Bug#23800: Correlated sub query returning incorrect results when operated upon.
Now all outer fields are substituted with references to them (Item_outer_ref objects)
in the Item_field::fix_outer_field() function.
The original field is saved in the Item_outer_ref object.
sql/item.h:
Bug#23800: Correlated sub query returning incorrect results when operated upon.
Added the Item_outer_ref class.
sql/mysql_priv.h:
Bug#23800: Correlated sub query returning incorrect results when operated upon.
Added the fix_inner_refs() function prototype.
sql/sql_delete.cc:
Bug#23800: Correlated sub query returning incorrect results when operated upon.
Added call to the fix_inner_refs() function.
sql/sql_select.cc:
Bug#23800: Correlated sub query returning incorrect results when operated upon.
The new function called fix_inner_refs() is added.
mysql-test/r/subselect.result:
Added a test case for bug#23800: Correlated sub query returning incorrect results when
operated upon.
sql/sql_update.cc:
Bug#23800: Correlated sub query returning incorrect results when operated upon.
Added call to the fix_inner_refs() function.
mysql-test/r/subselect3.result:
Corrected test cases result after fix for bug#23800: Correlated sub query returning
incorrect results when operated upon.
mysql-test/t/subselect.test:
Added a test case for bug#23800: Correlated sub query returning incorrect results when
operated upon.
sql/sql_lex.cc:
Bug#23800: Correlated sub query returning incorrect results when operated upon.
Added cleanup of the inner_refs_list.
sql/sql_lex.h:
Bug#23800: Correlated sub query returning incorrect results when operated upon.
The inner_refs_list is added to the SELECT_LEX class.
This also fixes a bug in counting number of rows that are updated when we have many simultanous queries
extra/yassl/src/ssl.cpp:
Removed compiler warning
extra/yassl/taocrypt/src/asn.cpp:
After merge fixes
extra/yassl/testsuite/testsuite.cpp:
Removed compiler warning
mysql-test/r/ndb_lock.result:
After merge fixes
ndb/src/common/debugger/EventLogger.cpp:
Removed compiler warning
ndb/src/common/util/ConfigValues.cpp:
Removed compiler warning
ndb/src/common/util/NdbSqlUtil.cpp:
Removed compiler warning
ndb/src/kernel/blocks/dbtc/DbtcMain.cpp:
Removed compiler warning
ndb/src/kernel/blocks/dbtup/DbtupIndex.cpp:
Removed compiler warning
ndb/src/kernel/blocks/dbtup/DbtupSystemRestart.cpp:
Removed compiler warning
ndb/src/kernel/vm/ndbd_malloc.cpp:
Removed compiler warning
ndb/src/mgmclient/main.cpp:
Removed compiler warning
ndb/src/ndbapi/SignalSender.cpp:
Removed compiler warning
sql/ha_ndbcluster.cc:
Some extra safety
sql/item_cmpfunc.cc:
After merge fixes
sql/item_subselect.cc:
After merge fixes
sql/sql_insert.cc:
After merge fixes
(This actually fixes a bug in old code when many connections are in use)
support-files/compiler_warnings.supp:
Removed some suppressed warnings
into mysql.com:/home/my/mysql-5.0
BitKeeper/etc/ignore:
auto-union
BUILD/SETUP.sh:
Auto merged
Makefile.am:
Auto merged
client/mysql.cc:
Auto merged
cmd-line-utils/readline/display.c:
Auto merged
configure.in:
Auto merged
extra/yassl/include/buffer.hpp:
Auto merged
extra/yassl/include/crypto_wrapper.hpp:
Auto merged
extra/yassl/include/yassl_imp.hpp:
Auto merged
extra/yassl/include/yassl_int.hpp:
Auto merged
extra/yassl/src/crypto_wrapper.cpp:
Auto merged
extra/yassl/taocrypt/include/algebra.hpp:
Auto merged
extra/yassl/taocrypt/include/des.hpp:
Auto merged
extra/yassl/taocrypt/include/hash.hpp:
Auto merged
extra/yassl/taocrypt/include/hmac.hpp:
Auto merged
extra/yassl/taocrypt/include/modarith.hpp:
Auto merged
extra/yassl/taocrypt/include/modes.hpp:
Auto merged
extra/yassl/taocrypt/include/rsa.hpp:
Auto merged
extra/yassl/taocrypt/include/type_traits.hpp:
Auto merged
extra/yassl/taocrypt/mySTL/list.hpp:
Auto merged
extra/yassl/taocrypt/src/aes.cpp:
Auto merged
extra/yassl/taocrypt/src/algebra.cpp:
Auto merged
extra/yassl/testsuite/testsuite.cpp:
Auto merged
include/my_global.h:
Auto merged
include/my_pthread.h:
Auto merged
libmysqld/lib_sql.cc:
Auto merged
myisam/mi_open.c:
Auto merged
mysql-test/mysql-test-run.pl:
Auto merged
mysql-test/r/mysqltest.result:
Auto merged
mysql-test/t/mysqltest.test:
Auto merged
mysys/default.c:
Auto merged
ndb/src/common/transporter/Transporter.cpp:
Auto merged
ndb/src/common/util/File.cpp:
Auto merged
ndb/src/common/util/SocketClient.cpp:
Auto merged
ndb/src/kernel/blocks/cmvmi/Cmvmi.cpp:
Auto merged
ndb/src/kernel/blocks/dbtc/Dbtc.hpp:
Auto merged
ndb/src/kernel/blocks/qmgr/Qmgr.hpp:
Auto merged
ndb/src/kernel/blocks/qmgr/QmgrMain.cpp:
Auto merged
ndb/src/mgmapi/mgmapi.cpp:
Auto merged
ndb/src/mgmclient/CommandInterpreter.cpp:
Auto merged
ndb/src/mgmsrv/ConfigInfo.cpp:
Auto merged
ndb/src/mgmsrv/MgmtSrvr.cpp:
Auto merged
ndb/src/ndbapi/ClusterMgr.hpp:
Auto merged
ndb/src/ndbapi/Ndb.cpp:
Auto merged
ndb/src/ndbapi/NdbScanOperation.cpp:
Auto merged
ndb/src/ndbapi/SignalSender.cpp:
Auto merged
sql/field.cc:
Auto merged
sql/filesort.cc:
Auto merged
sql/ha_myisammrg.cc:
Auto merged
sql/handler.cc:
Auto merged
sql/item.cc:
Auto merged
sql/item.h:
Auto merged
sql/item_cmpfunc.h:
Auto merged
sql/item_func.cc:
Auto merged
sql/item_strfunc.cc:
Auto merged
sql/item_subselect.h:
Auto merged
sql/item_sum.cc:
Auto merged
sql/item_timefunc.cc:
Auto merged
sql/mysql_priv.h:
Auto merged
sql/net_serv.cc:
Auto merged
sql/opt_range.cc:
Auto merged
sql/opt_range.h:
Auto merged
sql/repl_failsafe.cc:
Auto merged
sql/set_var.cc:
Auto merged
sql/set_var.h:
Auto merged
sql/slave.cc:
Auto merged
sql/sql_class.cc:
Auto merged
sql/sql_insert.cc:
Auto merged
sql/sql_lex.cc:
Auto merged
sql/sql_lex.h:
Auto merged
sql/sql_parse.cc:
Auto merged
sql/sql_prepare.cc:
Auto merged
sql/sql_select.cc:
Auto merged
sql/sql_show.cc:
Auto merged
sql/sql_table.cc:
Auto merged
sql/sql_union.cc:
Auto merged
sql/sql_update.cc:
Auto merged
sql-common/client.c:
Auto merged
sql/sql_view.cc:
Auto merged
sql/sql_yacc.yy:
Auto merged
sql/table.cc:
Auto merged
sql/unireg.cc:
Auto merged
extra/yassl/taocrypt/src/asn.cpp:
Manual merge (Fix shadowed variable name)
extra/yassl/taocrypt/test/test.cpp:
No changes
ndb/src/common/util/ConfigValues.cpp:
Manual merge (Fix shadowed variable name)
sql/field.h:
manual merge
sql/ha_myisam.cc:
manual merge
sql/ha_ndbcluster.cc:
manual merge
sql/item_cmpfunc.cc:
manual merge
sql/item_subselect.cc:
Manual merge (Fix shadowed variable name)
sql/mysqld.cc:
no changes
Fixed that --extern works with mysql-test-run.pl
Small trivial cleanups
include/my_global.h:
Fixed unsafe define of uint4korr()
mysql-test/lib/mtr_report.pl:
Removed wrong messages when using --extern
mysql-test/mysql-test-run.pl:
Fixed that --extern works
Print help on stdout instead of stderr (make it easier to pipe it to less)
mysql-test/t/ndb_lock.test:
Added other possible error code
sql/sql_prepare.cc:
Removed not needed casts
into polly.local:/home/kaa/src/maint/mysql-5.0-maint
mysql-test/r/sp.result:
Auto merged
mysql-test/t/innodb.test:
Auto merged
mysql-test/t/mysql.test:
Auto merged
mysql-test/t/mysqlbinlog.test:
Auto merged
mysql-test/t/sp.test:
Auto merged
sql/mysqld.cc:
Auto merged
mysql-test/r/mysqlbinlog.result:
SCCS merged
- Part 2, add @@hostname system variable
mysql-test/r/variables.result:
Add testcase for @@hostname
mysql-test/t/variables.test:
Add testcase for @@hostname
sql/log.cc:
Use pidfile_name as base when generating the default log name
sql/mysqld.cc:
Init "glob_hostname" to that of hostname, fallback to "localhost"
if 'gethostname' should fail.
Init "pidfile_name" to hostname.pid and fallback to "mysql.pid" if
'gethostname' should fail
sql/set_var.cc:
Add new system variable "hostname"
- Add test of bootstrap mode
- Make mysqld return error if bootstrap failed
mysql-test/mysql-test-run.pl:
Remove options --skip-grant-tables as that is always
turned on by --bootstrap
Remove options --console as that does not affect --bootstrap mode
at all
Add environment variable MYSQLD_BOOTSTRAP_CMD containing path
to mysqld and the arguments used for bootstrap
sql/sql_parse.cc:
Abort bootstrap if execution fails
Report error to stderr/log
mysql-test/r/bootstrap.result:
New BitKeeper file ``mysql-test/r/bootstrap.result''
mysql-test/t/bootstrap.test:
New BitKeeper file ``mysql-test/t/bootstrap.test''
into pilot.blaudden:/home/msvensson/mysql/mysql-5.0-maint
client/mysqltest.c:
Auto merged
mysql-test/t/mysqltest.test:
Auto merged
mysql-test/r/mysqltest.result:
SCCS merged
into rakia.gmz:/home/kgeorge/mysql/autopush/B25831-5.0-opt
sql/item.h:
Auto merged
sql/sql_base.cc:
Auto merged
sql/sql_insert.cc:
Auto merged
sql/sql_prepare.cc:
Auto merged
sql/sql_yacc.yy:
Auto merged
Several problems fixed:
1. There was a "catch-all" context initialization in setup_tables()
that was causing the table that we insert into to be visible in the
SELECT part of an INSERT .. SELECT .. statement with no tables in
its FROM clause. This was making sure all the under-initialized
contexts in various parts of the code are not left uninitialized.
Fixed by removing the "catch-all" statement and initializing the
context in the parser.
2. Incomplete name resolution context when resolving the right-hand
values in the ON DUPLICATE KEY UPDATE ... part of an INSERT ... SELECT ...
caused columns from NATURAL JOIN/JOIN USING table references in the
FROM clause of the select to be unavailable.
Fixed by establishing a proper name resolution context.
3. When setting up the special name resolution context for problem 2
there was no check for cases where an aggregate function without a
GROUP BY effectively takes the column from the SELECT part of an
INSERT ... SELECT unavailable for ON DUPLICATE KEY UPDATE.
Fixed by checking for that condition when setting up the name
resolution context.
mysql-test/r/insert_update.result:
Bug #25831: Deficiencies in INSERT ... SELECT ... field name resolving.
- test case
mysql-test/t/insert_update.test:
Bug #25831: Deficiencies in INSERT ... SELECT ... field name resolving.
- test case
sql/item.h:
Bug #25831: Deficiencies in INSERT ... SELECT ... field name resolving.
- save_next_local is not referenced any more outside class methods
sql/sql_base.cc:
Bug #25831: Deficiencies in INSERT ... SELECT ... field name resolving.
- removed a "catch-all" code to cater for correct context initialization
sql/sql_help.cc:
Bug #25831: Deficiencies in INSERT ... SELECT ... field name resolving.
- fixed the name resolution context initialization
sql/sql_insert.cc:
Bug #25831: Deficiencies in INSERT ... SELECT ... field name resolving.
- Fixed the context of resolving the values in INSERT SELECT ON UPDATE
sql/sql_prepare.cc:
Bug #25831: Deficiencies in INSERT ... SELECT ... field name resolving.
- Correct context for name resolution of prepared INSERT .. SELECT
sql/sql_union.cc:
Bug #25831: Deficiencies in INSERT ... SELECT ... field name resolving.
- fixed the name resolution context initialization
sql/sql_yacc.yy:
Bug #25831: Deficiencies in INSERT ... SELECT ... field name resolving.
- Set the context here instead of setup_tables()
mysql-test/r/mysqltest.result:
Update result file after removing one test
mysql-test/t/mysqltest.test:
Remove use of "ls" in system
Rewrite "system echo" which introduces CR/LF problems
with "write_file"
Remove test for end of line junk for "write_file" - it has mismatching number of "'s
The problem happened because those tests were using "cp932" and "ucs2" without checking whether these character sets are available. This fix moves test parts to make character set specific parts be tested only if they are:
- some parts were moved to "ctype_ucs.test" and "ctype_cp932.test"
- some parts were moved to the newly added tests "innodb-ucs2.test", "mysqlbinglog-cp932.test" and "sp-ucs2.test"
mysql-test/r/ctype_cp932.result:
Moved cp932-specific test case from mysql.test
mysql-test/r/innodb.result:
Moved ucs2-specific test cases to innodb-ucs2.test
mysql-test/r/mysql.result:
Move cp932-specific test cases to ctype_cp932.test
mysql-test/r/mysqlbinlog.result:
Moved cp932-specific test case to mysqlbinlog-cp932.test
mysql-test/r/sp.result:
Moved ucs2-specific test case to sp-ucs2.test
mysql-test/t/ctype_cp932.test:
Moved cp932-specific test case from mysql.test
mysql-test/t/ctype_ucs2_def-master.opt:
Use the comma-separated list of character sets to avoid mysql-test errors when ucs2 is not available in the server
mysql-test/t/ctype_ucs2_def.test:
Added requirement for ucs2 in the server
mysql-test/t/innodb.test:
Moved ucs2-specific test cases to innodb-ucs2.test
mysql-test/t/mysql.test:
Move cp932-specific test cases to ctype_cp932.test
mysql-test/t/mysqlbinlog.test:
Moved cp932-specific test case to mysqlbinlog-cp932.test
mysql-test/t/sp.test:
Moved ucs2-specific test case to sp-ucs2.test
sql/mysqld.cc:
Allow specifying several character sets for test purposes, to make "mysqld" start even if the character set being tested is not compiled:
mysqld --default-character-set=ucs2,latin1
The first available character set will be chosen.
mysql-test/r/innodb-ucs2.result:
New BitKeeper file ``mysql-test/r/innodb-ucs2.result''
mysql-test/r/mysqlbinlog-cp932.result:
New BitKeeper file ``mysql-test/r/mysqlbinlog-cp932.result''
mysql-test/r/sp-ucs2.result:
New BitKeeper file ``mysql-test/r/sp-ucs2.result''
mysql-test/t/innodb-ucs2.test:
New BitKeeper file ``mysql-test/t/innodb-ucs2.test''
mysql-test/t/mysqlbinlog-cp932.test:
New BitKeeper file ``mysql-test/t/mysqlbinlog-cp932.test''
mysql-test/t/sp-ucs2.test:
New BitKeeper file ``mysql-test/t/sp-ucs2.test''
UPDATE contains wrong data if the SELECT employs a temporary table.
If the UPDATE values of the INSERT .. SELECT .. ON DUPLICATE KEY UPDATE
statement contains fields from the SELECT part and the select employs a
temporary table then those fields will contain wrong values because they
aren't corrected to get data from the temporary table.
The solution is to add these fields to the selects all_fields list,
to store pointers to those fields in the selects ref_pointer_array and
to access them via Item_ref objects.
The substitution for Item_ref objects is done in the new function called
Item_field::update_value_transformer(). It is called through the
item->transform() mechanism at the end of the select_insert::prepare()
function.
sql/item.cc:
Bug#16630: The update fields of the INSERT .. SELECT .. ON DUPLICATE KEY
UPDATE contains wrong data if the SELECT employs a temporary table.
The new method Item_field::update_value_transformer() is added. It
substitutes fields in the update values list for references
(Item_ref objects) to them.
sql/item.h:
Bug#16630: The update fields of the INSERT .. SELECT .. ON DUPLICATE KEY
UPDATE contains wrong data if the SELECT employs a temporary table.
The update_value_transformer() method is added to the Item and to the
Item_field classes.
sql/sql_insert.cc:
Bug#16630: The update fields of the INSERT .. SELECT .. ON DUPLICATE KEY
UPDATE contains wrong data if the SELECT employs a temporary table.
Traverse update values and substitute fields from the select for
references (Item_ref objects) to them.
sql/sql_select.cc:
Bug#16630: The update fields of the INSERT .. SELECT .. ON DUPLICATE KEY
UPDATE contains wrong data if the SELECT employs a temporary table.
Traverse update values and substitute fields from the select for
references (Item_ref objects) to them.
mysql-test/r/insert_select.result:
Added a test case for bug#16630: The update fields of the INSERT .. SELECT ..
ON DUPLICATE KEY UPDATE contains wrong data if the SELECT employs a
temporary table.
mysql-test/t/insert_select.test:
Added a test case for bug#16630: The update fields of the INSERT .. SELECT ..
ON DUPLICATE KEY UPDATE contains wrong data if the SELECT employs a
temporary table.
into pilot.blaudden:/home/msvensson/mysql/mysql-5.0-maint
client/mysqltest.c:
Auto merged
mysql-test/lib/mtr_misc.pl:
Auto merged
mysql-test/mysql-test-run.pl:
Auto merged
mainly occurs on win2003 64bit.
- Execute "exec" commands directly with cmd.exe and replace "--exec echo ..." with "--exec .\echo.exe ..."
client/mysqltest.c:
Workaround the problem with "echo" in windows not behaving like "echo" in Unix.
- Replace "--exec echo ..." with "--exec <path to mysqltest>\echo.exe" thus forcing
use of our own echo implementation which baheves like on Unix.
- The above change makes it possible to remove the need to execute all --exec's
inside cygwin. Add ifdefs to only use use cygwin's bash conditionally
mysql-test/lib/mtr_misc.pl:
Add function for converting to the OS's native format
mysql-test/mysql-test-run.pl:
Convert path to executables to "windows native" (c:\<path>\) instead of "mixed"(c:/<path>) mode
necessary for pipes and redirects to work properly in cmd.exe
client/echo.c:
New BitKeeper file ``client/echo.c''
duplicate key entries on slave" (two concurrrent connections doing
multi-row INSERT DELAYED to insert into an auto_increment column,
caused replication slave to stop with "duplicate key error" (and
binlog was wrong)), and BUG#26116 "If multi-row INSERT
DELAYED has errors, statement-based binlogging breaks" (the binlog
was not accounting for all rows inserted, or slave could stop).
The fix is that: if (statement-based) binlogging is on, a multi-row
INSERT DELAYED is silently converted to a non-delayed INSERT.
Note: it is not possible to test BUG#25507 in 5.0 (requires mysqlslap),
so it is tested only in the changeset for 5.1. However, BUG#26116
is tested here, and the fix for BUG#25507 is the same code change.
mysql-test/r/innodb-replace.result:
result update
mysql-test/t/innodb-replace.test:
now that multi-row delayed inserts are converted to normal inserts
if the statement-based binlog is enabled,
no error is issued even if this engine does not support INSERT DELAYED,
as the insert does not go through the INSERT DELAYED code.
To preserve the goal of this test, we change the statements to single-
row inserts.
sql/sql_insert.cc:
A multi-row INSERT DELAYED cannot be recorded to a statement-based
binlog in a way that describes the insertions actually done;
in that case we fallback to a non-delayed INSERT.
mysql-test/r/rpl_insert_delayed.result:
result. Master and slave match.
mysql-test/t/rpl_insert_delayed.test:
Test for BUG#26116 (see if one error at first row on master makes the
slave's data incorrect, see if one error at second row on master
makes slave stop).
were evaluated.
According to the new rules for string comparison partial indexes on text
columns can be used in the same cases when partial indexes on varchar
columns can be used.
mysql-test/r/endspace.result:
Adjusted results after the fix for bug #25971.
mysql-test/r/innodb.result:
Adjusted results after the fix for bug #25971.
mysql-test/r/myisam.result:
Adjusted results after the fix for bug #25971.
mysql-test/r/select.result:
Added a test case for bug #25971.
mysql-test/r/type_blob.result:
Adjusted results after the fix for bug #25971.
mysql-test/t/select.test:
Added a test case for bug #25971.
index_read(), whereas it must return HA_ERR_END_OF_FILE
instead (as there are by definition no rows in a table of
that engine.
mysql-test/r/blackhole.result:
Bug#19717: test case
mysql-test/t/blackhole.test:
Bug#19717: test case
sql/ha_blackhole.cc:
Bug#19717: return no rows instead of success.
into pilot.mysql.com:/home/msvensson/mysql/mysql-5.0-maint
mysql-test/mysql-test-run.pl:
Auto merged
sql/item_strfunc.cc:
Auto merged
sql/mysql_priv.h:
Auto merged
sql/mysqld.cc:
Auto merged
sql/set_var.cc:
Auto merged
sql/sql_class.cc:
Auto merged
- Implement --secure-file-priv=<dir> option that limits
"load_file", "LOAD DATA" and "SELECT .. INTO OUTFILE" to work
with files in specified dir.
- Use above option for mysqld in mysql-test-run.pl
mysql-test/mysql-test-run.pl:
Add usage of --secure-file-priv=vardir when starting mysqld
mysql-test/r/loaddata.result:
Update test result after adding test to check that secure-file-priv
works for "load data" and "load_file"
mysql-test/r/outfile.result:
Update result
mysql-test/r/query_cache.result:
Can't load from outside of vardir anymore
mysql-test/r/type_blob.result:
Can't load from outside of vardir anymore
mysql-test/t/loaddata.test:
Update test result after adding test to check that secure-file-priv
works for "load data" and "load_file"
mysql-test/t/outfile.test:
Update test result after adding test to check that secure-file-priv
works for "SELECT .. INTO OUTFILE"
mysql-test/t/query_cache.test:
Can't load from outside of vardir anymore
mysql-test/t/type_blob.test:
Can't load from outside of vardir anymore
sql/item_strfunc.cc:
Check that the path "load_file" uses for the file is within
what's specified with --secure-file-priv
sql/mysql_priv.h:
Add secure_file_priv
sql/mysqld.cc:
Add "--secure_file_priv"
sql/set_var.cc:
Add variable "secure_file_priv" to "show variables"
sql/sql_class.cc:
Check that the path "load_file" uses for the file is within
what's specified with --secure-file-priv
sql/sql_class.h:
Fix spelling error
sql/sql_load.cc:
Check that the path "load_file" uses for the file is within
what's specified with --secure-file-priv
sql/share/errmsg.txt:
Fix swedish error message for ER_OPTION_PREVENTS_STATMENT wich was hardcoded
to --skip-grant-tables
into bk-internal.mysql.com:/data0/bk/mysql-5.0-opt
BitKeeper/etc/gone:
auto-union
mysys/my_getopt.c:
Auto merged
sql/field.h:
Auto merged
sql/item.cc:
Auto merged
sql/item_cmpfunc.cc:
Auto merged
sql/item_cmpfunc.h:
Auto merged
sql/mysql_priv.h:
Auto merged
sql/sql_prepare.cc:
Auto merged
sql/sql_select.cc:
Auto merged
sql/table.cc:
Auto merged
mysql-test/r/select.result:
Manual merge
mysql-test/t/select.test:
Manual merge
into zippy.cornsilk.net:/home/cmiller/work/mysql/mysql-4.1-maint
sql/item.cc:
Auto merged
sql/item_cmpfunc.cc:
Auto merged
sql/item_cmpfunc.h:
Auto merged
sql/sql_select.cc:
Auto merged
ENUMs weren't allowed to have character 0xff, a perfectly good character in some locales.
This was circumvented by mapping 0xff in ENUMs to ',', thereby prevent actual commas from
being used. Now if 0xff makes an appearance, we find a character not used in the enum and
use that as a separator. If no such character exists, we throw an error.
Any solution would have broken some sort of existing behaviour. This solution should
serve both fractions (those with 0xff and those with ',' in their enums), but
WILL REQUIRE A DUMP/RESTORE CYCLE FROM THOSE WITH 0xff IN THEIR ENUMS. :-/
That is, mysqldump with their current server, and restore when upgrading to one with
this patch.
mysql-test/r/type_enum.result:
Bug#24660: "enum" field type definition problem
Show that enums can now contain NAMES_SEP_CHAR (0xff, which is a perfectly respectable
char in some locales), or ',', or both.
mysql-test/t/type_enum.test:
Bug#24660: "enum" field type definition problem
Show that enums can now contain NAMES_SEP_CHAR (0xff, which is a perfectly respectable
char in some locales), or ',', or both.
sql/table.cc:
Bug#24660: "enum" field type definition problem
Revert fix for Bug#20922.
sql/unireg.cc:
Bug#24660: "enum" field type definition problem
Use a field-separator for ENUM-values that is not part of those values. If impossible,
throw error.
The crash happens because second filling of the same I_S table happens in
case of subselect with order by. table->sort.io_cache previously allocated
in create_sort_index() is deleted during second filling
(function get_schema_tables_result). There are two places where
I_S table can be filled: JOIN::exec and create_sort_index().
To fix the bug we should check if the table was already filled
in one of these places and skip processing of the table in second.
mysql-test/r/information_schema.result:
test case
mysql-test/t/information_schema.test:
test case
sql/mysql_priv.h:
added new parameter 'executed_place' to function get_schema_tables_result()
sql/sql_select.cc:
added new parameter 'executed_place' to function get_schema_tables_result()
sql/sql_show.cc:
added more accurate check for cases when we need to refresh I_S table
sql/table.cc:
added more accurate check for cases when we need to refresh I_S table
sql/table.h:
added more accurate check for cases when we need to refresh I_S table
Some fields (GEOMETRY first of all) can't be handled properly in this
case at all. So we return an error in this case
mysql-test/r/default.result:
result fixed
mysql-test/r/gis.result:
result fixed
mysql-test/t/default.test:
VIEW test added
mysql-test/t/gis.test:
testcase added
sql/item.cc:
set_defaults() changed with the 'reset()'
The function make_unireg_sortorder ignored the fact that any
view field is represented by a 'ref' object.
This could lead to wrong results for the queries containing
both GROUP BY and ORDER BY clauses.
mysql-test/r/view.result:
Added a test case for bug #26209.
mysql-test/t/view.test:
Added a test case for bug #26209.
Post fix for bug#12122.
information_schema.result:
Corrected test case after fixing bug#12122.
sql/sql_view.cc:
Post fix for bug#12122.
mysql-test/r/information_schema.result:
Corrected test case after fixing bug#12122.
A wrong order of statements in QUICK_GROUP_MIN_MAX_SELECT::reset
caused a crash when a query with DISTINCT was executed by a loose scan
for an InnoDB table that had been emptied.
mysql-test/r/innodb_mysql.result:
Added a test case for bug #26159.
mysql-test/t/innodb_mysql.test:
Added a test case for bug #26159.
sql/opt_range.cc:
Fixed bug #26159.
A wrong order of statements in QUICK_GROUP_MIN_MAX_SELECT::reset
caused a crash when a query with DISTINCT was executed by a loose scan
for an InnoDB table that had been emptied.
For an empty table quick_prefix_select->reset() was not called at all
and thus some important initialization steps were missing.
present.
A view created with CREATE VIEW ... ORDER BY ... cannot be resolved with
the MERGE algorithm, even when no other part of the CREATE VIEW statement
would require the view to be resolved using the TEMPTABLE algorithm.
The check for presence of the ORDER BY clause in the underlying select is
removed from the st_lex::can_be_merged() function.
The ORDER BY list of the underlying select is appended to the ORDER BY list
mysql-test/t/view.test:
Added a test case for bug#12122: Views with ORDER BY can't be resolved using MERGE algorithm.
mysql-test/r/view.result:
Added a test case for bug#12122: Views with ORDER BY can't be resolved using MERGE algorithm.
sql/sql_lex.cc:
Bug#12122: Views with ORDER BY can't be resolved using MERGE algorithm.
The st_lex::can_be_merged() function now allows views with the ORDER BY
clause to be resolved using MERGE algorithm. The ORDER BY list of the view
is appended to the ORDER BY list of the embedding select.
Objects of the class Item_equal contain an auxiliary member
eval_item of the type cmp_item that is used only for direct
evaluation of multiple equalities. Currently a multiple equality
is evaluated directly only in the cases when the equality holds
at most for one row in the result set.
The compare collation of eval_item was determined incorectly.
It could lead to returning incorrect results for some queries.
mysql-test/r/join_outer.result:
Added a test case for bug #26017.
mysql-test/t/join_outer.test:
Added a test case for bug #26017.
sql/item_cmpfunc.cc:
Fixed bug #26017.
Objects of the class Item_equal contain an auxiliary member
eval_item of the type cmp_item that is used only for direct
evaluation of multiple equalities. Currently a multiple equality
is evaluated directly only in the cases when the equality holds
at most for one row in the result set.
The compare collation of eval_item was determined incorrectly.
It could lead to returning incorrect results for some queries.
sql/item_cmpfunc.h:
Fixed bug #26017.
Removed the cmp_collation member from the Item_equal class as useless
for the current implementation of the class.
inserted.
The select_insert::send_eof() function now resets LAST_INSERT_ID variable if
no rows were inserted.
mysql-test/t/insert_select.test:
Added a test case for bug#23170: LAST_INSERT_ID isn't reset to 0 in INSERT .. SELECT when no rows were inserted.
mysql-test/r/insert_select.result:
Added a test case for bug#23170: LAST_INSERT_ID isn't reset to 0 in INSERT .. SELECT when no rows were inserted.
sql/sql_insert.cc:
Bug#23170: LAST_INSERT_ID isn't reset to 0 in INSERT .. SELECT when no rows were
inserted.The select_insert::send_eof() function now resets LAST_INSERT_ID variable if
no rows were inserted.
"update existingtable set anycolumn=nonexisting order by nonexisting" would crash
the server.
Though we would find the reference to a field, that doesn't mean we can then use
it to set some values. It could be a reference to another field. If it is NULL,
don't try to use it to set values in the Item_field and instead return an error.
Over the previous patch, this signals an error at the location of the error, rather
than letting the subsequent deref signal it.
mysql-test/r/order_by.result:
Verify that all permutations work.
mysql-test/t/order_by.test:
Verify that all permutations work.
sql/item.cc:
When the field is NULL, don't dereference it when we set_field().
Instead, raise an error.
The problem is (most probably) caused by whole server shutting down before a
slave thread terminates correctly. Fixing this requires fixing server shutdown
code which has been done in 5.1 tree. Thus we ignore the issue in 5.0 assuming
that it is fixed in 5.1.
mysql-test/valgrind.supp:
Added a suppresion rule.
"INSERT... ON DUPLICATE KEY UPDATE skips auto_increment values".
When in an INSERT ON DUPLICATE KEY UPDATE, using
an autoincrement column, we inserted some autogenerated values and
also updated some rows, some autogenerated values were not used
(for example, even if 10 was the largest autoinc value in the table
at the start of the statement, 12 could be the first autogenerated
value inserted by the statement, instead of 11). One autogenerated
value was lost per updated row. Led to exhausting the range of the
autoincrement column faster.
Bug introduced by fix of BUG#20188; present since 5.0.24 and 5.1.12.
This bug breaks replication from a pre-5.0.24 master.
But the present bugfix, as it makes INSERT ON DUP KEY UPDATE
behave like pre-5.0.24, breaks replication from a [5.0.24,5.0.34]
master to a fixed (5.0.36) slave! To warn users against this when
they upgrade their slave, as agreed with the support team, we add
code for a fixed slave to detect that it is connected to a buggy
master in a situation (INSERT ON DUP KEY UPDATE into autoinc column)
likely to break replication, in which case it cannot replicate so
stops and prints a message to the slave's error log and to SHOW SLAVE
STATUS.
For 5.0.36->[5.0.24,5.0.34] replication we cannot warn as master
does not know the slave's version (but we always recommended to users
to have slave at least as new as master).
As agreed with support, I'll also ask for an alert to be put into
the MySQL Network Monitoring and Advisory Service.
mysql-test/r/rpl_insert_id.result:
results to check the bugfix; without the bugfix, you would see, in
master and slave:
"3,2" instead of "2,2" for the INSERT VALUES testcase,
"11,6,..." instead of "6,6,..." for the INSERT SELECT testcase.
mysql-test/t/rpl_insert_id.test:
testing that BUG#24432 is fixed
sql/log_event.cc:
A trick to force the master to pretend it is old and features BUG#24432.
To do fast lookups in the list of known bugs by version, we compute
the 3 X.Y.Z numbers from the master's version string and cache that
into a new member Format_description_log_event::server_version_split.
We do this computation in the event's two constructors.
A simple prevention against buffer overrun when reading the master's
version from a binlog event (assume the event is corrupted on disk,
and so the version string on disk is longer than ST_SERVER_VER_LEN
(50), then we would not get a closing 0 at the end of the class member.
sql/log_event.h:
new member to hold the "split server version" (3 numbers X.Y.Z),
and a method to compute this from the version string.
sql/slave.cc:
a function which tells, based on master's version (as found
in the Format_description event in the relay log being executed),
if master can have a certain bug. This function uses a list of
bug_id / first_version_with_bug / first_version_with_fix.
If the test is positive, a short error message is put into SHOW SLAVE
STATUS, and a verbose message is put into the slave's error log.
The caller is expected to stop the slave in this case.
sql/slave.h:
new function to test if the replication master has a bug
sql/sql_insert.cc:
Fix for BUG#24432:t he reason was a misplaced restore_auto_increment()
(misplaced when fixing BUG#20188). Indeed, when updating the row,
it is clear that the autogenerated auto_increment value will not be
used for this row (and if by "chance" the autoinc value present
in the updated row is >= to the not used autogenerated value,
adjust_next_insert_id_after_explicit_value() will fix next_insert_id).
We also add code for a fixed slave to detect that it is connected to
a buggy master (in which case it cannot replicate so stops).
mysql-test/r/rpl_known_bugs_detection.result:
see that SHOW SLAVE STATUS prints information that slave found a bug
in master, and does not execute the dangerous event (table stays
empty).
mysql-test/t/rpl_known_bugs_detection-master.opt:
pass debug symbol to make the master pretend it has BUG#24432
mysql-test/t/rpl_known_bugs_detection.test:
new test to see if bug detection by slave works
View check option clauses were ignored for updates of multi-table
views when the updates could not be performed on fly and the rows
to update had to be put into temporary tables first.
mysql-test/r/view.result:
Added a test case for bug #25931.
mysql-test/t/view.test:
Added a test case for bug #25931.
Adjusted another existed test case to have the correct result.
sql/sql_update.cc:
Fixed bug #25931.
View check option clauses were ignored for updates of multi-table
views when the updates could not be performed on fly and the rows
to update had to be put into temporary tables first.
Added the required check to multi_update::do_updates to fix the problem.
"CONNECTION is a reserved keyword"
Allow connection to be used as an ordinary identifier
Tests included.
mysql-test/r/keywords.result:
test that CONNECTION may be used as ordinary identifier
test that CONNECTION may be used in stored procedure.
mysql-test/t/keywords.test:
test that CONNECTION may be used as ordinary identifier
test that CONNECTION may be used in stored procedure.
sql/sql_yacc.yy:
Set CONNECTION as an unreserved keyword
into mysql.com:/windows/Linux_space/MySQL/mysql-5.0-ndb
ndb/include/ndbapi/NdbIndexScanOperation.hpp:
Auto merged
ndb/include/ndbapi/NdbScanOperation.hpp:
Auto merged
ndb/src/ndbapi/NdbScanOperation.cpp:
Auto merged
sql/ha_ndbcluster.cc:
Auto merged
sql/ha_ndbcluster.h:
Auto merged
with a column of the DATETIME type could return a wrong
result set if the WHERE clause included a BETWEEN condition
on the column.
Fixed the method Item_func_between::fix_length_and_dec
where the aggregation type for BETWEEN predicates calculated
incorrectly if the first argument was a view column of the
DATETIME type.
mysql-test/r/view.result:
Added a test case for bug #26124.
mysql-test/t/view.test:
Added a test case for bug #26124.
updated.
INSERT ... ON DUPLICATE KEY UPDATE reports that a record was updated when
the duplicate key occurs even if the record wasn't actually changed
because the update values are the same as those in the record.
Now the compare_record() function is used to check whether the record was
changed and the update of a record reported only if the record differs
from the original one.
sql/sql_update.cc:
Bug#19978: INSERT .. ON DUPLICATE erroneously reports some records were
updated.
The compare_record() function was changed to non-static one.
sql/sql_insert.cc:
Bug#19978: INSERT .. ON DUPLICATE erroneously reports some records were
updated.
Now the compare_record() function is used to check whether the record was
changed and the update of a record reported only if the record differs
from the original one.
sql/mysql_priv.h:
Bug#19978: INSERT .. ON DUPLICATE erroneously reports some records were
updated.
Added the prototype of the compare_record() function.
mysql-test/t/insert_select.test:
Added a test case for bug#19978: INSERT .. ON DUPLICATE erroneously reports
some records were updated.
mysql-test/r/insert_select.result:
Added a test case for bug#19978: INSERT .. ON DUPLICATE erroneously reports
some records were updated.