End of Product Lifecycle. Active development and support for MySQL Database Server versions 3.23, 4.0, and 4.1 has ended. For details, see http://www.mysql.com/about/legal/lifecycle/#calendar. Please consider upgrading to a recent version. Further updates to the content of this manual will be minimal. All formats of this manual will continue to be available until 31 Dec 2010.
Functionality added or changed:
Replication: MySQL Cluster:
Added a new global system variable
slave_transaction_retries: If
the replication slave SQL thread fails to execute a transaction
because of an InnoDB deadlock or exceeded
InnoDB's
innodb_lock_wait_timeout or
NDBCLUSTER's
TransactionDeadlockDetectionTimeout or
TransactionInactiveTimeout, it automatically
retries
slave_transaction_retries times
before stopping with an error. The default is 0, and you must
explicitly set the value greater than 0 to enable the
“retry” behavior.
(Bug#8325)
MySQL Cluster:
More informative error messages are provided when a query is
issued against an NDB table that
has been modified by another mysqld server.
(Bug#6762)
Replication:
For slave replication servers started with
--replicate-* options, statements that should
not be replicated according those options no longer are written
to the slave's general query log.
(Bug#8297)
The use of SESSION or
GLOBAL is now disallowed for user variables.
(Bug#9286)
mysqld_safe will create the directory where the UNIX socket file is to be located if the directory does not exist. This applies only to the last component of the directory path name. (Bug#8513)
ONLY_FULL_GROUP_BY no longer
is included in the ANSI
composite SQL mode.
(Bug#8510)
Added sql_notes session
variable to cause Note-level warnings not to
be recorded.
(Bug#6662)
Modified the parser to allow
SELECT statements following the
UNION keyword to be subqueries in
parentheses.
(Bug#2435)
InnoDB: Commit after every 10,000 copied rows
when executing CREATE INDEX,
DROP INDEX or
OPTIMIZE TABLE, which are
internally implemented as ALTER
TABLE. This makes it much faster to recover from an
aborted operation.
User variable coercibility has been changed from “coercible” to “implicit.” That is, user variables have the same coercibility as column values.
Added --with-big-tables
compilation option to configure. (Previously
it was necessary to pass -DBIG_TABLES to the
compiler manually in order to enable large table support.) See
Section 2.9.2, “Typical configure Options”, for details.
The coercibility for the return value of functions such as
USER() or
VERSION() now is “system
constant” rather than “implicit.” This makes
these functions more coercible than column values so that
comparisons of the two do not result in Illegal mix of
collations errors.
COERCIBILITY() was modified to
accommodate this new coercibility value. See
Section 11.10.3, “Information Functions”.
Added configuration directives !include and
!includedir for including option files and
searching directories for option files. See
Section 4.2.3.3, “Using Option Files”, for usage.
NULL now is considered more coercible than
string constants. This resolves some Illegal mix of
collations conflicts.
Bugs fixed:
Replication: If multiple semicolon-separated statements were received in a single packet, they were written to the binary log as a single event rather than as separate per-statement events. For a server serving as a replication master, this caused replication to fail when the event was sent to slave servers. (Bug#8436)
Replication:
A replication master stamped a generated statement (such as a
SET statement) with an error code intended
only for another statement. This could happen, for example, when
a statement generated a duplicate key error on the master but
still had be to replicated to the slave.
(Bug#8412)
Replication:
If the slave was running with
--replicate-*-table options which excluded one
temporary table and included another, and the two tables were
used in a single DROP TEMPORARY TABLE IF
EXISTS statement, as the ones the master automatically
writes to its binary log upon client's disconnection when client
has not explicitly dropped these, the slave could forget to
delete the included replicated temporary table. Only the slave
needs to be upgraded.
(Bug#8055)
Replication:
Treat user variables as having IMPLICIT
derivation (coercibility) to avoid “Illegal mix of
collations” errors when replicating user variables.
(Bug#6676)
For MyISAM tables,
REPAIR TABLE no longer discard
rows that have incorrect checksum.
(Bug#9824)
Fixed option-parsing code for the embedded server to understand
K, M, and
G suffixes for the
net_buffer_length and
max_allowed_packet options.
(Bug#9472)
Some user variables were not being handled with “implicit” coercibility. (Bug#9425)
Using TIMESTAMP columns with no
minute or second parts in GROUP BY clauses
with the new system variable
set to 1 caused the server to crash.
(Bug#9401)
Allow extra HKSCS and cp950 characters (big5
extension characters) to be accepted in big5
columns.
(Bug#9357)
Subqueries using ALLor ANY
that contained a HAVING clause did not work
correctly.
(Bug#9350)
BLOB( and
M)TEXT( columns,
with M)M less than 256, were being
created as BLOB and
TEXT columns rather than
TINYBLOB or
TINYTEXT columns.
(Bug#9303)
InnoDB: If MySQL wrote to its binlog, but for
some reason trx->update_undo and
trx->insert_undo were NULL in
InnoDB, then
trx->commit_lsn was garbage, and
InnoDB could assert in the log flush of
trx_commit_complete_for_mysql().
(Bug#9277)
The utf8_spanish2_ci and
ucs2_spanish2_ci collations no longer
consider r equal to rr .
If you upgrade to this version from an earlier version, you
should rebuild the indexes of any affected tables.
(Bug#9269)
Depending on index statistics, GROUP BY
could return
incorrect results if the first table processed for a join had
several indexes that cover the grouped columns.
(Bug#9213)col1,
col2, ...
OPTIMIZE TABLE was written twice
to the binary log when used on InnoDB tables.
(Bug#9149)
The CHARSET(),
COLLATION(), and
COERCIBILITY() functions
sometimes returned NULL.
CHARSET() and
COLLATION() returned
NULL when given any of these arguments that
evaluated to NULL: A system function such as
DATABASE(); a column value; and a
user variable. Now CHARSET() and
COLLATION() return the system
character set and collation; the column character set and
collation; and binary.
COERCIBILITY(NULL) now returns
“ignorable” coercibility rather than
NULL.
(Bug#9129)
mysqldump misinterpreted
“_” and
“%” characters in the names of
tables to be dumped as wildcard characters.
(Bug#9123)
Bundled zlib in the source distribution was
upgraded to 1.2.2.
(Bug#9118)
Setting the max_error_count
system variable to 0 resulted in a setting of 1.
(Bug#9072)
The use of XOR together with NOT
ISNULL() erroneously resulted in some outer joins
being converted to inner joins by the optimizer.
(Bug#9017)
MIN(
and
col_name)MAX(
could fail to produce the correct result if
col_name)col_name was contained in multiple
indexes and the optimizer did not choose the first index that
contained the column.
(Bug#8893)
Using a compariosn where the left expression of
IN, ALL, or
ANY was a subquery caused the server to crash
(Bug#8888)
When using the cp1250_czech_cs collation,
empty literal strings were not regarded as equal to empty
character columns.
(Bug#8840)
Binary data stored in BLOB or
BINARY columns would be
erroneously dumped if mysqldump was invoked
with --hex-blob and
--skip-extended-insert arguments. This happened
if data contained characters larger then 0x7F .
(Bug#8830)
Using NOW() in a subquery caused
the server to crash.
(Bug#8824)
In prepared statements, subqueries containing parameters were
erroneously treated as const
tables during preparation, resulting in a server crash.
(Bug#8807)
Killing a filesort could cause an assertion failure. (Bug#8799)
Expressions involving nested
CONCAT() calls and character set
conversion of string constants could return an incorrect result.
(Bug#8785)
Do not try to space-pad BLOB
columns containing ucs2 characters.
(Bug#8771)
This regression was introduced by Bug#7350.
If max_join_size was set, a
query containing a subquery that exceeded the examined-rows
limit could hang.
(Bug#8726)
Table creation for a MyISAM table failed if
DATA DIRECTORY or INDEX
DIRECTORY options were given that specified the path
name to the database directory where the table files would be
created by default.
(Bug#8707)
A rare race condition could cause
FLUSH TABLES WITH READ
LOCK to hang.
(Bug#8682)
InnoDB: If one used LOCK
TABLES, created an InnoDB temp
table, and did a multiple-table update where a
MyISAM table was the update table and the
temp table was a read table, then InnoDB
asserted in row0sel.c because
n_mysql_tables_in_use was 0. Also, we remove
the assertion altogether and just print an error to the
.err log if this important consistency
check fails.
(Bug#8677)
AES_DECRYPT(
could fail to return col_name,key)NULL for invalid values
in col_name, if
col_name was declared as NOT
NULL.
(Bug#8669)
Use of
GROUP_CONCAT(
in a subquery, where x)x was an alias
to a column in the outer query, resulted in a server crash.
(Bug#8656)
Too many rows were returned from queries that combined
ROLLUP and LIMIT if
SQL_CALC_FOUND_ROWS was given.
(Bug#8617)
Incorrect results were returned from queries that combined
SELECT
DISTINCT, GROUP BY , and
ROLLUP.
(Bug#8616)
Queries that combined
SELECT
DISTINCT, SUM(), and
ROLLUP could cause the MySQL server to crash.
(Bug#8615)
A join on two tables failed when each contained a
BIGINT UNSIGNED column that were compared
when their values exceeded 263
– 1. The match failed and the join returned no rows.
(Bug#8562)
LIKE pattern-matching for strings did not
work correctly with the cp1251_bin collation.
(Bug#8560)
MATCH ... AGAINST in natural language mode
could cause a server crash if the FULLTEXT
index was not used in a join (that is,
EXPLAIN did not show
fulltext join mode) and the
search query matched no rows in the table.
(Bug#8522)
perror was printing a spurious extra line of output ("Error code ###: Unknown error ###" printed directly before the correct line with the error message). (Bug#8517)
The tee command could sometimes cause the
mysql client to crash.
(Bug#8499)
The MEMORY storage engine did not properly
increment an AUTO_INCREMENT column if there
was a second composite index that included the column.
(Bug#8489)
REPAIR TABLE did not invalidate
query results in the query cache that were generated from the
table.
(Bug#8480)
For a statement string that contained multiple slow queries, only the last one would be written to the slow query log. (Bug#8475)
When the server was started with
--skip-name-resolve, specifying
host name values that included netmasks in
GRANT statements did not work.
(Bug#8471)
The Cyrillic letters I
(И) and SHORT I
(Й) were treated as being the same
character by the utf8_general_ci collation.
(Bug#8385)
With a database was dropped with
lower_case_table_names = 2,
tables in the database also were dropped but not being flushed
properly from the table cache. If the database was re-created,
the tables also would appear to have been re-created.
(Bug#8355)
When performing boolean full-text searches on
utf8 columns, a double-quote character in the
search string caused the server to crash.
(Bug#8351)
The MAX_CONNECTIONS_PER_HOUR resource limit
was not being reset hourly and thus imposed an absolute limit on
number of connections per account until the server is restarted
or the limits flushed.
(Bug#8350)
The --set-character-set option for
myisamchk was changed to
--set-collation. The value
needed for specifying how to sort indexes is a collation name,
not a character set name.
(Bug#8349)
Corruption of MyISAM table indexes could
occur with TRUNCATE TABLE if the
table had already been opened. For example, this was possible if
the table had been opened implicitly by selecting from a
MERGE table that mapped to the
MyISAM table. The server now issues an error
message for TRUNCATE TABLE under
these conditions.
(Bug#8306)
In string literals with an escape character
(“\”) followed by a multi-byte
character that has a second byte of
“\”, the literal was not
interpreted correctly. The next character now is escaped, not
just the next byte.
(Bug#8303)
On Windows, create shared memory objects with the proper access rights to make them usable when the client and server are running under different accounts. (Bug#8226)
For a query with both GROUP BY and
COUNT(DISTINCT) clauses and a
FROM clause with a subquery,
NULL was returned for any
VARCHAR column selected by the
subquery.
(Bug#8218)
With lower_case_table_names set
to 1, mysqldump on Windows could write the
same table name in different lettercase for different SQL
statements.
(Bug#8216)
Matching of table names by mysqlhotcopy now
accommodates DBD::mysql versions 2.9003 and
up, which implement identifier quoting.
(Bug#8136)
Creating a table using a name containing a character that is
illegal in character_set_client
resulted in the character being stripped from the name and no
error. The character now is considered an error.
(Bug#8041)
mysqldump now avoids writing SET
NAMES to the dump output if the server is older than
version 4.1 and would not understand that statement.
(Bug#7997)
Mixed-case database and table names in the grant tables were
ignored for authentication if the
lower_case_table_names system
variable was set. GRANT will not
create such privileges when
lower_case_table_names is set,
but it is possible to create them by direct manipulation of the
grant tables, or that old grant records were present before
setting the variable.
(Bug#7989)
Accented letters were improperly treated as distinct by the
utf_general_ci collation.
(Bug#7878)
Conversion of strings to doubles is now more accurate for
floating point values that can be represented by integers, such
as 123.45E+02.
(Bug#7840)
ENUM and SET
columns in privilege tables incorrectly had a case-sensitive
collation, resulting in failure of assignments of values that
did not have the same lettercase as given in the column
definitions. The collation was changed to be case insensitive.
(Bug#7617)
The output of the STATUS
(\s) command in mysql had
the values for the server and client character sets reversed.
(Bug#7571)
A problem in index cost calculation caused a USE
INDEX or FORCE INDEX hint not to be
used properly for a LEFT JOIN across indexed
BLOB columns.
(Bug#7520)
Ordering by an unsigned expression (more complex than a column
reference) was treating the value as signed, producing
incorrectly sorted results. HAVING was also
treating unsigned columns as signed.
(Bug#7425)
Changed mysql_server_end() C API
function to restore more variables to their initial state so
that a subsequent call to
mysql_server_init() would not
cause a client program crash.
(Bug#7344)
Made the relay_log_space_limit
system variable show up in the output of
SHOW VARIABLES.
(Bug#7100)
An expression that tested a case-insensitive character column
against string constants that differed in lettercase could fail
because the constants were treated as having a binary collation.
(For example, WHERE city='London' AND
city='london' could fail.)
(Bug#7098, Bug#8690)
When setting integer system variables to a negative value with
SET VARIABLES, the value was treated as a
positive value modulo 232.
(Bug#6958)
If a MyISAM table on Windows had
INDEX DIRECTORY or DATA
DIRECTORY table options, mysqldump
dumped the directory path names with single-backslash path name
separators. This would cause syntax errors when importing the
dump file. mysqldump now changes
“\” to
“/” in the path names on
Windows.
(Bug#6660)
Incorrectly ordered results were returned from a query using a
FULLTEXT index to retrieve rows and there was
another index that was usable for ORDER BY.
For such a query, EXPLAIN showed
the fulltext join type, but
showed the other (not FULLTEXT) index in the
Key column.
(Bug#6635)
Neither SHOW ERRORS nor
SHOW WARNINGS were displaying
Error-level messages.
(Bug#6572)
Retrieving from a view defined as a
SELECT that mixed
UNION ALL and
UNION DISTINCT
resulted in a different result than retrieving from the original
SELECT.
(Bug#6565)
A problem with static variables did not allow building the server on Fedora Core 3. (Bug#6554)
Unions between binary and nonbinary columns failed due to a collation coercibility problem. (Bug#6519)
The CHAR() function was not
ignoring NULL arguments, contrary to the
documentation.
(Bug#6317)
FOUND_ROWS() returned an
incorrect value for preceding
SELECT statements that used no
table or view.
(Bug#6089)
InnoDB: Honor the
--tmpdir startup option when
creating temporary files. Previously, InnoDB
temporary files were always created in the temporary directory
of the operating system. On Netware, InnoDB
will continue to ignore --tmpdir.
(Bug#5822)
The bundled readline library caused a
segmentation fault in mysql when the user
entered Shift+Enter.
(Bug#5672)
The data type for
MAX(
was returned as datetime_col)VARCHAR rather
than DATETIME if the query
included a GROUP BY clause.
(Bug#5615)
Worked around a bug in support for NSS support in
glibc when static linking is used and LDAP is
one of the NSS sources. The workaround is to detect when the bug
causes a segmentation fault and issue a diagnostic message with
information about the problem.
(Bug#4872, Bug#3037)
If the mysql prompt was configured to display the default database name, and that database was dropped, mysql did not update the prompt. (Bug#4802)
Platform and architecture information in version information
produced for --version option on Windows was
always Win95/Win98 (i32). More accurately
determine platform as Win32 or
Win64 for 32-bit or 64-bit Windows, and
architecture as ia32 for x86,
ia64 for Itanium, and axp
for Alpha.
(Bug#4445)
Host name matching didn't work if a netmask was specified for table-specific privileges. (Bug#3309)
InnoDB: An error in mysqld
caused InnoDB in MySQL 4.1.8 to 4.1.10
InnoDB to refuse to use a table created with
MySQL 3.23.49 or earlier if it was in the new compact
InnoDB table format of 5.0.3 or later.
Workaround. Upgrade to 4.1.11 or newer, or dump the table and re-create it with MySQL 3.23.50 or newer before upgrading.
InnoDB: A table with a primary key that
contained at least two column prefixes was prone to memory
corruption. An example of an affected
CREATE TABLE statement is shown
here:
CREATE TABLE t (
a CHAR(100),
b TINYBLOB,
PRIMARY KEY(a(5), b(10))
);
InnoDB: If InnoDB cannot
allocate memory, keep retrying for 60 seconds before we
intentionally crash mysqld; maybe the
memory shortage is just temporary.
my_print_defaults ignored the
--defaults-extra-file and
--defaults-file options.
Privileges could be escalated via database wildcards in
GRANT statements.
(CVE-2004-0957)
InnoDB: Work around a problem in AIX 5.1
patched with ML7 security patch: InnoDB would
refuse to open its ibdata files,
complaining about an operating system error 0.

User Comments
Add your own comment.