disallow the use of comma in SET members
mysql-test/r/create.result:
Fix for bug#15316 SET value having comma not correctly handled
test case
mysql-test/t/create.test:
Fix for bug#15316 SET value having comma not correctly handled
test case
into mysql.com:/usr/home/bar/mysql-4.1.b15376
include/m_ctype.h:
Auto merged
strings/ctype-bin.c:
Auto merged
strings/ctype-euc_kr.c:
Auto merged
strings/ctype-gb2312.c:
Auto merged
strings/ctype-ucs2.c:
Auto merged
Fixed that LIKE worked case insensitively for latin2_czech_cs,
which was wrong for a case sensitive collation.
include/m_ctype.h:
Making my_wildcmp_bin public instead of static
strings/ctype-bin.c:
Making my_wildcmp_bin public instead of static
strings/ctype-czech.c:
Use my_wildcmp_bin instead of case insensitive my_wildcmp_8bit
mysql-test/include/have_latin2_ch.inc:
New BitKeeper file ``mysql-test/include/have_latin2_ch.inc''
mysql-test/r/ctype_latin2_ch.result:
New BitKeeper file ``mysql-test/r/ctype_latin2_ch.result''
mysql-test/r/have_latin2_ch.require:
New BitKeeper file ``mysql-test/r/have_latin2_ch.require''
mysql-test/t/ctype_latin2_ch.test:
New BitKeeper file ``mysql-test/t/ctype_latin2_ch.test''
table.cc:
Fixing to use system_charset_info instead of default_charset_info.
Crash happened because the "ctype" array is empty in UCS2,
and thus cannot be used with my_isspace().
The reason why UCS2 appeared in this context was because of
of default_charset_info variable incorrectly substituted to my_isspace().
As functions check_db_name(), check_table_name() and check_column_name()
always get values in utf8, system_charset_info must be used instead.
ctype_ucs2_def.test, ctype_ucs2_def-master.opt, ctype_ucs2_def.result:
new file
sql/table.cc:
Bug#18004 Connecting crashes server when default charset is UCS2
Use of default_charset_info was wrong.
Functions check_db_name, check_table_name and check_column_name
get values of system_charset_info character set (utf8).
mysql-test/lib/mtr_timer.pl:
Fix bug where ^C would trigger cleanup handler in both parent and
timeout child processes, causing duplicated messages and potential
conflicts.
For "count(*) while index_column = value" an index read
is done. It consists of an index scan and retrieval of
each key.
For efficiency reasons the index scan stores the key in
the special buffer 'lastkey2' once only. At the first
iteration it notes this fact with the flag
HA_STATE_RNEXT_SAME in 'info->update'.
For efficiency reasons, the key retrieval for blobs
does not allocate a new buffer, but uses 'lastkey2'...
Now I clear the HA_STATE_RNEXT_SAME flag whenever the
buffer has been polluted. In this case, the index scan
copies the key value again (and sets the flag again).
include/my_base.h:
Bug#14980 - COUNT(*) incorrect on MyISAM table with certain INDEX
Changed the comment for HA_STATE_RNEXT_SAME as a warning
for future uses.
myisam/mi_delete.c:
Bug#14980 - COUNT(*) incorrect on MyISAM table with certain INDEX
Removing the flag HA_STATE_RNEXT_SAME from info->update
if info->lastkey2 was reused for another purpose than
index scanning.
myisam/mi_key.c:
Bug#14980 - COUNT(*) incorrect on MyISAM table with certain INDEX
Removing the flag HA_STATE_RNEXT_SAME from info->update
if info->lastkey2 was reused for another purpose than
index scanning.
myisam/mi_rnext_same.c:
Bug#14980 - COUNT(*) incorrect on MyISAM table with certain INDEX
Removed trailing space and fixed a comment.
myisam/mi_unique.c:
Bug#14980 - COUNT(*) incorrect on MyISAM table with certain INDEX
Removing the flag HA_STATE_RNEXT_SAME from info->update
if info->lastkey2 was reused for another purpose than
index scanning.
myisam/mi_update.c:
Bug#14980 - COUNT(*) incorrect on MyISAM table with certain INDEX
Removing the flag HA_STATE_RNEXT_SAME from info->update
if info->lastkey2 was reused for another purpose than
index scanning.
myisam/mi_write.c:
Bug#14980 - COUNT(*) incorrect on MyISAM table with certain INDEX
Removing the flag HA_STATE_RNEXT_SAME from info->update
if info->lastkey2 was reused for another purpose than
index scanning.
mysql-test/r/myisam.result:
Bug#14980 - COUNT(*) incorrect on MyISAM table with certain INDEX
Added test result.
mysql-test/t/myisam.test:
Bug#14980 - COUNT(*) incorrect on MyISAM table with certain INDEX
Added test.
- Back porting of some changes in later releases
- Corrected valgrind support
- Removed work around for TZ needed in VisualStudio 6
- Don't restart master to add special settings from "<testcase>-master.opt",
if same settngs as running master, feature request in bug#12433
- With --reorder, keep tests with same *-master.opt content together,
to save even more master restarts
mysql-test/lib/mtr_misc.pl:
Added functions to compare lists of options
mysql-test/lib/mtr_cases.pl:
Removed special code for Windows as in VC6 we unset
TZ to avoid library bug
mysql-test/mysql-test-run.pl:
Handle pseudo option --timezone=<spec> that sets TZ
- Decrease "slave_open_temp_tables" during reopen of truncated table.
- Add test "rpl_trunc_temp"
sql/sql_delete.cc:
Decrease "slave_open_temp_tables" after temporary table has been closed, it will be
increased again when the temp table is reopened after it's been truncated.
mysql-test/r/rpl_trunc_temp.result:
New BitKeeper file ``mysql-test/r/rpl_trunc_temp.result''
mysql-test/t/rpl_trunc_temp.test:
New BitKeeper file ``mysql-test/t/rpl_trunc_temp.test''
Check if the host of table hash record exactly matches host from GRANT command
mysql-test/r/grant.result:
Fix for bug#14385 GRANT and mapping to correct user account problems
test case
mysql-test/t/grant.test:
Fix for bug#14385 GRANT and mapping to correct user account problems
test case
union.result, union.test:
Adding test case.
item.cc:
Allow safe character set conversion in UNION
- string constant to column's charset
- to unicode
Thus, UNION now works the same with CONCAT (and other string functions)
in respect of aggregating arguments with different character sets.
sql/item.cc:
Allow character set conversion in UNION
- string to column's charset
- to unicode
Bug#15949 union + illegal mix of collations (IMPLICIT + COERCIBLE)
mysql-test/t/union.test:
Adding test case.
mysql-test/r/union.result:
Adding test case.
mysql-test/mysql-test-run.pl:
Add a "--comment=<string>" option (backport from 5.1).
Its sole purpose is to get logged, so that test evaluation gets easier.
See "Do-compile" for how it is called, and "gen-build-status-page" for its effect.
mysql-test/mysql-test-run.sh:
Add a "--comment=<string>" option, to get it logged when the test is run.
The purpose is to allow a better analysis when generating the status page
("gen-build-status-page").
See "Do-compile" for how it is used.
Fix URLs.
README:
Fix URL.
mysqltest.result:
Update test result for real_sleep error message.
mysqltest.c:
Fix do_sleep() to print correct command name for real_sleep.
client/mysqltest.c:
Fix do_sleep() to print correct command name for real_sleep.
mysql-test/r/mysqltest.result:
Update test result for real_sleep error message.
mysql-test/README:
Fix URL.
mysql-test/mysql-test-run.sh:
Fix URLs.
fixed in 5.0).
A post-review fix (Bug#13134)
mysql-test/r/heap.result:
Remove 'delayed' to make the test deterministic.
mysql-test/r/ps.result:
Remove an unneeded drop table (test case for Bug#13134)
mysql-test/t/heap.test:
Remove 'delayed' to make the test deterministic.
mysql-test/t/ps.test:
A post-review fix (Bug#13134)
column is increasing when table is recreated with PS/SP":
make use of create_field::char_length more consistent in the code.
Reinit create_field::length from create_field::char_length
for every execution of a prepared statement (actually fixes the
bug).
mysql-test/r/ps.result:
Test results fixed (Bug#13134)
mysql-test/t/ps.test:
A test case for Bug#13134 "Length of VARCHAR() utf8 column is
increasing when table is recreated with PS/SP"
sql/field.cc:
Move initialization of create_field::char_length to the constructor
of create_field.
sql/field.h:
Rename chars_length to char_length (to be consistent with
how this term is used throughout the rest of the code).
sql/sql_parse.cc:
Initialize char_length in add_field_to_list. This function
effectively works as another create_field constructor.
sql/sql_table.cc:
Reinit length from char_length for every field in
mysql_prepare_table. This is not needed if we're executing
a statement for the first time, however, at subsequent executions
length contains the number of bytes, not characters (as it's expected
to).
Give space for second and third slave port
mysql-test/mysql-test-run.pl:
Give space for second and third slave port
Define shell variables for all ports, and
list these at startup
mysql-test/mysql-test-run.sh:
Give space for second and third slave port
errorneously abort reporting failure to kill child processes, where in
reality the problem was merely that the child had become a zombie because
of missing waitpid() call.
mysql-test/lib/mtr_process.pl:
Fix race (on some platforms) when killing processes.
Bug #17257 ndb, update fails for inner joins if tables do not have Primary Key
change: the allocated area by setValue may not be around for later, store hidden key in special member variable instead
mysql-test/r/ndb_basic.result:
Bug #17249 delete statement with join where clause fails when table do not have pk
Bug #17257 update fails for inner joins if tables do not have Primary Key
mysql-test/t/ndb_basic.test:
Bug #17249 delete statement with join where clause fails when table do not have pk
Bug #17257 update fails for inner joins if tables do not have Primary Key
sql/ha_ndbcluster.cc:
Bug #17249 delete statement with join where clause fails when table do not have pk
Bug #17257 update fails for inner joins if tables do not have Primary Key
change: the allocated area by setValue may not be around for later, store hidden key in special member variable instead
sql/ha_ndbcluster.h:
Bug #17249 delete statement with join where clause fails when table do not have pk
Bug #17257 update fails for inner joins if tables do not have Primary Key
change: the allocated area by setValue may not be around for later, store hidden key in special member variable instead
This changeset is assumed to stay in 4.1.
client/mysql.cc:
BUG#16217 forced to introduce a separate mysql client command.
Feature is backported from 5.0, precisely
ChangeSet 1.2034 06/02/09 16:23:09 aelkin@mysql.com
(under second review at the moment)
mysql-test/r/mysqlbinlog.result:
changed in 5.0
mysql-test/t/mysqlbinlog.test:
backported from 5.0. The last part of the test to mimic bug#16217
sql/log_event.cc:
Inserting exclaiming comment command for mysql client made differently than in 5.0.
Parsing still is cheap enough not to think to modify server code instead.
mysql-test/r/kill.result:
This result chenged because of the correspondent test change.
mysql-test/t/kill.test:
This test fixed for kill on Mac OS X (which do not send OK)
Bug #17158 load data infile of char values into table of char with no (PK) fails to load
Bug #17081 Doing "LOAD DATA INFILE" directly after delete can cause missing data
mysql-test/r/ndb_load.result:
New BitKeeper file ``mysql-test/r/ndb_load.result''
mysql-test/t/ndb_load.test:
New BitKeeper file ``mysql-test/t/ndb_load.test''
mysql-test/r/ndb_blob.result:
replace+tinyblob back-patch from 5.0
mysql-test/t/ndb_blob.test:
replace+tinyblob back-patch from 5.0
ndb/src/ndbapi/NdbBlob.cpp:
replace+tinyblob back-patch from 5.0
MATCH and FULLTEXT
Fixed that fulltext query using PS results in unexpected behaviour
when executed 2 or more times.
mysql-test/r/fulltext.result:
Testcase for BUG#14496.
mysql-test/t/fulltext.test:
Testcase for BUG#14496.
sql/item_func.h:
In Item_func_match::cleanup() always reset ft_handler to 0.
Bug#16780: Extend port range to make space for 5.1 NDBCLUSTER_PORT_SLAVE
mysql-test/mysql-test-run.sh:
Bug#16780: Extend port range to make space for 5.1 NDBCLUSTER_PORT_SLAVE
mysql-test/t/rpl_ignore_table-slave.opt:
New BitKeeper file ``mysql-test/t/rpl_ignore_table-slave.opt''
mysql-test/t/rpl_ignore_table.test:
New BitKeeper file ``mysql-test/t/rpl_ignore_table.test''
sql/sql_parse.cc:
BUG#15699,16487 merge of the fix made in 5.0
mysql-test/r/rpl_multi_update4.result:
New BitKeeper file ``mysql-test/r/rpl_multi_update4.result''
mysql-test/t/rpl_multi_update4-slave.opt:
New BitKeeper file ``mysql-test/t/rpl_multi_update4-slave.opt''
mysql-test/t/rpl_multi_update4.test:
New BitKeeper file ``mysql-test/t/rpl_multi_update4.test''
mysql-test/r/rpl_ignore_table.result:
New BitKeeper file ``mysql-test/r/rpl_ignore_table.result''
mysql-test/r/update.result:
Testcase for BUG#15935
mysql-test/t/update.test:
Testcase for BUG#15935
sql/sql_update.cc:
BUG#15935:
- Do account for the fact that used_index!=MAX_KEY is also true for cases
when quick select is used, and use quick select then (and not full index scan).
- Also removed the redundant "used_index= MAX_KEY" statement
When setup_fields() function finds field named '*' it expands it to the list
of all table fields. It does so by checking that the first char of
field_name is '*', but it doesn't checks that the '* is the only char.
Due to this, when updating table with a field named like '*name', such field
is wrongly treated as '*' and expanded. This leads to making list of fields
to update being longer than list of the new values. Later, the fill_record()
function crashes by dereferencing null when there is left fields to update,
but no more values.
Added check in the setup_fields() function which ensures that the field
expanding will be done only when '*' is the only char in the field name.
mysql-test/t/update.test:
Added test case for bug#16510: Updating field named like '*name' caused server crash
mysql-test/r/update.result:
Added test case for bug#16510: Updating field named like '*name' caused server crash
sql/sql_base.cc:
Fixed bug #16510: Updating field named like '*name' caused server crash.
Added check in the setup_fields() function which ensures that the field
expanding will be done only when '*' is the only char in the field name.
into mysql.com:/home/mydev/mysql-4.1-bug5390
sql/table.h:
Auto merged
mysql-test/r/lock.result:
BUG#5390 - problems with merge tables
Manual merge from 4.0.
mysql-test/t/lock.test:
BUG#5390 - problems with merge tables
Manual merge from 4.0.
sql/lock.cc:
BUG#5390 - problems with merge tables
Manual merge from 4.0.
After-fix optimizations proposed and finally
implemented by Monty.
mysql-test/r/lock.result:
BUG#5390 - problems with merge tables
After-fix optimizations proposed and finally
implemented by Monty.
Additional test results.
mysql-test/t/lock.test:
BUG#5390 - problems with merge tables
After-fix optimizations proposed and finally
implemented by Monty.
Additional tests.
sql/lock.cc:
BUG#5390 - problems with merge tables
After-fix optimizations proposed and finally
implemented by Monty.
get_lock_data() gets a flag for storing the lock
positions in the new TABLE elements.
mysql_lock_remove() can now remove a lock faster
and more precisely as it has needed info in TABLE now.
mysql_unlock_read_tables() and mysql_lock_merge() must
now adjust the new elements of TABLE when modifying locks.
mysql_lock_have_duplicate() can now work faster on
the existing lock as the positions in the lock
arrays are known for each table.
get_lock_data() assigns the new TABLE elements
on request of the new flag.
sql/table.h:
BUG#5390 - problems with merge tables
After-fix optimizations proposed and finally
implemented by Monty.
Additional elements of TABLE.
mysql-test/r/kill.result:
BUG#14851 test
mysql-test/t/kill.test:
BUG#14851 test
sql/sql_class.cc:
Debug prints are added.
sql/sql_select.cc:
Allocation of tmp_join fixed to involve constructor (it is not related to the bug directly but might cause other problems).
Excluded posibility of tmp_table_param.copy_field double deletion (BUG#14851).
sql/sql_select.h:
JOINs constructor added, initialization of them fixed (it is not related to the bug directly but might cause other problems).
mysql-test/r/ctype_ucs.result:
Test results changed (Bug#13337)
mysql-test/r/ps.result:
Test results changed (Bug#13337)
mysql-test/t/ctype_ucs.test:
Fix Bug#13337 (move the test that uses UCS character set to
ctype_ucs)
mysql-test/t/ps.test:
Fix Bug#13337 (move the test that uses UCS character set to
ctype_ucs)
fix for bug #15828 after review
doing val_str now before testing of null value secures the function for null values returned by dynamic functions - the fix before was incomplete andy covered constant null values
mysql-test/t/date_formats.test:
fix for bug #15828 after review
doing val_str now before testing of null value secures the function for null values returned by dynamic functions - the fix before was incomplete andy covered constant null values
Fixed BUG#14056: Column prefix index on UTF-8 primary key
causes "Can't find record.."
Also fixed bug 15991.
innobase/include/os0file.h:
Changes from innodb-4.1-ss14 snapshot
os_file_hadle_error(): Map the error codes EXDEV, ENOTDIR, and EISDIR
to the new code OS_FILE_PATH_ERROR. Treat this code as OS_FILE_PATH_ERROR.
This fixes the crash on RENAME TABLE when the .ibd file is a symbolic
link to a different file system. (Bug 15991)
innobase/os/os0file.c:
Changes from innodb-4.1-ss14 snapshot
os_file_hadle_error(): Map the error codes EXDEV, ENOTDIR, and EISDIR
to the new code OS_FILE_PATH_ERROR. Treat this code as OS_FILE_PATH_ERROR.
This fixes the crash on RENAME TABLE when the .ibd file is a symbolic
link to a different file system. (Bug 15991)
mysql-test/r/innodb.result:
Changes from innodb-4.1-ss14 snapshot
Fixed BUG#14056: Column prefix index on UTF-8 primary key
causes "Can't find record.."
mysql-test/t/innodb.test:
Changes from innodb-4.1-ss14 snapshot
Fixed BUG#14056: Column prefix index on UTF-8 primary key
causes "Can't find record.."
sql/ha_innodb.cc:
Changes from innodb-4.1-ss14 snapshot
Fixed BUG#14056: Column prefix index on UTF-8 primary key
causes "Can't find record.."
return incorrect result set for a select SQL request"
mysql-test/r/ps.result:
Test results fixed (Bug#12734)
mysql-test/t/ps.test:
A test case for Bug#12734
sql/item_cmpfunc.cc:
Reset canDoTurboBM in Item_func_like::cleanup()
sql/item_cmpfunc.h:
Add Item_func_like::cleanup()
To be uncommented after fixing bug 15805.
mysql-test/r/type_time.result:
Fixing testcases results.
mysql-test/t/type_time.test:
Temporaly commented out testcases which cause type_time.test failure.
To be uncommented after fixing bug 15805.
- When acl_user->host.hostname is NULL compare it as ""
mysql-test/r/grant.result:
Test user with host ''
mysql-test/t/grant.test:
Test user with host ''
sql/sql_acl.cc:
If acl_user->host.hostname is NULL compare it as ""
mysql-test/r/having.result:
Added a test case for bug #14274.
mysql-test/t/having.test:
Added a test case for bug #14274.
sql/sql_select.cc:
Fixed bug #14274: a query with a having clause containing only set function returned a wrong result set.
It happened because processing of the set functions in having started with a call of the split_sum_func
method, instead of the split_sum_func2 method.
- DROP USER command didn't reload the acl_check_hosts cache causing subsequent
connect's via TCP to fail randomly.
- 4.1 version
mysql-test/r/grant2.result:
Update test results
mysql-test/t/grant2.test:
Add test for to check that connect via TCP work after "drop user"
sql/sql_acl.cc:
Reload acl_check_hosts as its memory is mapped to acl_user
Use acl_user->host.hostname when searching the acl_check_hosts list
When InnoDB compares varchar field in ucs2 with given key using bin collation,
it calls my_strnncollsp_ucs2_bin() to perform comparison.
Because field length was lesser than length of key field should be padded
with trailing spaces in order to get correct result.
Because my_strnncollsp_ucs2_bin() was calling my_strnncollp_ucs2_bin(), which
doesn't pads field, wrong comparison result was returned. This results in
wrong result set.
my_strnncollsp_ucs2_bin() now compares fields like my_strnncollsp_ucs2 do,
but using binary collation.
mysql-test/t/ctype_ucs.test:
Test case for bug#14583 Wrong my_strnncollsp_ucs2_bin() behaviour results in skipping
correct records.
mysql-test/r/ctype_ucs.result:
Test case for bug#14583 Wrong my_strnncollsp_ucs2_bin() behaviour results in skipping correct records.
strings/ctype-ucs2.c:
Fix bug#14583 Wrong my_strnncollsp_ucs2_bin() behaviour results in skipping
correct records.my_strnncollsp_ucs2_bin() now compares fields like my_strnncollsp_ucs2 do,
but using binary collation.
field.cc:
BLOB variations have number-in-bytes limit,
unlike CHAR/VARCHAR which have number-of-characters limits.
A tinyblob column can store up to 255 bytes.
In the case of basic Latin letters (which use 1 byte per character)
we can store up to 255 characters in a tinyblob column.
When passing an utf8 tinyblob column as an argument into
a function (e.g. COALESCE) we need to reserve 3*255 bytes.
I.e. multiply length in bytes to mbcharlen for the character set.
Although in reality a tinyblob column can never be 3*255 bytes long,
we need to set max_length to multiply to make fix_length_and_dec()
of the function-caller (e.g. COALESCE) calculate the correct max_length
for the column being created.
ctype_utf8.result, ctype_utf8.test:
Adding test case.
mysql-test/t/ctype_utf8.test:
Adding test case.
mysql-test/r/ctype_utf8.result:
Adding test case.
sql/field.cc:
Bug#15581: COALESCE function truncates mutli-byte TINYTEXT values
BLOB variations have byte limits,
unlike CHAR/VARCHAR which have number-of-character limits.
It means tinyblob can store up to 255 bytes.
All of them can be basic latin letters which use 1 byte
per character.
I.e. we can store up to 255 characters in a tinyblob column.
When passing a tinyblob column as an argument into
a function (for example COALESCE or CONCAT) we
need to reserve 3*255 bytes in the case of utf-8.
I.e. multiply length in bytes to mbcharlen for the
character set.
for uca collation isalnum and strnncollsp don't agree on whether
0xC2A0 is a space (strnncollsp is right, isalnum is wrong).
they still don't, the bug was fixed by avoiding strnncollsp
long fraction and/or large exponent part".
mysql-test/r/type_time.result:
Fixed testcases results (bug #12440)
mysql-test/t/type_time.test:
Added testcases for bug #12440
sql-common/my_time.c:
Fixed bug #12440: "Incorrect processing of time values containing
long fraction and/or large exponent part".
Modified str_to_time(). Process properly fraction part containing
more than 6 digits. Check for existence of exponent part which
may result from %g formatting applied to time value specified as
large real number.
mysql-test/r/ndb_multi.result:
Fix to make ndb_multi.test (Bug #15401 NDB lock problems) more preditable
mysql-test/t/ndb_multi.test:
Fix to make ndb_multi.test (Bug #15401 NDB lock problems) more preditable
table' lockup".
Changes from the innodb-4.1-ss11 snapshot.
Do not call os_file-create_tmpfile() at runtime. Instead, create
a tempfile at startup and guard access to it with a mutex.
Also, fix bugs:
10511: "Wrong padding of UCS2 CHAR columns in ON UPDATE CASCADE";
13778: "If FOREIGN_KEY_CHECKS=0, one can create inconsistent FOREIGN
KEYs". When FOREIGN_KEY_CHECKS=0 we still need to check that
datatypes between foreign key references are compatible.
Also, added test cases (also for bug 9802).
innobase/dict/dict0dict.c:
Changes from the innodb-4.1-ss11 snapshot
innobase/dict/dict0load.c:
Changes from the innodb-4.1-ss11 snapshot
innobase/include/dict0dict.h:
Changes from the innodb-4.1-ss11 snapshot
innobase/include/dict0load.h:
Changes from the innodb-4.1-ss11 snapshot
innobase/include/os0file.h:
Changes from the innodb-4.1-ss11 snapshot
innobase/include/rem0cmp.h:
Changes from the innodb-4.1-ss11 snapshot
innobase/include/srv0srv.h:
Changes from the innodb-4.1-ss11 snapshot
innobase/rem/rem0cmp.c:
Changes from the innodb-4.1-ss11 snapshot
innobase/row/row0ins.c:
Changes from the innodb-4.1-ss11 snapshot
innobase/row/row0mysql.c:
Changes from the innodb-4.1-ss11 snapshot
innobase/srv/srv0srv.c:
Changes from the innodb-4.1-ss11 snapshot
innobase/srv/srv0start.c:
Changes from the innodb-4.1-ss11 snapshot
libmysqld/ha_blackhole.cc:
Changes from the innodb-4.1-ss11 snapshot
mysql-test/r/innodb.result:
Changes from the innodb-4.1-ss11 snapshot
mysql-test/t/innodb.test:
Changes from the innodb-4.1-ss11 snapshot
sql/ha_innodb.cc:
Changes from the innodb-4.1-ss11 snapshot
into parts when converting to Unicode.
m_ctype.h:
Reorganizing mb_wc return codes to be able
to return "an unassigned N-byte-long character".
sql_string.cc:
Adding code to detect and properly handle
unassigned characters (i.e. the those character
which are correctly formed according to the
character specifications, but don't have Unicode
mapping).
Many files:
Fixing conversion function to return new codes.
ctype_ujis.test, ctype_gbk.test, ctype_big5.test:
Adding a test case.
ctype_ujis.result, ctype_gbk.result, ctype_big5.result:
Fixing results accordingly.
include/m_ctype.h:
Reorganizing mb_wc return codes to be able
to return "an unassigned N-byte long character".
Bug#15375 Unassigned multibyte codes are broken into parts when converting to Unicode.
mysql-test/r/ctype_big5.result:
Fixing results accordingly.
mysql-test/r/ctype_gbk.result:
Fixing results accordingly.
mysql-test/r/ctype_ujis.result:
Fixing results accordingly.
mysql-test/t/ctype_big5.test:
Adding a test case.
mysql-test/t/ctype_gbk.test:
Adding a test case.
mysql-test/t/ctype_ujis.test:
Adding a test case.
sql/sql_string.cc:
Adding code to detect and properly hanlde
unassigned characters (i.e. the those character
which are correctly formed according to the
character specifications, but don't have Unicode
mapping).
strings/ctype-big5.c:
Fixing conversion function to return new codes.
strings/ctype-bin.c:
Fixing conversion function to return new codes.
strings/ctype-cp932.c:
Fixing conversion function to return new codes.
strings/ctype-euc_kr.c:
Fixing conversion function to return new codes.
strings/ctype-gb2312.c:
Fixing conversion function to return new codes.
strings/ctype-gbk.c:
Fixing conversion function to return new codes.
strings/ctype-latin1.c:
Fixing conversion function to return new codes.
strings/ctype-simple.c:
Fixing conversion function to return new codes.
strings/ctype-sjis.c:
Fixing conversion function to return new codes.
strings/ctype-tis620.c:
Fixing conversion function to return new codes.
strings/ctype-ucs2.c:
Fixing conversion function to return new codes.
strings/ctype-ujis.c:
Fixing conversion function to return new codes.
strings/ctype-utf8.c:
Fixing conversion function to return new codes.
Fix for bug#12429: Replication tests fail: "Slave_IO_Running" differs:
The value is not important, and it depends on timing. Mask it.
Backport and extension of a fix made by Matthias in 5.0, originally it was
1.1976 05/12/05 17:57:48 mleich@mysql.com
mysql-test/r/rpl_until.result:
Fix for bug#12429: Replication tests fail: "Slave_IO_Running" differs:
The value is not important, and it depends on timing. Mask it.
Backport and extension of a fix made by Matthias in 5.0, originally it was
1.1976 05/12/05 17:57:48 mleich@mysql.com
mysql-test/t/rpl_until.test:
Fix for bug#12429: Replication tests fail: "Slave_IO_Running" differs:
The value is not important, and it depends on timing. Mask it.
Backport and extension of a fix made by Matthias in 5.0, originally it was
1.1976 05/12/05 17:57:48 mleich@mysql.com
mysql-test/r/analyze.result:
test result fixed
mysql-test/t/analyze.test:
test case added
sql/sql_table.cc:
we don't need to remove temporary table from the cache,
but we need to reload it's info
ctype-euc_kr.c:
ctype-gb2312.c:
Adding specific well_formed_length functions
for gb2312 and euckr, to allow storing characters
which are correct according to the character set
specifications but just don't have Unicode mapping.
Previously only those which have Unicode mapping
could be stored, while unassigned characters lead
to data truncation.
Many files:
new file
strings/ctype-gb2312.c:
Bug#15377 Valid multibyte sequences are truncated on INSERT
Adding specific well_formed_length functions
for gb2312 and euckr, to allow storing characters
which are correct according to the character set.
Previously only those which have Unicode mapping
could be stored.
strings/ctype-euc_kr.c:
Adding specific well_formed_length functions
for gb2312 and euckr, to allow storing characters
which are correct according to the character set.
Previously only those which have Unicode mapping
could be stored.
handling so that indexes are closed before trying to commit the
transaction. (Bug #15536)
mysql-test/r/bdb.result:
Add new results
mysql-test/t/bdb.test:
Add new test
sql/sql_delete.cc:
Move call to free_underlaid_joins() to before ha_autocommit_or_rollback().
sql/sql_insert.cc:
Move call to free_underlaid_joins() to before ha_autocommit_or_rollback().
sql/sql_update.cc:
Move call to free_underlaid_joins() to before ha_autocommit_or_rollback().
Bug#14960, reverted code to make symdir work on Windows
symlink.test:
Disabled test case on Windows
mysql-test/t/symlink.test:
Disabled test case on Windows
sql/mysqld.cc:
Bug#14960, reverted code to make symdir work on Windows
Problem #1: INSERT...SELECT, Version for 4.1.
INSERT ... SELECT with the same table on both sides (hidden
below a MERGE table) does now work by buffering the select result.
The duplicate detection works now after open_and_lock_tables()
on the locks.
I did not find a test case that failed without the change in
sql_update.cc. I made the change anyway as it should in theory
fix a possible MERGE table problem with multi-table update.
libmysqld/ha_blackhole.cc:
BUG#5390 - problems with merge tables
No idea, how the symlink change made it into my patch.
mysql-test/r/create.result:
BUG#5390 - problems with merge tables
Removed a duplicate test.
mysql-test/r/merge.result:
BUG#5390 - problems with merge tables
Problem #1: INSERT...SELECT, Version for 4.1.
Added test results.
mysql-test/t/create.test:
BUG#5390 - problems with merge tables
Removed a duplicate test.
mysql-test/t/merge.test:
BUG#5390 - problems with merge tables
Problem #1: INSERT...SELECT, Version for 4.1.
Added tests.
sql/lock.cc:
BUG#5390 - problems with merge tables
Problem #1: INSERT...SELECT, Version for 4.1.
Added a new function to find a duplicate lock in a list of tables.
sql/mysql_priv.h:
BUG#5390 - problems with merge tables
Problem #1: INSERT...SELECT, Version for 4.1.
Added a declaration for the new function.
sql/sql_parse.cc:
BUG#5390 - problems with merge tables
Problem #1: INSERT...SELECT, Version for 4.1.
Changed the duplicate tables detection for INSERT ... SELECT
to use the new function, which does also work for MERGE tables.
sql/sql_update.cc:
BUG#5390 - problems with merge tables
Problem #1: INSERT...SELECT, Version for 4.1.
Changed the duplicate tables detection for UPDATE
to use the new function, which does also work for MERGE tables.
- Set max_length of Item_func_uuid to max_length*system_charset_info->mbmaxlen
Note! Item_func_uuid should be set to use 'ascii' charset when hex(), format(), md5()
etc will use 'ascii'
- Comitting again, the old patch seems to have been lost.
mysql-test/r/func_misc.result:
Test results updated
mysql-test/t/func_misc.test:
Test case
sql/item_strfunc.h:
Multiply max_length of Item_func_uuid with system_charset_info->mbmaxlen
field.cc:
Adding longlong range checking to return
LONGLONG_MIN or LONGLONG_MAX when out of range.
Using (longlong) cast only when range is ok.
cast.test:
Adding test case.
cast.result:
Fixing results accordingly.
sql/field.cc:
Bug#15098 CAST(column double TO signed int), wrong result
Adding longlong range checking.
mysql-test/t/cast.test:
Bug#15098 CAST(column double TO signed int), wrong result
Adding longlong range checking.
mysql-test/r/cast.result:
Fixing results accordingly.
depending on table order
multi_update::send_data() was counting updates, not updated rows. Thus if one
record have several updates it will be counted several times in 'rows matched'
but updated only once.
multi_update::send_data() now counts only unique rows.
sql/sql_update.cc:
Fix bug#15028 Multitable update returns different numbers of matched rows
depending on table order
multi_update::send_data() now counts only unique rows.
mysql-test/t/update.test:
Test case for bug#15028 Multitable update returns different numbers of matched rows depending on table order
mysql-test/r/update.result:
Test case for bug#15028 Multitable update returns different numbers of matched rows depending on table order
to be in the query cache. (BUG#14652)
mysql-test/r/query_cache.result:
BUG#14652 test suite.
mysql-test/t/query_cache.test:
BUG#14652 test suite.
sql/sql_cache.cc:
We should skip beggining '(' characters when test query on possibility
to be in the query cache.
Problem #1: INSERT...SELECT
INSERT ... SELECT with the same table on both sides (hidden
below a MERGE table) does now work by buffering the select result.
The duplicate detection works now after open_and_lock_tables()
on the locks.
I did not find a test case that failed without the change in
sql_update.cc. I made the change anyway as it should in theory
fix a possible MERGE table problem with multi-table update.
mysql-test/r/create.result:
BUG#5390 - problems with merge tables
Removed a duplicate test.
mysql-test/r/merge.result:
BUG#5390 - problems with merge tables
Problem #1: INSERT...SELECT
Added test results.
mysql-test/t/create.test:
BUG#5390 - problems with merge tables
Removed a duplicate test.
mysql-test/t/merge.test:
BUG#5390 - problems with merge tables
Problem #1: INSERT...SELECT
Added tests.
sql/lock.cc:
BUG#5390 - problems with merge tables
Problem #1: INSERT...SELECT
Added a new function to find a duplicate lock in a list of tables.
sql/mysql_priv.h:
BUG#5390 - problems with merge tables
Problem #1: INSERT...SELECT
Added a declaration for the new function.
sql/sql_parse.cc:
BUG#5390 - problems with merge tables
Problem #1: INSERT...SELECT
Changed the duplicate tables detection for INSERT ... SELECT
to use the new function, which does also work for MERGE tables.
sql/sql_update.cc:
BUG#5390 - problems with merge tables
Changed the duplicate tables detection for UPDATE
to use the new function, which does also work for MERGE tables.
CREATE TABLE and PS/SP": make sure that 'typelib' object for
ENUM values and 'Item_string' object for DEFAULT clause are
created in the statement memory root.
mysql-test/r/ps.result:
Test results has been fixed (Bug#14410)
mysql-test/t/ps.test:
A test case for Bug#14410 "Crash in Enum or Set type in CREATE
TABLE and PS/SP"
sql/mysql_priv.h:
typelib() function declaration has been changed.
sql/sql_table.cc:
Supply the statement memory root to use in typelib() and
safe_charset_converter() functions to ensure that objects
created during the first execution of CREATE TABLE statement
are allocated in persistent memory of the statement.
sql/table.cc:
Change typelib() function to require MEM_ROOT.
crash
resolve_const_item() substitutes item which will evaluate to constant with
equvalent constant item, basing on the item's result type. In this case
subselect was resolved as constant, and resolve_const_item() was substituting
it's result's Item_caches to Item_null. Later Item_cache's function was called
for Item_null object, which caused server crash.
resolve_const_item() now substitutes constants for items with
result_type == ROW_RESULT only for Item_rows.
sql/item.cc:
Fix bug #14482 Wrongly applied optimization in resolve_const_item() caused
crash
resolve_const_item() now applies optimization for items with
result_type == ROW_RESULT only to Item_rows.
mysql-test/t/select.test:
Test case for bug #14482 Wrongly applied optimization in resolve_const_item() caused crash
mysql-test/r/select.result:
Test case for bug #14482 Wrongly applied optimization in resolve_const_item() caused crash
item_strfunc.h, item_strfunc.cc, item.cc:
Try to convert a const item into destination
character set. If conversion happens without
data loss, then cache the converted value
and return it during val_str().
Otherwise, if conversion loses data, return
Illeral mix of collations error, as it happened
previously.
ctype_recoding.result, ctype_recoding.test:
Fixing tests accordingly.
sql/item.cc:
Bug#10446 Illegal mix of collations
Try to convert a const item into destination
character set. If conversion happens without
data loss, then cache the converted value
and return it during val_str().
Otherwise, if conversion loses data, return
Illeral mix of collations error, as it happened
previously.
sql/item_strfunc.cc:
Return cached value when it's possible.
mysql-test/t/ctype_recoding.test:
Fixing tests accordingly.
mysql-test/r/ctype_recoding.result:
Fixing tests accordingly.
- Backport from 5.0
include/my_base.h:
Rename HA_CREATE_FROM_ENGINE to HA_OPTION_CREATE_FROM_ENGINE, ie. it's a bit in the table_options variable
mysql-test/r/ndb_basic.result:
Add test result
mysql-test/t/ndb_basic.test:
Add test case for bug14514
sql/ha_ndbcluster.cc:
Use new bitmask for table_options to detect if create from engine
sql/handler.cc:
Use new bit for create from engine
mysql-test/r/ndb_charset.result:
bug#14007 test [re-commit]
mysql-test/t/ndb_charset.test:
bug#14007 test [re-commit]
ndb/include/kernel/AttributeDescriptor.hpp:
bug#14007 4.1 need getSizeInBytes [re-commit]
ndb/src/kernel/blocks/dbtup/DbtupRoutines.cpp:
bug#14007 4.1 *** do not AUTOmerge to 5.0 *** [re-commit]
into mysql.com:/home/mydev/mysql-4.1-4100
mysql-test/r/handler.result:
Auto merged
sql/mysql_priv.h:
Auto merged
sql/sql_base.cc:
Auto merged
sql/sql_class.cc:
Auto merged
mysql-test/t/handler.test:
Bug#14397 - OPTIMIZE TABLE with an open HANDLER causes a crash
Manual merge.
sql/sql_handler.cc:
Bug#14397 - OPTIMIZE TABLE with an open HANDLER causes a crash
Manual merge.
sql/sql_table.cc:
Bug#14397 - OPTIMIZE TABLE with an open HANDLER causes a crash
Manual merge.
ps_grant.result:
Fixing result order.
grant.result:
Adding test case,
fixing result order.
grant.test:
Adding test case.
sql_acl.cc:
Fixed that my_charset_latin1 was incorrectly used instead of system_charset_info.
This problem was previously fixed by Ingo in 5.0.
This patch is basically a backport of the same changes into 4.1.
sql/sql_acl.cc:
Bug#14406 GRANTS ON objects with non-ascii names borked after FLUSH PRIVILEGES
Fixed that my_charset_latin1 was incorrectly used instead of system_charset_info.
This problem was previously fixed by Ingo in 5.0.
This patch is basically a backport of the same changes into 4.1.
mysql-test/t/grant.test:
Adding test case.
mysql-test/r/grant.result:
Adding test case,
fixing result order.
mysql-test/r/ps_grant.result:
Fixing result order.
myisam/ft_parser.c:
word->len calculation correction.
mysql-test/r/fulltext.result:
Test case for bug#5686.
mysql-test/t/fulltext.test:
Test case for bug#5686.
Two handler objects were present, one was used for an insert and the other for a select
The state of the statistics was local to the handler object and thus the other handler
object didn't notice the insert.
Fix included:
1) Add a new variable key_stat_version added to whenever statistics was considered in need
of update (previously key_stats_ok= FALSE in those places)
2) Add a new handler variable key_stat_version assigned whenever key_stats_ok= TRUE was set
previously
3) Fix records_in_range to return records if records <= 1
4) Fix records_in_range to add 2 to rec_per_key to ensure we don't specify 0 or 1 when it isn't
and thus invoking incorrect optimisations.
5) Fix unique key handling for HEAP table in records_in_range
non-deterministic result in the test case for BUG#7947
the bug fix for BUG#7947 now fixed the result of mix_innodb_myisam_binlog test, which
in the past was missing DO RELEASE_LOCK() in the output of SHOW BINLOG EVENTS
mysql-test/r/mix_innodb_myisam_binlog.result:
DO RELEASE_LOCK() was supposed to be there from the very start
mysql-test/r/rpl_bug7947.result:
changed select release_lock() to do release_lock() to avoid having to compare the
non-deterministic result
mysql-test/t/rpl_bug7947.test:
changed select release_lock() to do release_lock() to avoid having to compare the
non-deterministic result
transaction while holding the lock. Also test to make sure other binlogging issues
reported in the bug have been addressed.
sql/item_func.cc:
fix for BUG#7947
mysql-test/r/rpl_bug7947.result:
New BitKeeper file ``mysql-test/r/rpl_bug7947.result''
mysql-test/t/rpl_bug7947.test:
New BitKeeper file ``mysql-test/t/rpl_bug7947.test''
Initialized usable_keys from table->keys_in_use instead of ~0
in test_if_skip_sort_order(). It was possible that a disabled
index was used for sorting.
mysql-test/r/myisam.result:
Bug#14616 - Freshly imported table returns error 124 when using LIMIT
The test result.
mysql-test/t/myisam.test:
Bug#14616 - Freshly imported table returns error 124 when using LIMIT
The test case.
when calculating table->null_fields.
mysql-test/r/create.result:
Testcase for BUG#14480
mysql-test/t/create.test:
Testcase for BUG#14480
sql/sql_table.cc:
BUG#14480: For CREATE ... SELECT ... a field list passed to mysql_prepare_table() contains
instances of create_field for both create-list and select-list. mysql_prepare_table()
matches elements that refer to the same field, and joins them together. When the "join"
is performed, both of create_field structures has already been counted in "null_fields".
This fix makes sure that "null_fields" contains the correct value after two create_field
structures have been joined.
mysql-test/r/csv.result:
correct result file
mysql-test/t/csv.test:
Add test for a bug
sql/examples/ha_tina.cc:
Add O_APPEND flag to my_open. We should always add rows to the end of file
mysql-test/r/csv.result:
update result file
mysql-test/t/csv.test:
Add test for a bug
sql/examples/ha_tina.cc:
sort function should return reverted values for chains to be sorted in
the right orded. don't do a strange memmove
Version for 4.0.
It fixes two problems:
1. The cause of the bug was that we did not check the table version for
the HANDLER ... READ commands. We did not notice when a table was
replaced by a new one. This can happen during ALTER TABLE, REPAIR
TABLE, and OPTIMIZE TABLE (there might be more cases). I call the fix
for this problem "the primary bug fix".
2. mysql_ha_flush() was not always called with a locked LOCK_open.
Though the function comment clearly said it must.
I changed the code so that the locking is done when required. I call
the fix for this problem "the secondary fix".
mysql-test/r/handler.result:
Bug#14397 - OPTIMIZE TABLE with an open HANDLER causes a crash
The test result.
mysql-test/t/handler.test:
Bug#14397 - OPTIMIZE TABLE with an open HANDLER causes a crash
The test case.
sql/mysql_priv.h:
Bug#14397 - OPTIMIZE TABLE with an open HANDLER causes a crash
Changed a definition for the secondary fix.
sql/sql_base.cc:
Bug#14397 - OPTIMIZE TABLE with an open HANDLER causes a crash
Changed function calls for the secondary fix.
sql/sql_class.cc:
Bug#14397 - OPTIMIZE TABLE with an open HANDLER causes a crash
Changed a function call for the secondary fix.
sql/sql_handler.cc:
Bug#14397 - OPTIMIZE TABLE with an open HANDLER causes a crash
The first two diffs make the primary bug fix.
The rest is for the secondary fix.
sql/sql_table.cc:
Bug#14397 - OPTIMIZE TABLE with an open HANDLER causes a crash
Changed function calls for the secondary fix.
Removed wrong fix for bug #14009 (use of abs() on null value causes problems with filesort)
Mark that add_time(), time_diff() and str_to_date() can return null values
myisam/mi_check.c:
keyoffset is not a position (no %lx here)
mysql-test/r/func_sapdb.result:
Fixed test after marking that timediff() can return NULL
sql/item_func.cc:
Removed wrong fix for bug #14009 (use of abs() on null value causes problems with filesort)
sql/item_timefunc.cc:
Mark that add_time and str_to_date() can return null values
sql/item_timefunc.h:
Mark that time_diff can return 0
sql/spatial.cc:
Simple cleanups during review of new code
cause a crash or write to an incorrect memory location. (Bug #14216)
mysql-test/r/union.result:
Update results
mysql-test/t/union.test:
Add regression test
sql/item.cc:
Set max_length for decimal fields correctly
do advance the source pointer over 2 bytes that specify value length.
myisam/mi_key.c:
Fix for BUG#13814: in mi_pack_key(), when processing NULL value for TINYBLOB key segment,
do advance the source pointer over 2 bytes that specify value length (for NULL value the
format is: null_marker 0x01, value length 0x00 0x00, data: 0x00 keyseg->length times).
We need to advance over 2 bytes separately as keyseg->length doesn't include them.
mysql-test/r/myisam.result:
Testcase for BUG#13814
mysql-test/t/myisam.test:
Testcase for BUG#13814
Procedure analyse() redefines select's fields_list. setup_copy_fields() assumes
that fields_list is a part of all_fields_list. Because select have only
3 columns and analyse() redefines it to have 10 columns, int overrun in
setup_copy_fields() occurs and server goes to almost infinite loop.
Because fields_list used not only to send data ad fields types, it's wrong
to allow procedure redefine it. This patch separates select's fileds_list
and procedure's one. Now if procedure is present, copy of fields_list is
created in procedure_fields_list and it is used for sending data and fields.
mysql-test/t/analyse.test:
Test case for bug #14138 ROLLUP and PROCEDURE ANALYSE() hang server
mysql-test/r/analyse.result:
Test case for bug #14138 ROLLUP and PROCEDURE ANALYSE() hang server
sql/sql_select.h:
Fix bug #14138 ROLLUP and PROCEDURE ANALYSE() hang server
To JOIN Added separate fields_list for procedure.
sql/sql_select.cc:
Fix bug #14138 ROLLUP and PROCEDURE ANALYSE() hang server
SELECT's fields_list and procedure's fields_list made split. If procedure is defined
then procedure's fields_list is used to send fields and data.
Date field was declared as not null, thus expression 'datefield is null'
was always false. For SELECT special handling of such cases is used.
There 'datefield is null' converted to 'datefield eq "0000-00-00"'.
In mysql_update() before creation of select added remove_eq_conds() call.
It makes some optimization of conds and in particular performs conversion
from 'is null' to 'eq'.
Also remove_eq_conds() makes some evaluation of conds and if it founds that
conds is always false then update statement is not processed further.
All this allows to perform some update statements process faster due to
optimized conds, and not wasting resources if conds known to be false.
sql/sql_select.cc:
Fix bug#14186 select datefield is null not updated
Remove static from remove_eq_conds()
sql/sql_select.h:
Fix bug#14186 select datefield is null not updated
Added remove_eq_conds() prototype.
mysql-test/r/update.result:
Test case for bug#14186 select datefield is null not updated
mysql-test/t/update.test:
Test case for bug#14186 select datefield is null not updated
sql/sql_update.cc:
Fix bug#14186 select datefield is null not updated
To mysql_update() added call to remove_eq_conds() to optimize conds and convert 'datefield is null' to 'datefield eq 0000-00-00'
include/config-netware.h:
Auto merged
sql/sql_select.cc:
Auto merged
mysql-test/r/select.result:
Manually merged fix for bug#13855
mysql-test/t/select.test:
Manuall merged fix for bug#13855
Made change to mysqlimport to set character_set_database to binary to
make importing various charsets/columns work correctly.
client/mysqlimport.c:
BUG# 12123
Added 'set @@character_set_database=binary' to make loading of tables with
mixed charset types and non-latin characters load.
mysql-test/mysql-test-run.pl:
BUG #12123
Added $MYSQL_IMPORT in order to test mysqlimport bug.
mysql-test/mysql-test-run.sh:
BUG #12123
Added $MYSQL_IMPORT in order to test mysqlimport bug.
mysql-test/r/mysqldump.result:
BUG #12123
Added dumping and reloading (using mysql, mysqldump, and mysqlimport) to
show that this fix handles dumping and reloading of non-latin1 charsets
in table with different charset columns (mixing of charsets, also can be a
UTF table with latin1 tables). Note the select before and after dump and
restore - should be exact.
mysql-test/t/mysqldump.test:
BUG #12123
Added dumping and reloading (using mysql, mysqldump, and mysqlimport) to
show that this fix handles dumping and reloading of non-latin1 charsets
in table with different charset columns (mixing of charsets, also can be a
UTF table with latin1 tables). Note the select before and after dump and
restore - should be exact. (results of this)
avoid multiplying length of field_X by charset->mbmaxlen twice when calculating space
required for field_X in the new table.
mysql-test/r/create.result:
Testcase for BUG#14139
mysql-test/t/create.test:
Testcase for BUG#14139
sql/field.cc:
BUG#14139: Make create_length_to_internal_length() save length-in-characters in
create_field::chars_length.
sql/field.h:
BUG#14139: Add create_length::chars_length where we save length-in-characters, added comments.
sql/sql_table.cc:
BUG#14139: When handling "CREATE TABLE(field_X type_spec,...) SELECT smth AS field_X, ...."
we get two instances of create_field: (1) is occurence of field_X in create list, and (2) is
in select list. If we figure they both refer to the same field, we "join" them according to
some rule that is not explicitly specified anywhere.
When we do this "join", create_field::length already contains length-in-bytes for both, so
when we transfer field length (in characters) from (1) to (2), use length-in-characters that
we have saved in create_length::chars_length.
options to the wrong value. (Bug #12925)
mysql-test/t/mysql_client_test.test:
Add parameter for testing getopt bug
mysys/my_getopt.c:
Remove incorrect and unnecessary casts
tests/mysql_client_test.c:
Add test case for Bug #12925 (my_getopt bug)
collation
By default constant strings in second parameter of date_time() have case
insensitive collation. Because of this expressions date_format(f,'%m') and
date_format(f,'%M') wrongly becomes equal, which results in choosing wrong
column to sort by.
Now if second parameter of date_format() is constant then it's collation is
changed to case sensitive.
sql/item_timefunc.cc:
Fix bug #14016 date_format() 2nd parameter was compared using case insensitive collation.
If second parameter of date_format() is constant then it's collation is changed to case sensitive.
mysql-test/r/date_formats.result:
Test case for bug#14016 2nd parameter was compared using case insensitive collation
mysql-test/t/date_formats.test:
Test case for bug#14016 2nd parameter was compared using case insensitive collation
VALUES() can only refer to table insert going to.
But Item_insert_value::fix_fields() were passing to it's arg full table list,
This results in finding second column which shouldn't be found, and
failing with error about ambiguous field.
Item_insert_value::fix_fields() now passes only first table of full table
list.
sql/item.cc:
Fix bug #14016 date_format() 2nd parameter was compared using case insensitive collation.
If second parameter of date_format() is constant then it's collation is changed to case sensitive.
mysql-test/r/insert_select.result:
Test case for bug#14016 2nd parameter was compared using case insensitive collation
mysql-test/t/insert_select.test:
Test case for bug#14016 2nd parameter was compared using case insensitive collation
ctype-win1250ch.c:
Like range prefix tables were wrong.
ctype_cp1250_ch.result, ctype_cp1250_ch.test:
Adding test case.
strings/ctype-win1250ch.c:
Bug#13347: empty result from query with like and cp1250 charset
Like range prefix tables were wrong.
mysql-test/t/ctype_cp1250_ch.test:
Adding test case.
mysql-test/r/ctype_cp1250_ch.result:
Adding test case.
Option to set environment variable MTR_BUILD_THREAD to a small
number, from what mysql-test-run calculate port numbers that
will not conflict with other runs with different thread num
Makefile.am:
Option to set environment variable MTR_BUILD_THREAD to a small
number, from what mysql-test-run calculate port numbers that
will not conflict with other runs with different thread num
heap/_check.c:
Change arguments to ha_key_cmp
heap/hp_create.c:
Change arguments to ha_key_cmp
include/my_base.h:
Remove SEARCH_RETURN_B_POS and instead always send an array to ha_key_cmp() as last argument
myisam/mi_check.c:
Change arguments to ha_key_cmp
myisam/mi_rnext_same.c:
Change arguments to ha_key_cmp
myisam/mi_search.c:
Change arguments to ha_key_cmp
myisam/mi_write.c:
Change arguments to ha_key_cmp
myisammrg/myrg_queue.c:
Change arguments to ha_key_cmp
mysys/my_handler.c:
Remove SEARCH_RETURN_B_POS and instead always send an array to ha_key_cmp() as last argument
(This removes an if in a loop at the expensive of an int on the stack)
sql/records.cc:
Simplify new rr_index() code
Create common error handling function for rr_() functions.
Remove loop from rr_index() as handler::index_next() can never return HA_ERR_RECORD_DELETED
sql/sql_load.cc:
Simplify
sql/sql_update.cc:
Simplify code
Fixed bug when one is updating an index column that could be used with ORDER BY
sql/structs.h:
Removed not needed structure element
select distinct char(column) fails with utf8
ctype_utf8.result, ctype_utf8.test:
Adding test case
sql_yacc.yy:
Adding new syntax.
item_strfunc.h:
Fixing wrong max_length calculation.
Also, adding CHAR(x USING charset),
for easier migrating from 4.1 to 5.0,
according to Monty's suggestion.
sql/item_strfunc.h:
Bug#13233
select distinct char(column) fails with utf8
Also, adding CHAR(x USING charset),
for easier migrating from 4.1 to 5.0.
sql/sql_yacc.yy:
Adding new syntax.
mysql-test/t/ctype_utf8.test:
Adding test case
mysql-test/r/ctype_utf8.result:
Adding test case
mysql-test/my_manage.c:
Avoid warning: i not used in case of Windows.
mysql-test/mysql_test_run_new.c:
Removed unused variable.
sql/item_func.cc:
Removed unused variables.
strings/ctype-simple.c:
Added cast.
strings/ctype-ucs2.c:
Added cast.
mysql-test/r/func_math.result:
Add new results
mysql-test/t/func_math.test:
Add new regression test
sql/item_func.cc:
Set maybe_null in Item_func_abs::fix_length_and_dec().
mysql-test/r/func_gconcat.result:
result fixed
mysql-test/r/subselect.result:
result fixed
mysql-test/r/type_float.result:
result fixed
mysql-test/t/type_float.test:
testcase added
sql/item_func.cc:
Now we set decimals to NOT_FIXED_DEC if the max_length is longer than
maximum possible double length
DISTINCT wasn't optimized away and caused creation of tmp table in wrong
case. This result in integer overrun and running out of memory.
Fix backported from 4.1. Now if optimizer founds that in result be only 1
row it removes distinct.
sql/sql_select.cc:
Fix bug #13855 select distinct with group by caused server crash
mysql-test/r/select.result:
Test case for bug#13855 select distinct with group by caused server crash
mysql-test/t/select.test:
Test case for bug#13855 select distinct with group by caused server crash
- fixed test
mysql-test/r/rpl_multi_update2.result:
fixed setting/reseting environment
multi-update with subquery added
mysql-test/t/rpl_multi_update2.test:
fixed setting/reseting environment
multi-update with subquery added
sql/sql_update.cc:
set 'updating' in both tables list if we have two of them (because of subquery)
conditions of its first test. (Bug #13796)
mysql-test/t/not_embedded_server-master.opt:
New BitKeeper file ``mysql-test/t/not_embedded_server-master.opt''
- Move test for bug#93 from mysql_client_test.c to show_check.test
- No need for test written in c
mysql-test/r/show_check.result:
Add test case for bug#93, moved from mysql_client_test.c
mysql-test/t/show_check.test:
Add test case for bug#93, moved from mysql_client_test.c
tests/mysql_client_test.c:
Remove test for bug#95 to show_check.test