Table of Contents
This appendix lists the changes from version to version in the MySQL 5.0 source code through MySQL 5.0.26. For changes made to versions following 5.0.26, see Appendix C, MySQL Enterprise Release Notes, and Appendix D, MySQL Community Server Enhancements and Release Notes.
Starting with MySQL 5.0, we began offering a new version of the Manual for each new series of MySQL releases (5.0, 5.1, and so on). For information about changes in previous release series of the MySQL database software, see the corresponding version of this Manual. For information about legacy versions of the MySQL software through the 4.1 series, see MySQL 3.23, 4.0, 4.1 Reference Manual.
We update this section as we add new features in the 5.0 series, so that everybody can follow the development process.
Note that we tend to update the manual at the same time we make changes to MySQL. If you find a recent version of MySQL listed here that you can't find on our download page (http://dev.mysql.com/downloads/), it means that the version has not yet been released.
The date mentioned with a release version is the date of the last BitKeeper ChangeSet on which the release was based, not the date when the packages were made available. The binaries are usually made available a few days after the date of the tagged ChangeSet, because building and testing all packages takes some time.
The manual included in the source and binary distributions may not be fully accurate when it comes to the release changelog entries, because the integration of the manual happens at build time. For the most up-to-date release changelog, please refer to the online version instead.
The following changelog shows what has been done in the 5.0 tree:
Basic support for read-only server side cursors. For information
about using cursors within stored routines, see
Section 19.2.9, “Cursors”. For information about using cursors
from within the C API, see
Section 24.2.7.3, “mysql_stmt_attr_set()”.
Basic support for (updatable) views. See, for example,
Section 21.2, “CREATE VIEW Syntax”.
Basic support for stored procedures and functions (SQL:2003 style). See Chapter 19, Stored Procedures and Functions.
Initial support for rudimentary triggers.
Added SELECT INTO
, which can be
of mixed (that is, global and local) types. See
Section 19.2.7.3, “list_of_varsSELECT ... INTO Statement”.
Removed the update log. It is fully replaced by the binary log.
If the MySQL server is started with
--log-update, it is translated to
--log-bin (or ignored if the server is
explicitly started with --log-bin), and a
warning message is written to the error log. Setting
SQL_LOG_UPDATE silently sets
SQL_LOG_BIN instead (or do nothing if the
server is explicitly started with --log-bin).
Support for the ISAM storage engine has been
removed. If you have ISAM tables, you should
convert them before upgrading. See
Section 2.4.17.2, “Upgrading from MySQL 4.1 to 5.0”.
Support for RAID options in
MyISAM tables has been removed. If you have
tables that use these options, you should convert them before
upgrading. See Section 2.4.17.2, “Upgrading from MySQL 4.1 to 5.0”.
User variable names are now case insensitive: If you do
SET @a=10; then SELECT @A;
now returns 10. Case sensitivity of a
variable's value depends on the collation of the value.
Strict mode, which in essence means that you get an error instead of a warning when inserting an incorrect value into a column. See Section 5.1.6, “SQL Modes”.
VARCHAR and VARBINARY
columns remember end space. A VARCHAR() or
VARBINARY column can contain up to 65,535
characters or bytes, respectively.
MEMORY (HEAP) tables can
have VARCHAR columns.
When using a constant string or a function that generates a
string result in CREATE ... SELECT, MySQL
creates the result column based on the maximum length of the
string or expression:
| Maximum Length | Data type |
| = 0 | CHAR(0) |
| < 512 | VARCHAR( |
| >= 512 | TEXT |
A fixed-point math library is introduced that supports precision
math, resulting in more accurate results when working with the
DECIMAL and NUMERIC data
types. For details, see Chapter 23, Precision Math.
For a full list of changes, please refer to the changelog sections for each individual 5.0.x release.
Beginning with MySQL 5.0.27, change notes are listed separately for MySQL Enterprise and MySQL Community Server. See Appendix C, MySQL Enterprise Release Notes, and Appendix D, MySQL Community Server Enhancements and Release Notes.
This is a bugfix release for the current production release family.
This section documents all changes and bug fixes that have been applied since the last official MySQL release. If you would like to receive more fine-grained and personalized update alerts about fixes that are relevant to the version and features you use, please consider subscribing to MySQL Enterprise (a commercial MySQL offering). For more details please see http://www.mysql.com/products/enterprise.
Functionality added or changed:
Important Change: MySQL Cluster:
LOAD DATA INFILE no longer causes an implicit
commit for all storage engines. It now causes an implicit commit
only for tables using the NDB storage engine.
(Bug#11151)
The number of InnoDB threads is no longer
limited to 1,000 on Windows.
(Bug#22268)
mysqldump now has a
--flush-privileges option. It causes
mysqldump to emit a FLUSH
PRIVILEGES statement after dumping the
mysql database. This option should be used
any time the dump contains the mysql database
and any other database that depends on the data in the
mysql database for proper restoration.
(Bug#21424)
The output generated by the server when using the
--xml option has changed with regard to null
values. It now matches the output from mysqldump
--xml . That is, a column containing
a NULL value is now reported as
<field name="column_name" xsi:nil="true" />
whereas a column containing the string value
'NULL' is reported as
<field name="column_name">NULL</field>
and a column containing an empty string is reported as
<field name="column_name">>/field>
The source distribution has been updated so that the UDF example can be compiled under Windows with CMake. See Section 27.2.4.5, “Compiling and Installing User-Defined Functions”. (Bug#19121)
The LOAD DATA FROM MASTER and LOAD
TABLE FROM MASTER statements are deprecated. See
Section 12.6.2.2, “LOAD DATA FROM MASTER Syntax”, for recommended
alternatives.
(Bug#9125, Bug#20596, Bug#14399, Bug#12187, Bug#15025, Bug#18822)
Bugs fixed:
Deleting entries from a large MyISAM index
could cause index corruption when it needed to shrink. Deletes
from an index can happen when a record is deleted, when a key
changes and must be moved, and when a key must be un-inserted
because of a duplicate key. This can also happen in
REPAIR TABLE when a duplicate key is found
and in myisamchk when sorting the records by
an index.
(Bug#22384)
yaSSL had a conflicting definition for
socklen_t on hurd-i386 systems.
(Bug#22326)
Conversion of values inserted into a BIT
column could affect adjacent columns.
(Bug#22271)
mysql_com.h unnecessarily referred to the
ulong type.
(Bug#22227)
The source distribution would not build on Windows due to a
spurious dependency on ib_config.h.
(Bug#22224)
Execution of a prepared statement that uses an
IN subquery with aggregate functions in the
HAVING clause could cause a server crash.
(Bug#22085)
Using GROUP_CONCAT() on the
result of a subquery in the FROM clause that
itself used GROUP_CONCAT() could
cause a server crash.
(Bug#22015)
A query that used GROUP BY and an
ALL or ANY quantified
subquery in a HAVING clause could trigger an
assertion failure.
(Bug#21853)
UPGRADE was treated as a reserved word,
although it is not.
(Bug#21772)
The value of LAST_INSERT_ID()
was not always updated correctly within stored routines.
(Bug#21726)
A function result in a comparison was replaced with a constant by the optimizer under some circumstances when this optimization was invalid. (Bug#21698)
If mysqld was linked against a
system-installed zlib library compiled
without large-file support, it would likely exit with a
SIGXFSZ (file size exceeded) signal if an
ARCHIVE table reached 2GB. The server now
checks for space before writing.
(Bug#21675)
The presence of a subquery in the ON clause
of a join in a view definition prevented the
MERGE algorithm from being used for the view
in cases where it should be allowed.
(Bug#21646)
When records are merged from the insert buffer and the page
needs to be reorganized, InnoDB used
incorrect column length information when interpreting the
records of the page. This caused a server crash due to apparent
corruption of secondary indexes in
ROW_FORMAT=COMPACT that contain prefix
indexes of fixed-length columns. Data files should not be
corrupted, but the crash was likely to repeat every time the
server was restarted.
(Bug#21638)
For character sets having a mbmaxlen value of
2, any ALTER TABLE statement changed
TEXT columns to
MEDIUMTEXT.
(Bug#21620)
mysql displayed an empty string for
NULL values.
(Bug#21618)
For INSERT ... ON DUPLICATE KEY UPDATE, use
of
VALUES(
within the col_name)UPDATE clause sometimes was
handled incorrectly.
(Bug#21555)
Subqueries with aggregate functions but no
FROM clause could return incorrect results.
(Bug#21540)
The server could crash for the second execution of a function
containing a SELECT statement that uses an
aggregating IN subquery.
(Bug#21493)
myisam_ftdump produced bad counts for common words. (Bug#21459)
The URL into the online manual that is printed in the stack trace message by the server was out of date. (Bug#21449)
Table aliases in multiple-table DELETE
statements sometimes were not resolved.
(Bug#21392)
mysql_config --libmysqld-libs did not produce
any SSL options necessary for linking
libmysqld with SSL support enabled.
(Bug#21239)
In the package of pre-built time zone tables that is available
for download at timezones.html, the tables now
explicitly use the utf8 character set so that
they work the same way regardless of the system character set
value.
(Bug#21208)
A subquery that uses an index for both the
WHERE and ORDER BY clauses
produced an empty result.
(Bug#21180)
mysql_upgrade produced a malformed
upgrade_defaults file by overwriting the
[client] group header with a
password option. This prevented
mysqlcheck from running successfully when
invoked by mysql_upgrade.
(Bug#21011)
On Windows, inserting into a MERGE table
after renaming an underlying MyISAM table
caused a server crash.
(Bug#20789)
Within stored routines, some error messages were printed incorrectly. A non-null-terminated string was passed to a message-printing routine that expected a null-terminated string. (Bug#20778)
INSERT DELAYED did not honor SET
INSERT_ID or the auto_increment_*
system variables.
(Bug#20627, Bug#20830)
If the auto_increment_offset setting causes
MySQL to generate a value larger than the column's maximum
possible value, the INSERT statement is
accepted in strict SQL mode, whereas but should fail with an
error.
(Bug#20573)
User names have a maximum length of 16 characters (even if they contain multi-byte characters), but were being truncated to 16 bytes. (Bug#20393)
PROCEDURE ANALYSE() returned incorrect values
of M
FLOAT( and
M,
D)DOUBLE(.
(Bug#20305)M,
D)
For a MyISAM table locked with LOCK
TABLES ...WRITE, queries optimized using the
index_merge method did not show rows inserted
with the lock in place.
(Bug#20256)
SUBSTRING() results sometimes
were stored improperly into a temporary table when multi-byte
character sets were used.
(Bug#20204)
For an ENUM column that used the
ucs2 character set, using ALTER
TABLE to modify the column definition caused the
default value to be lost.
(Bug#20108)
Join conditions using index prefixes on utf8
columns of InnoDB tables incorrectly ignored
rows where the length of the actual value was greater than the
length of the index prefix.
(Bug#19960)
make install tried to build files that should already have been built by make all, causing a failure if installation was performed using a different account than the one used for the initial build. (Bug#19738)
For a MyISAM table with a
FULLTEXT index, compression with
myisampack or a check with
myisamchk after compression resulted in table
corruption.
(Bug#19702)
Column names supplied for a view created on a master server could be lost on a slave server. (Bug#19419)
The build process incorrectly tried to overwrite
sql/lex_hash.h. This caused the build to
fail when using a shadow link tree pointing to original sources
that were owned by another account.
(Bug#18888)
Linking the pthreads library to
single-threaded MySQL libraries caused
dlopen() to fail at runtime on HP-UX.
(Bug#18267)
The source distribution failed to compile when configured with
the --with-libwrap option.
(Bug#18246)
Queries containing a subquery that used aggregate functions could return incorrect results. (Bug#16792)
Row equalities (such as WHERE (a,b) = (c,d)
were not taken into account by the optimizer, resulting in slow
query execution. Now they are treated as conjunctions of
equalities between row elements.
(Bug#16081)
BIN(),
OCT(), and
CONV() did not work with BIT
values.
(Bug#15583)
The parser rejected queries that selected from a table twice
using a UNION within a subquery. The parser
now supports arbitrary subquery, join, and parenthesis
operations within EXISTS subqueries. A
limitation still exists for scalar subqueries: If the subquery
contains UNION, the first
SELECT of the UNION cannot
be within parentheses. For example, SELECT (SELECT a
FROM t1 UNION SELECT b FROM t2) will work, but
SELECT ((SELECT a FROM t1) UNION (SELECT b FROM
t2)) will not.
(Bug#14654)
On Mac OS X, zero-byte read() or
write() calls to an SMB-mounted filesystem
could return a non-standard return value, leading to data
corruption. Now such calls are avoided.
(Bug#12620)
The server returns a more informative error message when it
attempts to open a MERGE table that has been
defined to use non-MyISAM tables.
(Bug#10974)
With TRADITIONAL SQL mode, assignment of
out-of-bound values and rounding of assigned values was done
correctly, but assignment of the same numbers represented as
strings sometimes was handled differently.
(Bug#6147)
On an INSERT into an updatable but
non-insertable view, an error message was issued stating that
the view was not updatable. Now the message says the view is not
insertable-into.
(Bug#5505)
EXPLAIN sometimes returned an incorrect
select_type for a SELECT
from a view, compared to the select_type for
the equivalent SELECT from the base table.
(Bug#5500)
Incorporated some portability fixes into the definition of
__attribute__ in
my_global.h.
(Bug#2717)
End of Product LifecycleActive development and support for MySQL database server versions 3.23, 4.0, and 4.1 has ended. However, for MySQL 4.0 and 4.1, there is still extended support available. For details, see http://www.mysql.com/company/legal/lifecycle/#calendar. According to the MySQL Lifecycle Policy (see http://www.mysql.com/company/legal/lifecycle/#policy), only Security and Severity Level 1 issues will still be fixed for MySQL 4.0 and 4.1. Please consider upgrading to a recent version (MySQL 5.0 or 5.1).
This is a bugfix release for the current production release family. This version was released as MySQL Classic 5.0.25 to commercial customers only.
This section documents all changes and bug fixes that have been applied since the last official MySQL release. If you would like to receive more fine-grained and personalized update alerts about fixes that are relevant to the version and features you use, please consider subscribing to MySQL Enterprise (a commercial MySQL offering). For more details please see http://www.mysql.com/products/enterprise.
Functionality added or changed:
MySQL now can do stack dumps on x86_64 and
i386/NPTL systems.
(Bug#21250)
The mysqld and mysqlmanager manpages have been reclassified from volume 1 to volume 8. (Bug#21220)
InnoDB now honors IGNORE
INDEX. Perviously using IGNORE
INDEX in cases where an index sort would be slower
than a filesort had no effect when used with
InnoDB tables.
This fix was reverted in MySQL 5.0.26, and a new fix made in MySQL 5.0.40.
TIMESTAMP columns that are NOT
NULL now are reported that way by SHOW
COLUMNS and INFORMATION_SCHEMA.
(Bug#20910)
The MySQL distribution now compiles on UnixWare 7.13. (Bug#20190)
configure now defines the symbol
DBUG_ON in config.h to
indicate whether the source tree is configured to be compiled
with debugging support.
(Bug#19517)
mysql_upgrade no longer reads the
[client] option file group because it is not
a client and did not understand client options such as
host. Now it reads only the
[mysql_upgrade] group.
(Bug#19452)
For mysqlshow, if a database name argument
contains wildcard characters (such as “
_ ”) but matches a single database
name exactly, treat the name as a literal name. This allows a
command such as mysqlshow information_schema
work without having to escape the wildcard character.
(Bug#19147)
On Windows, typing Control-C while a query was running caused the mysql client to crash. Now it causes mysql to attempt to kill the current statement. If this cannot be done, or Control-C is typed again before the statement is killed, mysql exits. (In other words, mysql's behavior with regard to Control-C is now the same as it is on Unix platforms.) (Bug#17926)
See also Bug#1989
The VIEW_DEFINITION column of the
INFORMATION_SCHEMA VIEWS
table now contains information about the view algorithm.
(Bug#16832)
The bundled yaSSL library licensing has added a FLOSS exception
similar to MySQL to resolve licensing incompatibilities with
MySQL. (See the
extra/yassl/FLOSS-EXCEPTIONS file in a
MySQL source distribution for details.)
(Bug#16755)
Table comments longer than 60 characters and column comments longer than 255 characters were truncated silently. Now a warning is issued, or an error in strict mode. (Bug#13934)
The mysql client used the default character
set if it automatically reconnected to the server, which is
incorrect if the character set had been changed. To enable the
character set to remain synchronized on the client and server,
the mysql command charset
(or \C) that changes the default character
set and now also issues a SET NAMES
statement. The changed character set is used for reconnects.
(Bug#11972)
If a DROP VIEW statement named multiple
views, it stopped with an error if a non-existent view was named
and did not drop the remaining views. Now it continues on and
reports an error at the end, similar to DROP
TABLE.
(Bug#11551)
The server now issues a warning if it removes leading spaces from an alias. (Bug#10977)
For a successful dump, mysqldump now writes a SQL comment to the end of the dump file in the following format:
-- Dump completed on YYYY-MM-DD hh:mm:ss
For spatial data types, the server formerly returned these as
VARSTRING values with a binary collation. Now
the server returns spatial values as BLOB
values.
(Bug#10166)
A new system variable, lc_time_names,
specifies the locale that controls the language used to display
day and month names and abbreviations. This variable affects the
output from the DATE_FORMAT(),
DAYNAME() and
MONTHNAME() functions. See
Section 9.8, “MySQL Server Locale Support”.
Using --with-debug to configure MySQL with
debugging support enables you to use the
--debug="d,parser_debug" option when
you start the server. This causes the Bison parser that is used
to process SQL statements to dump a parser trace to the server's
standard error output. Typically, this output is written to the
error log.
The bundled yaSSL library was upgraded to version 1.3.7.
Bugs fixed:
Security Fix:
A stored routine created by one user and then made accessible to
a different user using GRANT EXECUTE could be
executed by that user with the privileges of the routine's
definer.
(Bug#18630, CVE-2006-4227)
Security Fix: On Linux, and possibly other platforms using case-sensitive filesystems, it was possible for a user granted rights on a database to create or access a database whose name differed only from that of the first by the case of one or more letters. (Bug#17647, CVE-2006-4226)
MySQL Cluster: Packaging:
The ndb_mgm program was included in both the
MySQL-ndb-tools and
MySQL-ndb-management RPM packages, resulting
in a conflict if both were installed. Now
ndb_mgm is included only in
MySQL-ndb-tools.
(Bug#21058)
MySQL Cluster:
Setting TransactionDeadlockDetectionTimeout
to a value greater than 12000 would cause scans to deadlock,
time out, fail to release scan records, until the cluster ran
out of scan records and stopped processing.
(Bug#21800)
MySQL Cluster: A memory leak occurred when running ndb_mgm -e "SHOW". (Bug#21670)
MySQL Cluster: The server provided a non-descriptive error message when encountering a fatally corrupted REDO log. (Bug#21615)
MySQL Cluster: A partial rollback could lead to node restart failures. (Bug#21536)
MySQL Cluster: The failure of a unique index read due to an invalid schema version could be handled incorrectly in some cases, leading to unpredictable results. (Bug#21384)
MySQL Cluster: In a cluster with more than 2 replicas, a manual restart of one of the data nodes could fail and cause the other nodes in the same node group to shut down. (Bug#21213)
MySQL Cluster:
Some queries involving joins on very large
NDB tables could crash the MySQL server.
(Bug#21059)
MySQL Cluster: Restarting a data node while DDL operations were in progress on the cluster could cause other data nodes to fail. This could also lead to mysqld hanging or crashing under some circumstances. (Bug#21017, Bug#21050)
MySQL Cluster: In some situations with a high disk-load, writing of the redo log could hang, causing a crash with the error message GCP STOP detected. (Bug#20904)
MySQL Cluster:
When the redo buffer ran out of space, a Pointer too
large error was raised and the cluster could become
unusable until restarted with --initial.
(Bug#20892)
MySQL Cluster: A vague error message was returned when reading both schema files during a restart of the cluster. (Bug#20860)
MySQL Cluster:
Incorrect values were inserted into
AUTO_INCREMENT columns of tables restored
from a cluster backup.
(Bug#20820)
MySQL Cluster: When attempting to restart the cluster following a data import, the cluster failed during Phase 4 of the restart with Error 2334: Job buffer congestion. (Bug#20774)
MySQL Cluster:
REPLACE statements did not work correctly on
an NDB table having both a primary key and a
unique key. In such cases, proper values were not set for
columns which were not explicitly referenced in the statement.
(Bug#20728)
MySQL Cluster:
The server did not honor the value set for
ndb_cache_check_time in the
my.cnf file.
(Bug#20708)
MySQL Cluster: ndb_size.pl and ndb_error_reporter were missing from RPM packages. (Bug#20426)
MySQL Cluster:
Running ndbd
--nowait-nodes=
where id id was the node ID of a node
that was already running would fail with an invalid error
message.
(Bug#20419)
MySQL Cluster:
(Direct APIs): NdbScanOperation::readTuples()
and NdbIndexScanOperation::readTuples()
ignored the batch parameter.
(Bug#20252)
MySQL Cluster: A node failure during a scan could sometime cause the node to crash when restarting too quickly following the failure. (Bug#20197)
MySQL Cluster:
It was possible to use port numbers greater than 65535 for
ServerPort in the
config.ini file.
(Bug#19164)
MySQL Cluster: Under certain circumstances, a node that was shut down then restarted could hang during the restart. (Bug#18863)
MySQL Cluster: Trying to create or drop a table while a node was restarting caused the node to crash. This is now handled by raising an error. (Bug#18781)
MySQL Cluster: The server failed with a non-descriptive error message when out of data memory. (Bug#18475)
MySQL Cluster:
For NDB and possibly
InnoDB tables, a BEFORE
UPDATE trigger could insert incorrect values.
(Bug#18437)
MySQL Cluster:
SELECT ... FOR UPDATE failed to lock the
selected rows.
(Bug#18184)
MySQL Cluster:
perror did not properly report
NDB error codes.
(Bug#16561)
MySQL Cluster:
A Cluster whose storage nodes were installed from the
MySQL-ndb-storage- RPMs could not perform *
CREATE or
ALTER operations that made use of non-default
character sets or collations.
(Bug#14918)
MySQL Cluster:
The management client ALL STATUS command
could sometimes report the status of some data nodes
incorrectly.
(Bug#13985)
MySQL Cluster: An issue that arose from a patch for Bug#19852 made in MySQL 5.0.23 was corrected. (See Section E.1.6, “Changes in MySQL 5.0.23 (Not released)”.)
Cluster Replication:
In some cases, a large number of MySQL servers sending requests
to the cluster simultaneously could cause the cluster to crash.
This could also be triggered by many NDB API
clients making simultaneous event subscriptions or
unsubscriptions.
(Bug#20683)
Cluster API:
Invoking the MGM API function
ndb_mgm_listen_event() caused a memory leak.
(Bug#21671)
Cluster API:
The MGM API function ndb_logevent_get_fd()
was not implemented.
(Bug#21129)
Some Linux-x86_64-icc packages (of previous releases) mistakenly contained 32-bit binaries. Only ICC builds are affected, not gcc builds. Solaris and FreeBSD x86_64 builds are not affected. (Bug#22238)
Running SHOW MASTER LOGS at the same time as
binary log files were being switched would cause
mysqld to hang.
(Bug#21965)
libmysqlclient defined a symbol
BN_bin2bn which belongs to OpenSSL. This
could break applications that also linked against OpenSSL's
libcrypto library. The fix required
correcting an error in a build script that was failing to add
rename macros for some functions.
(Bug#21930)
character_set_results can be
NULL to signify “no conversion,”
but some code did not check for NULL,
resulting in a server crash.
(Bug#21913)
A NUL byte within a prepared statement string
caused the rest of the string not to be written to the query
log, allowing logging to be bypassed.
(Bug#21813)
COUNT(*) queries with
ORDER BY and LIMIT could
return the wrong result.
This problem was introduced by the fix for Bug#9676, which
limited the rows stored in a temporary table to the
LIMIT clause. This optimization is not
applicable to non-group queries with aggregate functions. The
current fix disables the optimization in such cases.
INSERT ... SELECT sometimes generated a
spurious Column count doesn't match value
count error.
(Bug#21774)
EXPORT_SET() did not accept
arguments with coercible character sets.
(Bug#21531)
mysqldump incorrectly tried to use
LOCK TABLES for tables in the
INFORMATION_SCHEMA database.
(Bug#21527)
Memory overruns could occur for certain kinds of subqueries. (Bug#21477)
A DATE can be represented as an integer (such
as 20060101) or as a string (such as
'2006.01.01'). When a DATE
(or TIME) column is compared in one
SELECT against both representations, constant
propagation by the optimizer led to comparison of
DATE as a string against
DATE as an integer. This could result in
integer comparisons such as 2006 against
20060101, erroneously producing a false
result.
(Bug#21475)
Adding ORDER BY to a SELECT
DISTINCT( query could
produce incorrect results.
(Bug#21456)expr)
Database and table names have a maximum length of 64 characters (even if they contain multi-byte characters), but were truncated to 64 bytes.
This fix was reverted in MySQL 5.0.26.
With max_sp_recursion set to 0, a stored
procedure that executed a SHOW CREATE
PROCEDURE statement for itself triggered a recursion
limit exceeded error, though the statement involves no
recursion.
(Bug#21416)
On 64-bit Windows, a missing table generated error 1017, not the correct value of 1146. (Bug#21396)
The optimizer sometimes produced an incorrect row-count estimate
after elimination of const tables. This
resulted in choosing extremely inefficient execution plans in
same cases when distribution of data in joins were skewed.
(Bug#21390)
A query result could be sorted improperly when using
ORDER BY for the second table in a join.
(Bug#21302)
Query results could be incorrect if the WHERE
clause contained t., where
key_part
NOT IN (val_list)val_list is a list of more than 1000
constants.
(Bug#21282)
For user-defined functions created with CREATE
FUNCTION, the DEFINER clause is not
legal, but no error was generated.
(Bug#21269)
The SELECT privilege was required for an
insert on a view, instead of the INSERT
privilege.
(Bug#21261)
This regression was introduced by Bug#20989
Subqueries on INFORMATION_SCHEMA tables could
erroneously return an empty result.
(Bug#21231)
mysql_upgrade created temporary files in a possibly insecure way. (Bug#21224)
When DROP DATABASE or SHOW OPEN
TABLES was issued while concurrently in another
connection issuing DROP TABLE,
RENAME TABLE, CREATE TABLE
LIKE or any other statement that required a name lock,
the server crashed.
(Bug#21216, Bug#19403)
The --master-data option for
mysqldump requires certain privileges, but
mysqldump generated a truncated dump file
without producing an appropriate error message or exit status if
the invoking user did not have those privileges.
(Bug#21215)
Some prepared statements caused a server crash when executed a second time. (Bug#21166)
The optimizer assumed that if (a=x AND b=x)
is true, (a=x AND b=x) AND a=b is also true.
But that is not always so if a and
b have different data types.
(Bug#21159)
SHOW INNODB STATUS contained some duplicate
output.
(Bug#21113)
InnoDB was slow with more than 100,000
.idb files.
(Bug#21112)
Performing an INSERT on a view that was
defined using a SELECT that specified a
collation and a column alias caused the server to crash .
(Bug#21086)
ALTER VIEW did not retain existing values of
attributes that had been originally specified but were not
changed in the ALTER VIEW statement.
(Bug#21080)
For InnoDB tables, the server could crash
when executing NOT IN(...) subqueries.
(Bug#21077)
The myisam_stats_method variable was
mishandled when set from an option file or on the command line.
(Bug#21054)
With query_cache_type set to 0,
RESET QUERY CACHE was very slow and other
threads were blocked during the operation. Now a cache reset is
faster and non-blocking.
(Bug#21051)
mysql crashed for very long arguments to the
connect command.
(Bug#21042)
A query using WHERE did not
return consistent results on successive invocations. The
column =
constant OR
column IS NULLcolumn in each part of the
WHERE clause could be either the same column,
or two different columns, for the effect to be observed.
(Bug#21019)
Performance during an import on a table with a trigger that called a stored procedure was severely degraded. This issue first arose in MySQL 5.0.18. (Bug#21013)
A query of the form shown here caused the server to crash:
SELECT * FROM t1 NATURAL JOIN (
t2 JOIN (
t3 NATURAL JOIN t4,
t5 NATURAL JOIN t6
)
ON (t3.id3 = t2.id3 AND t5.id5 = t2.id5)
);
STR_TO_DATE() sometimes would
return NULL if the %D
format specifier was not the last specifier in the format
string.
(Bug#20987)
A query using WHERE NOT
( yielded a
different result from the same query using the same
column < ANY
(subquery))column and
subquery with WHERE
(.
(Bug#20975)column > ANY
(subquery))
In debugging mode, mysqld printed
server_init rather than
network_init during network initialization.
(Bug#20968)
Under certain circumstances,
AVG(
returned a value but
key_val)MAX(
returned an empty set due to incorrect application of
key_val)MIN()/MAX() optimization.
(Bug#20954)
On Windows, mysql_upgrade.exe could not find mysqlcheck.exe. (Bug#20950)
Use of zero-length variable names caused a server crash. (Bug#20908)
The server crashed when using the range access method to execut
a subquery with a ORDER BY DESC clause.
(Bug#20869)
For certain queries, the server incorrectly resolved a reference to an aggregate function and crashed. (Bug#20868)
Using aggregate functions in subqueries yielded incorrect
results under certain circumstances due to incorrect application
of
MIN()/MAX()
optimization.
(Bug#20792)
If a column definition contained a character set declaration,
but a DEFAULT value began with an introducer,
the introducer character set was used as the column character
set.
(Bug#20695)
Multiplication of DECIMAL values could
produce incorrect fractional part and trailing garbage caused by
signed overflow.
(Bug#20569)
Users who had the SHOW VIEW privilege for a
view and privileges on one of the view's base tables could
not see records in INFORMATION_SCHEMA tables
relating to the base table.
(Bug#20543)
The MD5(),
SHA1(), and
ENCRYPT() functions should
return a binary string, but the result sometimes was converted
to the character set of the argument.
MAKE_SET() and
EXPORT_SET() now use the correct
character set for their default separators, resulting in
consistent result strings which can be coerced according to
normal character set rules.
(Bug#20536)
A subquery that contained LIMIT
could return more than
one row.
(Bug#20519)N,1
Creation of a view as a join of views or tables could fail if the views or tables are in different databases. (Bug#20482)
SELECT statements using GROUP
BY against a view could have missing columns in the
output when there was a trigger defined on one of the base
tables for the view.
(Bug#20466)
CREATE PROCEDURE, CREATE
FUNTION, CREATE TRIGGER, and
CREATE VIEW statements containing multi-line
comments (/* ... */) could not be replicated.
(Bug#20438)
For connections that required a SUBJECT
value, a check was performed to verify that the value was
correct, but the connection was not refused if not.
(Bug#20411)
Some user-level errors were being written to the server's error log, which is for server errors. (Bug#20402)
perror crashed on Solaris due to
NULL return value of
strerror() system call.
(Bug#20145)
For mysql, escaping with backslash sometimes did not work. (Bug#20103)
Use of MIN() or
MAX() with GROUP
BY on a ucs2 column could cause a
server crash.
(Bug#20076)
mysqld --flush failed to flush
MyISAM table changes to disk following an
UPDATE statement for which no updated column
had an index.
(Bug#20060)
A user-defined function that is called on each row of a returned
result set, could receive an in_null state
that is set, if it was set previously. Now, the
is_null state is reset to false before each
invocation of a UDF.
(Bug#19904)
The query command for
mysqltest did not work.
(Bug#19890)
When executing a SELECT with ORDER
BY on a view that is constructed from a
SELECT statement containing a stored
function, the stored function was evaluated too many times.
(Bug#19862)
The first time a user who had been granted the CREATE
ROUTINE privilege used that privilege to create a
stored function or procedure, the Password
column in that user's row in the mysql.user
table was set to NULL.
(Bug#19857)
For TIME_FORMAT(), the
%H and %k format
specifiers can return values larger than two digits (if the hour
is greater than 99), but for some query results that contained
three-character hours, column values were truncated.
(Bug#19844)
Using SELECT on a corrupt
MyISAM table using the dynamic record format
could cause a server crash.
(Bug#19835)
Using cursors with READ COMMITTED isolation
level could cause InnoDB to crash.
(Bug#19834)
The yaSSL library bundled with libmysqlclient
had some conflicts with OpenSSL. Now macros are used to rename
the conflicting symbols to have a prefix of
ya.
(Bug#19810)
On 64-bit systems, use of the cp1250
character set with a primary key column in a
LIKE clause caused a server crash for
patterns having letters in the range 128..255.
(Bug#19741)
DESCRIBE returned the type
BIGINT for a column of a view if the column
was specified by an expression over values of the type
INT.
(Bug#19714)
An issue with yaSSL prevented Connector/J clients from connecting to the server using a certificate. (Bug#19705)
A cast problem caused incorrect results for prepared statements that returned float values when MySQL was compiled with gcc 4.0. (Bug#19694)
The mysql_list_fields() C API
function returned the incorrect table name for views.
(Bug#19671)
If a query had a condition of the form
, which participated in equality propagation and also
was used for tableX.key
=
tableY.key
ref access, then early
ref-access NULL filtering
was not peformed for the condition. This could make query
execution slower.
(Bug#19649)
Repeated DROP TABLE statements in a stored
procedure could sometimes cause the server to crash.
(Bug#19399)
When not running in strict mode, the server failed to convert
the invalid years portion of a DATE or
DATETIME value to '0000'
when inserting it into a table.
This fix was reverted in MySQL 5.0.40.
See also Bug#25301
The final parenthesis of a CREATE INDEX
statement occurring in a stored procedure was omitted from the
binary log when the stored procedure was called.
(Bug#19207)
A SELECT with a subquery that was bound to
the outer query over multiple columns returned different results
when a constant was used instead of one of the dependant
columns.
(Bug#18925)
Setting myisam_repair_threads caused any
repair operation on a MyISAM table to fail to
update the cardinality of indexes, instead making them always
equal to 1.
(Bug#18874)
FEDERATED tables raised invalid duplicate key
errors when attempting on one server to insert rows having the
same primary key values as rows that had been deleted from the
linked table on the other server.
(Bug#18764)
The implementation for
UNCOMPRESS() did not indicate
that it could return NULL, causing the
optimizer to do the wrong thing.
(Bug#18539)
Using > ALL with subqueries that return no
rows yielded incorrect results under certain circumstances due
to incorrect application of
MIN()/MAX()
optimization.
(Bug#18503)
Referring to a stored function qualified with the name of one database and tables in another database caused a “table doesn't exist” error. (Bug#18444)
Triggers on tables in the mysql database
caused a server crash. Triggers for tables in this database now
are disallowed.
(Bug#18361, Bug#18005)
The length of the pattern string prefix for
LIKE operations was calculated incorrectly
for multi-byte character sets. As a result, the scanned range
was wider than necessary if the prefix contained any multi-byte
characters, and rows could be missing from the result set.
(Bug#18359, Bug#16674)
Multiple invocations of the
REVERSE() function could return
different results.
(Bug#18243)
The optimizer did not take advantage of indexes on columns used
for the second or third arguments of
BETWEEN.
(Bug#18165)
For table-format output, mysql did not always calculate columns widths correctly for columns containing multi-byte characters in the column name or contents. (Bug#17939)
The character set was not being properly initialized for
CAST() with a type like
CHAR(2) BINARY, which resulted in incorrect
results or even a server crash.
(Bug#17903)
Checking a MyISAM table (using CHECK
TABLE) having a spatial index and only one row would
wrongly indicate that the table was corrupted.
(Bug#17877)
A stored procedure that created and invoked a prepared statement was not executed when called in a mysqld init-file. (Bug#17843)
It is possible to create MERGE tables into
which data cannot be inserted (by not specifying a
UNION clause. However, when an insert was
attempted, the error message was confusing. Now an error occurs
indicating that the table is read-only.
(Bug#17766)
Attempting to insert a string of greater than 4096 bytes into a
FEDERATED table resulted in the error
ERROR 1296 (HY000) at line 2: Got error 10000 'Error
on remote system: 1054: Unknown column
'string-value' from
FEDERATED. This error was raised regardless of the
type of column involved (VARCHAR,
TEXT, and so on.)
(Bug#17608)
Views could not be updated within a stored function or trigger. (Bug#17591)
Use of the --prompt option or
prompt command caused
mysql to be unable to connect to the Instance
Manager.
(Bug#17485)
N'xxx' and _utf8'xxx' were
not treated as equivalent because N'xxx'
failed to unescape backslashes (\) and
doubled apostrophe/single quote characters
('').
(Bug#17313)
Use of the join cache in favor of an index for ORDER
BY operations could cause incorrect result sorting.
(Bug#17212)
The PASSWORD() function returned
invalid results when used in some UNION
queries.
(Bug#16881)
ORDER BY RAND() LIMIT 1 always set a user
variable to the last possible value from the table.
(Bug#16861)
When performing a
GROUP_CONCAT(), the server
transformed BLOB columns
VARCHAR columns, which could cause erroneous
results when using Connector/J and possibly other MySQL APIs.
(Bug#16712)
Stored procedures did not use the character set defined for the database in which they were created. (Bug#16676)
Some server errors were not reported to the client, causing both to try to read from the connection until a hang or crash resulted. (Bug#16581)
On Windows, a definition for
mysql_set_server_option() was
missing from the C client library.
(Bug#16513)
Updating a column of a FEDERATED table to
NULL sometimes failed.
(Bug#16494)
For SELECT ... FOR UPDATE statements that
used DISTINCT or GROUP BY
over all key parts of a unique index (or primary key), the
optimizer unnecessarily created a temporary table, thus losing
the linkage to the underlying unique index values. This caused a
Result set not updatable error. (The
temporary table is unnecessary because under these circumstances
the distinct or grouped columns must also be unique.)
(Bug#16458)
Using ANY with “non-table”
subqueries such as SELECT 1 yielded incorrect
results under certain circumstances due to incorrect application
of
MIN()/MAX()
optimization.
(Bug#16302)
A subquery in the WHERE clause of the outer
query and using IN and GROUP
BY returned an incorrect result.
(Bug#16255)
A query could produce different results with and without and
index, if the WHERE clause contained a range
condition that used an invalid DATETIME
constant.
(Bug#16249)
TIMESTAMPDIFF() examined only
the date and ignored the time when the requested difference unit
was months or quarters.
(Bug#16226)
Using tables from MySQL 4.x in MySQL 5.x, in particular those
with VARCHAR fields and using INSERT
DELAYED to update data in the table would result in
either data corruption or a server crash.
(Bug#16218, Bug#17294, Bug#16611)
The value returned by a stored function returning a string value was not of the declared character set. (Bug#16211)
The
index_merge/Intersection
optimizer could experience a memory overrun when the number of
table columns covered by an index was sufficiently large,
possibly resulting in a server crash.
(Bug#16201)
DECIMAL columns were handled incorrectly in
two respects :
When the precision of the column was too small for the value. In this case, the original value was returned instead of an error.
When the scale of the column was set to 0. In this case, the value. In this case, the value was treated as though the scale had been defined as 2.
Certain queries having a WHERE clause that
included conditions on multi-part keys with more than 2 key
parts could produce incorrect results and send [Note]
Use_count: Wrong count for key at... messages to
STDERR.
(Bug#16168)
When a row was inserted through a view but did not specify a value for a column that had no default value in the base table, no warning or error occurred. Now a warning occurs, or an error in strict SQL mode. (Bug#16110)
When NOW() was used in a
BETWEEN clause of the
definition for a view, it was replaced with a constant in the
view.
(Bug#15950)
The C API failed to return a status message when invoking a stored procedure. (Bug#15752)
mysqlimport sends a set
@@character_set_database=binary statement to the
server, but this is not understood by pre-4.1 servers. Now
mysqlimport encloses the statement within a
/*!40101 ... */ comment so that old servers
will ignore it.
(Bug#15690)
For the CSV storage engine, memory-mapped
pages of the data file were not invalidated when new data was
appended to the file via traditional (file descriptor-based) I/O
primitives.
(Bug#15669)
SHOW GRANTS FOR CURRENT_USER did not return
definer grants when executed in DEFINER
context (such as within a stored prodedure defined with
SQL SECURITY DEFINER), it returned the
invoker grants.
(Bug#15298)
The --collation-server server option was being
ignored. With the fix for this problem, if you choose a
non-default character set with
--character-set-server, you should also use
--collation-server to specify the collation.
(Bug#15276)
The server crashed if it tried to access a
CSV table for which the data file had been
removed.
(Bug#15205)
Tables created with the FEDERATED storage
engine did not permit indexes using NULL
columns.
(Bug#15133)
When using tables containing VARCHAR columns
created under MySQL 4.1 with a 5.0 or later server, for some
queries the metadata sent to the client could have an empty
column name.
(Bug#14897)
CREATE TABLE ... SELECT statements that
selected GEOMETRY values resulted in a table
that contained BLOB columns, not
GEOMETRY columns.
(Bug#14807)
When setting a column to its implicit default value as the
result of inserting a NULL into a
NOT NULL column as part of a multi-row insert
or LOAD DATA operation, the server returned a
misleading warning message.
(Bug#14770)
The use of WHERE in col_name IS
NULLSELECT statements reset the
value of LAST_INSERT_ID() to
zero.
(Bug#14553)
Inserts into BIT columns of
FEDERATED tables did not work.
(Bug#14532)
Using SELECT and a table join while running a
concurrent INSERT operation would join
incorrect rows.
(Bug#14400)
Prepared statements caused general log and server memory corruption. (Bug#14346)
libmysqld produced some warnings to
stderr which could not be silenced. These
warnings now are suppressed.
(Bug#13717)
The Instance Manager allowed STOP INSTANCE to
be used on a server instance that was not running.
(Bug#12673)
For very complex SELECT statements could
create temporary tables that were too large, and for which the
temporary files were not removed, causing subsequent queries to
fail.
(Bug#11824)
USE did not refresh database privileges when
employed to re-select the current database.
(Bug#10979)
The type of the value returned by the
VARIANCE() function varied
according to the type of the input value. The function should
always return a DOUBLE value.
(Bug#10966)
The same trigger error message was produced under two conditions: The trigger duplicated an existing trigger name, or the trigger duplicated an existing combination of action and event. Now different messages are produced for the two conditions so as to be more informative. (Bug#10946)
CREATE USER did not respect the 16-character
username limit.
(Bug#10668)
A server or network failure with an open client connection would cause the client to hang even though the server was no longer available.
As a result of this change, the
MYSQL_OPT_READ_TIMEOUT and
MYSQL_OPT_WRITE_TIMEOUT options for
mysql_options() now apply to
TCP/IP connections on all platforms. Previously, they applied
only to Windows.
(Bug#9678)
INSERT INTO ... SELECT ... LIMIT 1 could be
slow because the LIMIT was ignored when
selecting candidate rows.
(Bug#9676)
The optimizer could produce an incorrect result after
AND with collations such as
latin1_german2_ci,
utf8_czech_ci, and
utf8_lithianian_ci.
(Bug#9509)
A stored procedure with a CONTINUE handler
that encountered an error continued to execute a statement that
caused an error, rather with the next statement following the
one that caused the error.
(Bug#8153)
For ODBC compatibility, MySQL supports use of WHERE
for
col_name IS NULLDATE or DATETIME columns
that are NOT NULL, to allow column values of
'0000-00-00' or '0000-00-00
00:00:00' to be selected. However, this was not
working for WHERE clauses in
DELETE statements.
(Bug#8143)
A user variable set to a value selected from an unsigned column was stored as a signed value. (Bug#7498)
The --with-collation option was not honored for
client connections.
(Bug#7192)
When the precision of the column was too small for the value. In this case, the original value was returned instead of an error.
When the scale of the column was set to 0. In this case, the value. In this case, the value was treated as though the scale had been defined as 2.
This is a bugfix release for the current production release family. It replaces MySQL 5.0.24.
Bugs fixed:
The shared compatibility RPM files were missing some files. (Bug#22251)
mysqld could crash when closing temporary tables. (Bug#21582)
MySQL 5.0.24 introduced an ABI incompatibility, which this release reverts. Programs compiled against 5.0.24 are not compatible with any other version and must be recompiled. (Bug#21543)
Pathname separator and device characters were not correctly parameterized for NetWare, causing mysqld startup errors. (Bug#21537)
Closing of temporary tables failed if binary logging was not enabled. (Bug#20919)
For statements that have a DEFINER clause
such as CREATE TRIGGER or CREATE
VIEW, long usernames or hostnames could cause a buffer
overflow.
(Bug#16899)
This is a bugfix release for the current production release family.
This section documents all changes and bug fixes that have been applied since the last official MySQL release. If you would like to receive more fine-grained and personalized update alerts about fixes that are relevant to the version and features you use, please consider subscribing to MySQL Enterprise (a commercial MySQL offering). For more details please see http://www.mysql.com/products/enterprise.
Functionality added or changed:
In the INFORMATION_SCHEMA.ROUTINES table the
ROUTINE_DEFINITION column now is defined as
NULL rather than NOT NULL.
Also, NULL rather than the empty string is
returned as the column value if the user does not have
sufficient privileges to see the routine definition.
(Bug#20230)
The LEFT() and
RIGHT() functions return
NULL if any argument is
NULL.
(Bug#11728)
The innodb_log_arch_dir system variable
(which has been unused since MySQL 4.0.6) is now deprecated and
should no longer be used. It will be removed in MySQL 5.1.
Program Database files (extension pdf) are
now included by default in Windows distributions. These can be
used to help diagnose problems with mysqld
and other tools. See Section 27.4.1, “Debugging a MySQL Server”.
Bugs fixed:
Security Fix:
If a user has access to MyISAM table
t, that user can create a
MERGE table m that
accesses t. However, if the user's
privileges on t are subsequently
revoked, the user can continue to access
t by doing so through
m. If this behavior is undesirable,
you can start the server with the new
--skip-merge option to disable the
MERGE storage engine.
(Bug#15195, CVE-2006-4031)
MySQL Cluster:
The ndb_size.pl script did not account for
TEXT and BLOB column
values correctly.
(Bug#21204)
MySQL Cluster:
The repeated creating and dropping of a table would eventually
lead to NDB Error 826, Too many
tables and attributes ... Insufficient space.
(Bug#20847)
Under heavy load (executing more than 1024 simultaneous complex queries), a problem in the code that handles internal temporary tables could lead to writing beyond allocated space and memory corruption.
Use of more than 1024 simultaneous cursors server wide also could lead to memory corruption. This applies to both stored procedure cursors and C API cursors. (Bug#21206)
Failure to account for a NULL table pointer
on big-endian machines could cause a server crash during type
conversion.
(Bug#21135)
mysqldump sometimes did not select the correct database before trying to dump views from it, resulting in an empty result set that caused mysqldump to die with a segmentation fault. (Bug#21014)
A SELECT that used a subquery in the
FROM clause that did not select from a table
failed when the subquery was used in a join.
(Bug#21002)
REPLACE ... SELECT for a view required the
INSERT privilege for tables other than the
table being modified.
(Bug#20989)
A race condition during slave server shutdown caused an assert failure. (Bug#20850)
Issuing a SHOW CREATE FUNCTION or
SHOW CREATE PROCEDURE statement without
sufficient privileges could crash the mysql
client.
(Bug#20664)
In a view defined with SQL SECURITY DEFINER,
the CURRENT_USER() function
returned the invoker, not the definer.
(Bug#20570)
With the auto_increment_increment system
variable set larger than 1, if the next generated
AUTO_INCREMENT value would be larger than the
column's maximum value, the value would be clipped down to that
maximum value and inserted, even if the resulting value would
not be in the generated sequence. This could cause problems for
master-master replication. Now the server clips the value down
to the previous value in the sequence, which correctly produces
a duplicate-key error if that value already exists in the
column.
(Bug#20524)
SELECT @@INSERT_ID displayed a value
unrelated to a preceding SET INSERT_ID. (It
was returning LAST_INSERT_ID instead.)
(Bug#20392)
The mysql client did not understand
help commands that had spaces at the end.
(Bug#20328)
mysqldump produced a malformed dump file when dumping multiple databases that contained views. (Bug#20221)
If a table on a slave server had a higher
AUTO_INCREMENT counter than the corresponding
master table (even though all rows of the two tables were
identical), in some cases REPLACE or
INSERT ... ON DUPLICATE KEY UPDATE would not
replicate properly using statement-based logging. (Different
values would be inserted on the master and slave.)
(Bug#20188)
For a DATE parameter sent via a
MYSQL_TIME data structure,
mysql_stmt_execute() zeroed the
hour, minute, and second members of the structure rather than
treating them as read-only.
(Bug#20152)
Performing INSERT ... SELECT ... JOIN ...
USING without qualifying the column names caused
ERROR 1052 "column 'x' in field list is
ambiguous" even in cases where the column
references were unambiguous.
(Bug#18080)
Using the extended syntax for
TRIM() — that is,
TRIM(... FROM ...) — in a
SELECT statement defining a view caused an
invalid syntax error when selecting from the view.
(Bug#17526)
Assignments of values to variables of type
TEXT were handled incorrectly in stored
routines.
(Bug#17225)
DATE_ADD() and
DATE_SUB() returned
NULL when the result date was on the day
'9999-12-31'.
(Bug#12356)
The DATA DIRECTORY table option did not work
for TEMPORARY tables.
(Bug#8706)
Bug#10952 may cause inadvertent data loss. A fix for this bug was included in MySQL 5.0.23, but the approach used caused a loss of intended functionality. Because of this, that fix has been reverted in MySQL 5.0.24. As a consequence, the risk of inadvertent data loss still exists (see Bug#10952).
MySQL 5.0.23 was never officially released.
This section documents all changes and bug fixes that have been applied since the last official MySQL release. If you would like to receive more fine-grained and personalized update alerts about fixes that are relevant to the version and features you use, please consider subscribing to MySQL Enterprise (a commercial MySQL offering). For more details please see http://www.mysql.com/products/enterprise.
Functionality added or changed:
Important Change: MySQL Cluster:
The status variables Ndb_connected_host and
Ndb_connected_port were renamed to
Ndb_config_from_host and
Ndb_config_from_port, respectively.
MySQL Cluster:
The limit of 2048 ordered indexes per cluster has been lifted.
There is now no upper limit on the number of ordered indexes
(including AUTO_INCREMENT columns) that may
be used.
(Bug#14509)
The mysqldumpslow script has been moved from client RPM packages to server RPM packages. This corrects a problem where mysqldumpslow could not be used with a client-only RPM install, because it depends on my_print_defaults which is in the server RPM. (Bug#20216)
Added the log_queries_not_using_indexes
system variable.
(Bug#19616)
Added the ssl_ca,
ssl_capath, ssl_cert,
ssl_cipher, and ssl_key
system variables, which display the values given via the
corresponding command options. See
Section 5.5.7.3, “SSL Command Options”.
(Bug#19606)
SQL syntax for prepared statements now supports ANALYZE
TABLE, OPTIMIZE TABLE, and
REPAIR TABLE.
(Bug#19308)
For a table with an AUTO_INCREMENT column,
SHOW CREATE TABLE now shows the next
AUTO_INCREMENT value to be generated.
(Bug#19025)
The ONLY_FULL_GROUP_BY SQL mode now also
applies to the HAVING clause. That is,
columns not named in the GROUP BY clause
cannot be used in the HAVING clause if not
used in an aggregate function.
(Bug#18739)
Added the --set-charset option to
mysqlbinlog to allow the character set to be
specified for processing binary log files.
(Bug#18351)
The bundled yaSSL library was upgraded to version 1.3.5. This improves handling of certain problems with SSL-related command options. (Bug#17737)
Added the --ssl-verify-server-cert option to
MySQL client programs. This option causes the server's Common
Name value in its certificate to be verified against the
hostname used when connecting to the server, and the connection
is rejected if there is a mismatch. Added
MYSQL_OPT_SSL_VERIFY_SERVER_CERT option for
the mysql_options() C API
function to enable this verification. This feature can be used
to prevent man-in-the-middle attacks. Verification is disabled
by default.
(Bug#17208)
It is now possible to use
NEW.
values within triggers as var_nameINOUT parameters to
stored procedures.
(Bug#14635)
Added the --angel-pid-file option to
mysqlmanager for specifying the file in which
the angel process records its process ID when
mysqlmanager runs in daemon mode.
(Bug#14106)
The mysql_get_ssl_cipher() C
API function was added.
The mysql_upgrade command has been converted from a shell script to a C program, so it is available on non-Unix systems such as Windows. This program should be run for each MySQL upgrade. See Section 4.4.9, “mysql_upgrade — Check Tables for MySQL Upgrade”.
Binary distributions that include SSL support now are built using yaSSL when possible.
Bugs fixed:
Security Fix:
A NUL byte within a comment in a statement
string caused the rest of the string not to be written to the
query log, allowing logging to be bypassed.
(Bug#17667, CVE-2006-0903)
MySQL Cluster:
The ndb_mgm client command ALL
CLUSTERLOG STATISTICS=15 had no effect.
(Bug#20336)
MySQL Cluster:
The failure of a data node when preparing to commit a
transaction (that is, while the node's status was
CS_PREPARE_TO_COMMIT) could cause the failure
of other cluster data nodes.
(Bug#20185)
MySQL Cluster: An internal formatting error caused some management client error messages to be unreadable. (Bug#20016)
MySQL Cluster: Renaming a table in such a way as to move it to a different database failed to move the table's indexes. (Bug#19967)
MySQL Cluster: Running management client commands while mgmd was in the process of disconnecting could cause the management server to fail. (Bug#19932)
MySQL Cluster:
Running ALL START in the
NDB management client or restarting multiple
nodes simultaneously could under some circumstances cause the
cluster to crash.
(Bug#19930)
MySQL Cluster:
TEXT columns in Cluster tables having both an
explicit primary key and a unique key were not correctly updated
by REPLACE statements.
(Bug#19906)
MySQL Cluster:
The cluster's data nodes failed while trying to load data when
NoOfFrangmentLogFiles was set equal to 1.
(Bug#19894)
MySQL Cluster:
Restoring a backup with ndb_restore failed
when the backup had been taken from a cluster whose
DataMemory had been completely used up.
(Bug#19852)
MySQL Cluster:
Resources for unique indexes on Cluster table columns were
incorrectly allocated, so that only one-fourth as many unique
indexes as indicated by the value of
UniqueHashIndexes could be created.
(Bug#19623)
MySQL Cluster:
(NDBAPI): On big-endian platforms,
NdbOperation::write_attr() did not update
32-bit fields correctly.
(Bug#19537)
MySQL Cluster:
LOAD DATA LOCAL failed to ignore duplicate
keys in Cluster tables.
(Bug#19496)
MySQL Cluster: For ndb_mgmd, Valgrind revealed problems with a memory leak and a dependency on an uninitialized variable. (Bug#19318, Bug#20333)
MySQL Cluster:
A problem with error handling when
ndb_use_exact_count was enabled could lead to
incorrect values returned from queries using
COUNT(). A warning is now
returned in such cases.
(Bug#19202)
MySQL Cluster:
TRUNCATE failed on tables having
BLOB or TEXT columns with
the error Lock wait timeout exceeded.
(Bug#19201)
MySQL Cluster:
mysql-test-run.pl started
NDB even for test cases that did not need it.
(Bug#19083)
MySQL Cluster: Stopping multiple nodes could cause node failure handling not to be completed. (Bug#19039)
MySQL Cluster:
The management client ALL STOP command shut
down mgmd processes (as well as
ndbd processes).
(Bug#18966)
MySQL Cluster:
TRUNCATE TABLE failed to reset the
AUTO_INCREMENT counter.
(Bug#18864)
MySQL Cluster:
Repeated CREATE - INSERT -
DROP operations tables could in some
circumstances cause the MySQL table definition cache to become
corrupt, so that some mysqld processes could
access table information but others could not.
(Bug#18595)
MySQL Cluster:
Repeated use of the SHOW and ALL
STATUS commands in the ndb_mgm
client could cause the mgmd process to crash.
(Bug#18591)
MySQL Cluster: ndbd sometimes failed to start with the error Node failure handling not completed following a graceful restart. (Bug#18550)
MySQL Cluster:
Backups could fail for large clusters with many tables, where
the number of tables approached
MaxNoOfTables.
(Bug#17607)
MySQL Cluster:
An issue with ndb_mgmd prevented more than 27
mysqld processes from connecting to a single
cluster at one time.
(Bug#17150)
MySQL Cluster:
Using “stale” mysqld
.FRM files could cause a newly-restored
cluster to fail. This situation could arise when restarting a
MySQL Cluster using the --intial option while
leaving connected mysqld processes running.
(Bug#16875)
MySQL Cluster: Data node failures could cause excessive CPU usage by ndb_mgmd. (Bug#13987)
MySQL Cluster: Cluster system status variables were not updated properly. (Bug#11459)
MySQL Cluster:
Some queries having a WHERE clause of the
form c1=val1 OR c2 LIKE 'val2' were not
evaluated correctly. (Bug # 17421)
MySQL Cluster: (NDBAPI): Update operations on blobs were not checked for illegal operations.
Read locks with blob update operations are now upgraded from read committed to read shared.
A buffer overwrite error in Instance Manager caused a crash. (Bug#20622)
On Windows, temporary tables containing “
: ” in the name could not be created.
(Bug#20616)
The fill_help_tables.sql file did not
contain a SET NAMES 'utf8' statement to
indicate its encoding. This caused problems for some settings of
the MySQL character set such as big5.
(Bug#20551)
The fill_help_tables.sql file did not load
properly if the ANSI_QUOTES SQL mode was
enabled.
(Bug#20542)
mysql_upgrade was missing from binary MySQL distributions. (Bug#20403, Bug#18516, Bug#20556)
Several aspects of view privileges were being checked incorrectly. (Bug#20363, Bug#18681)
Queries using an indexed column as the argument for the
MIN() and
MAX() functions following an
ALTER TABLE .. DISABLE KEYS statement
returned Got error 124 from storage
engine until ALTER TABLE ... ENABLE
KEYS was run on the table.
(Bug#20357)
The thread for INSERT DELAYED rows was
maintaining a separate AUTO_INCREMENT
counter, resulting in incorrect values being assigned if
DELAYED and non-DELAYED
inserts were mixed.
(Bug#20195)
On Linux, libmysqlclient when compiled with
yaSSL using the icc compiler had a spurious
dependency on C++ libraries.
(Bug#20119)
A number of dependency issues in the RPM
bench and test packages
caused installation of these packages to fail.
(Bug#20078)
A compatibility issue with NPTL (Native POSIX Thread Library) on
Linux could result in a deadlock with FLUSH TABLES WITH
READ LOCK under some conditions.
(Bug#20048)
Some outer joins were incorrectly converted to inner joins. (Bug#19816)
This regression was introduced by Bug#17146
CREATE DATABASE, RENAME
DATABASE, and DROP DATABASE could
deadlock in cases where there was a global read lock.
(Bug#19815)
The WITH CHECK OPTION was not enforced when a
REPLACE statement was executed against a
view.
(Bug#19789)
Multiple-table updates with FEDERATED tables
could cause a server crash.
(Bug#19773)
InnoDB unlocked its data directory before
committing a transaction, potentially resulting in
non-recoverable tables if a server crash occurred before the
commit.
(Bug#19727)
Subqueries that produced a BIGINT UNSIGNED
value were being treated as returning a signed value.
(Bug#19700)
GROUP BY on an expression that contained a
cast to DECIMAL produced an incorrect result.
(Bug#19667)
MERGE tables did not work reliably with
BIT columns.
(Bug#19648)
Re-execution of a prepared multiple-table
DELETE statement that involves a trigger or
stored function can result in a server crash.
(Bug#19634)
The range operator failed and caused a server crash for clauses
of the form
.
(Bug#19618)tbl_name.unsigned_keypart
NOT IN (negative_const,
...)
CHECK TABLE on a MyISAM
table briefly cleared its AUTO_INCREMENT
value, while holding only a read lock. Concurrent inserts to
that table could use the wrong AUTO_INCREMENT
value. CHECK TABLE no longer modifies the
AUTO_INCREMENT value.
(Bug#19604)
Using
CONCAT(@, where
user_var,
col_name)col_name is a column in an
INFORMATION_SCHEMA table, could cause
erroneous duplication of data in the query result.
(Bug#19599)
Some yaSSL public function names conflicted with those from
OpenSSL, causing conflicts for applications that linked against
both OpenSSL and a version of libmysqlclient
that was built with yaSSL support. The yaSSL public functions
now are renamed to avoid this conflict.
(Bug#19575)
A view definition that referred to an alias in the
HAVING clause could be saved in the
.frm file with the alias replaced by the
expression that it referred to, causing failure of subsequent
SELECT * FROM statements.
(Bug#19573)view_name
mysql displayed NULL for
strings that are empty or contain only spaces.
(Bug#19564)
InnoDB failed to increment the
handler_read_prev counter.
(Bug#19542)
Selecting from a view that used GROUP BY on a
non-constant temporal interval (such as
DATE(
could cause a server crash.
(Bug#19490)col) + INTERVAL
TIME_TO_SEC(col) SECOND
mysqldump did not dump the table name
correctly for some table identifiers that contained unusual
characters such as “ : ”.
(Bug#19479)
On 64-bit Windows systems, REGEXP for regular
expressions with exactly 31 characters did not work.
(Bug#19407)
An outer join of two views that was written using { OJ
... } syntax could cause a server crash.
(Bug#19396)
Race conditions on certain platforms could cause the Instance Manager to fail to initialize. (Bug#19391)
Use of the --no-pager option caused
mysql to crash.
(Bug#19363)
In the INFORMATION_SCHEMA.COLUMNS table, the
values for the CHARACTER_MAXIMUM_LENGTH and
CHARACTER_OCTET_LENGTH columns were incorrect
for multi-byte character sets.
(Bug#19236)
Multiple-table DELETE statements containing a
subquery that selected from one of the tables being modified
caused a server crash.
(Bug#19225)
On Windows, removal of binary log files would fail if the files were already open. (Bug#19208)
Flushing the compression buffer (via FLUSH
TABLE) no longer increases the size of an unmodified
ARCHIVE table.
(Bug#19204)
An ALTER TABLE operation that does not need
to copy data, when executed on a table created prior to MySQL
4.0.25, could result in a server crash for subsequent accesses
to the table.
(Bug#19192)
SSL connections using yaSSL on OpenBSD could fail. (Bug#19191)
Attempting to set the default value of an
ENUM or SET column to
NULL caused a server crash.
(Bug#19145)
Use of uninitialized user variables in a subquery in the
FROM clause resulted in invalid entries in
the binary log.
(Bug#19136)
A CREATE TABLE statement that created a table
from a materialized view did not inherit default values from the
underlying table.
(Bug#19089)
Index prefixes for utf8
VARCHAR columns did not work for
UPDATE statements.
(Bug#19080)
Premature optimization of nested subqueries in the
FROM clause that refer to aggregate functions
could lead to incorrect results.
(Bug#19077)
Valgrind revealed several issues with mysqld
that were corrected: A dangling stack pointer being overwritten;
possible uninitialized data in a string comparison; memory
corruption in replication slaves when switching databases;
syscall() write parameter pointing to an
uninitialized byte.
(Bug#19022, Bug#20579, Bug#20769, Bug#20783, Bug#20791)
The parser leaked memory when its stack needed to be extended. (Bug#18930)
BIT columns in a table could cause joins that
use the table to fail.
(Bug#18895)
The MySQL server startup script /etc/init.d/mysql (created from mysql.server) is now marked to ensure that the system services ypbind, nscd, ldap, and NTP are started first (if these are configured on the machine). (Bug#18810)
The COM_STATISTICS command was changed in
5.0.3 to display session status variable values rather than
global values. This causes mysqladmin status
information not to be useful for the Slow
queries and Opens values. Now
COM_STATISTICS displays the global values for
Slow queries and Opens.
(Bug#18669)
LOAD DATA FROM MASTER would fail when trying
to load the INFORMATION_SCHEMA database from
the master, because the INFORMATION_SCHEMA
system database would already exist on the slave.
(Bug#18607)
BLOB or TEXT arguments to
or values returned from stored functions were not copied
properly if too long and could become garbled.
(Bug#18587)
The IN-to-EXISTS
transformation was making a reference to a parse tree fragment
that was left out of the parse tree. This caused problems with
prepared statements.
(Bug#18492)
mysqldump produced garbled output for view definitions. (Bug#18462)
The configuration information for building the embedded server on Windows was missing a file. (Bug#18455)
In mysqltest, --sleep=0 had
no effect. Now it correctly causes sleep
commands in test case files to sleep for 0 seconds.
(Bug#18312)
INFORMATION_SCHEMA.TABLES provided
inconsistent info about invalid views. This could cause server
crashes or result in incorrect data being returned for queries
that attempt to obtain information from
INFORMATION_SCHEMA tables about views using
stored functions.
(Bug#18282)
On Windows, corrected a crash stemming from differences in Visual C runtime library routines from POSIX behavior regarding invalid file descriptors. (Bug#18275)
On Windows, terminating mysqld with Control-C could result in a crash during shutdown. (Bug#18235)
Selecting data from a MEMORY table with a
VARCHAR column and a HASH
index over it returned only the first row matched.
(Bug#18233)
The use of MIN() and
MAX() on columns with an index
prefix produced incorrect results in some queries.
(Bug#18206)
An entry in the mysql.proc table with an
empty routine name caused access to the
INFORMATION_SCHEMA.ROUTINES table to crash
the server.
(Bug#18177)
A UNION over more than 128
SELECT statements that use an aggregate
function failed.
(Bug#18175)
Updates to a MEMORY table caused the size of
BTREE indexes for the table to increase.
(Bug#18160)
SELECT DISTINCT queries sometimes returned
only the last row.
(Bug#18068)
Returning the value of a system variable from a stored function caused a server crash. (Bug#18037)
An update that used a join of a table to itself and modified the table on both sides of the join reported the table as crashed. (Bug#18036)
Race conditions on certain platforms could cause the Instance Manager to try to restart the same instance multiple times. (Bug#18023)
For a reference to a non-existent index in FORCE
INDEX, the error message referred to a column, not an
index.
(Bug#17873)
The sql_big_selects system variable was not
displayed by SHOW VARIABLES.
(Bug#17849)
REPAIR TABLE did not restore the length for
packed keys in tables created under MySQL 4.x, which caused them
to appear corrupt to CHECK TABLE but not to
REPAIR TABLE.
(Bug#17810)
Results from INFORMATION_SCHEMA.SCHEMATA
could contain uppercase information when
lower_case_table_names was not 0.
(Bug#17661)
CREATE TABLE ... SELECT did not always
produce the proper column default value in
TRADITIONAL SQL mode.
(Bug#17626)
A range access optimizer heuristic was invalid, causing some queries to be much slower in MySQL 5.0 than in 4.0. (Bug#17379, Bug#18940)
mysqldump would not dump views that had
become invalid because a table named in the view definition had
been dropped. Instead, it quit with an error message. Now you
can specify the --force option to cause
mysqldump to keep going and write a SQL
comment containing the view definition to the dump output.
(Bug#17371)
The --core-file-size option for
mysqld_safe was effective only for
root.
(Bug#17353)
On Windows, multiple clients simultaneously attempting to
perform ALTER TABLE operations on an
InnoDB table could deadlock.
(Bug#17264)
The binary log would create an incorrect DROP
query when creating temporary tables during replication.
(Bug#17263)
Revised memory allocation for local objects within stored functions and triggers to avoid memory leak for repeated function or trigger invocation. (Bug#17260)
Multiple calls to a stored procedure that selects from
INFORMATION_SCHEMA could cause a server
crash.
(Bug#17204)
Views created from prepared statements inside of stored
procedures were created with a definition that included both
SQL_CACHE and
SQL_NO_CACHE.
(Bug#17203)
mysqldump wrote an extra pair of
DROP DATABASE and CREATE
DATABASE statements if run with the
--add-drop-database option and the database
contained views.
(Bug#17201)
A Table ... doesn't exist error could occur for statements that called a function defined in another database. (Bug#17199)
For certain CREATE TABLE ... SELECT
statements, the selected values were truncated when inserted
into the new table.
(Bug#17048)
ALTER TABLE on a table created prior to 5.0.3
would cause table corruption if the ALTER
TABLE did one of the following:
Change the default value of a column.
Change the table comment.
Change the table password.
MyISAM table deadlock was possible if one
thread issued a LOCK TABLES request for write
locks and then an administrative statement such as
OPTIMIZE TABLE, if between the two statements
another client meanwhile issued a multiple-table
SELECT for some of the locked tables.
(Bug#16986)
Symlinking .mysql_history to
/dev/null to suppress statement history
saving by mysql did not work.
(mysql deleted the symlink and recreated
.mysql_history as a regular file, and then
wrote history to it.)
(Bug#16803)
Concatenating the results of multiple constant subselects produced incorrect results. (Bug#16716)
Privilege checking on the contents of the
INFORMATION_SCHEMA.VIEWS table was
insufficiently restrictive.
(Bug#16681)
mysqlcheck tried to check views instead of ignoring them. (Bug#16502)
IS_USED_LOCK() could return an
incorrect connection identifier.
(Bug#16501)
Concurrent reading and writing of privilege structures could crash the server. (Bug#16372)
Grant table modifications sometimes did not refresh the
in-memory tables if the hostname was '' or
not specified.
(Bug#16297)
The sql_notes and
sql_warnings system variables were not always
displayed correctly by SHOW VARIABLES (for
example, they were displayed as ON after
being set to OFF).
(Bug#16195)
The max_length metadata value for columns
created from CONCAT() could be
incorrect when the collation of an argument differed from the
collation of the CONCAT()
itself. In some contexts such as UNION, this
could lead to truncation of the column contents.
(Bug#15962)
The server no longer uses a signal handler for signal 0 because it could cause a crash on some platforms. (Bug#15869)
InnoDB does not support
SPATIAL indexes, but did not prevent creation
of such an index.
(Bug#15860)
Long multiple-row INSERT statements could
take a very long time for some multi-byte character sets.
(Bug#15811)
The system_time_zone and
version_* system variables could not be
accessed via SELECT
@@ syntax.
(Bug#15684, Bug#12792)var_name
EXPLAIN ... SELECT INTO caused the client to
hang.
(Bug#15463)
Nested natural joins worked executed correctly when executed as
a non-prepared statement could fail with an Unknown
column ' error when executed as a prepared statement, due
to a name resolution problem.
(Bug#15355)col_name' in 'field
list'
The MD5() and SHA()
functions treat their arguments as case-sensitive strings. But
when they are compared, their arguments were compared as
case-insensitive strings, which leads to two function calls with
different arguments (and thus different results) compared as
being identical. This can lead to a wrong decision made in the
range optimizer and thus to an incorrect result set.
(Bug#15351)
Invalid escape sequences in option files caused MySQL programs that read them to abort. (Bug#15328)
Re-executing a stored procedure with a complex stored procedure cursor query could lead to a server crash. (Bug#15217)
CREATE TABLE ... SELECT ... statements that
used a stored function explicitly or implicitly (through a view)
resulted in a Table not locked error.
(Bug#15137, Bug#12472)
An invalid comparison between keys with index prefixes over
multi-byte character fields could lead to incorrect result sets
if the selected query execution plan used a range scan by an
index prefix over a UTF8 character field.
This also caused incorrect results under similar circumstances
with many other character sets.
(Bug#14896)
A view with a non-existent account in the
DEFINER clause caused SHOW CREATE
VIEW to fail. Now SHOW CREATE VIEW
issues a warning instead.
(Bug#14875)
For BOOLEAN mode full-text searches on
non-indexed columns, NULL rows generated by a
LEFT JOIN caused incorrect query results.
(Bug#14708, Bug#25637)
SHOW CREATE TABLE did not display the
AUTO_INCREMENT column attribute if the SQL
mode was MYSQL323 or
MYSQL40. This also affected
mysqldump, which uses SHOW CREATE
TABLE to get table definitions.
(Bug#14515)
Some queries were slower in 5.0 than in 4.1 because some 4.1 cost-evaluation code had not been merged into 5.0. (Bug#14292)
The binary log lacked character set information for table names when dropping temporary tables. (Bug#14157)
The result from CONV() is a
string, but was not always treated the same way as a string when
converted to a real value for an arithmetic operation.
(Bug#13975)
RPM packages had spurious dependencies on Perl modules and other programs. (Bug#13634)
REPLACE statements caused activation of
UPDATE triggers, not
DELETE and INSERT
triggers.
(Bug#13479)
With settings of read_buffer_size >= 2G
and read_rnd_buffer_size >=2G,
LOAD DATA INFILE failed with no error message
or caused a server crash for files larger than 2GB.
(Bug#12982)
A B-TREE index on a MEMORY
table erroneously reported duplicate entry error for multiple
NULL values.
(Bug#12873)
Use of CONVERT_TZ() in a stored
function or trigger (or in a stored procedure called from a
stored function or trigger) caused an error.
(Bug#11081)
LOAD_FILE() returned an error if
the file did not exist, rather than NULL as
it should according to the manual.
(Bug#10418)
When myisamchk needed to rebuild a table,
AUTO_INCREMENT information was lost.
(Bug#10405)
For certain CREATE VIEW statements, the
server did not detect invalid subqueries within the
SELECT part.
(Bug#7549)
Within a trigger, SET used the SQL mode of
the invoking statement, not the mode in effect at trigger
creation time.
(Bug#6951)
An invalid GRANT statement for which
Ok was returned on a replication master
caused an error on the slave and replication to fail.
(Bug#6774)
Some queries that used ORDER BY and
LIMIT performed quickly in MySQL 3.23, but
slowly in MySQL 4.x/5.x due to an optimizer problem.
(Bug#4981)
The basedir and tmpdir
system variables could not be accessed via
@@ syntax.
(Bug#1039)var_name
This is a security fix release for the previous production release family.
This section documents all changes and bug fixes that have been applied since the last official MySQL release. If you would like to receive more fine-grained and personalized update alerts about fixes that are relevant to the version and features you use, please consider subscribing to MySQL Enterprise (a commercial MySQL offering). For more details please see http://www.mysql.com/products/enterprise.
Bugs fixed:
Security Fix:
An SQL-injection security hole has been found in multi-byte
encoding processing. The bug was in the server, incorrectly
parsing the string escaped with the
mysql_real_escape_string() C
API function.
This vulnerability was discovered and reported by Josh Berkus
<josh@postgresql.org> and Tom Lane
<tgl@sss.pgh.pa.us> as part of the inter-project
security collaboration of the OSDB consortium. For more
information about SQL injection, please see the following text.
Discussion.
An SQL injection security hole has been found in multi-byte
encoding processing. An SQL injection security hole can
include a situation whereby when a user supplied data to be
inserted into a database, the user might inject SQL statements
into the data that the server will execute. With regards to
this vulnerability, when character set-unaware escaping is
used (for example, addslashes() in PHP), it
is possible to bypass the escaping in some multi-byte
character sets (for example, SJIS, BIG5 and GBK). As a result,
a function such as addslashes() is not able
to prevent SQL-injection attacks. It is impossible to fix this
on the server side. The best solution is for applications to
use character set-aware escaping offered by a function such
mysql_real_escape_string().
However, a bug was detected in how the MySQL server parses the
output of
mysql_real_escape_string(). As
a result, even when the character set-aware function
mysql_real_escape_string() was
used, SQL injection was possible. This bug has been fixed.
Workarounds.
If you are unable to upgrade MySQL to a version that includes
the fix for the bug in
mysql_real_escape_string()
parsing, but run MySQL 5.0.1 or higher, you can use the
NO_BACKSLASH_ESCAPES SQL mode as a
workaround. (This mode was introduced in MySQL 5.0.1.)
NO_BACKSLASH_ESCAPES enables an SQL
standard compatibility mode, where backslash is not considered
a special character. The result will be that queries will
fail.
To set this mode for the current connection, enter the following SQL statement:
SET sql_mode='NO_BACKSLASH_ESCAPES';
You can also set the mode globally for all clients:
SET GLOBAL sql_mode='NO_BACKSLASH_ESCAPES';
This SQL mode also can be enabled automatically when the server
starts by using the command-line option
--sql-mode=NO_BACKSLASH_ESCAPES or by setting
sql-mode=NO_BACKSLASH_ESCAPES in the server
option file (for example, my.cnf or
my.ini, depending on your system).
(Bug#8378, CVE-2006-2753)
See also Bug#8303
The dropping of a temporary table whose name contained a
backtick ('`') character was not correctly
written to the binary log, which also caused it not to be
replicated correctly.
(Bug#19188)
The client libraries were not compiled for position-independent code on Solaris-SPARC and AMD x86_64 platforms. (Bug#18091, Bug#13159, Bug#14202)
Running myisampack followed by
myisamchk with the --unpack
option would corrupt the auto_increment key.
(Bug#12633)
The patch for Bug#8303 broke the fix for Bug#8378 and was
undone. (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 byte now is escaped, not the
entire multi-byte character. This means it a strict reverse of
the mysql_real_escape_string()
function.)
This MySQL 5.0.21 release includes the patches for recently
reported security vulnerabilites in the MySQL client-server
protocol. We would like to thank Stefano Di Paola
<stefano.dipaola@wisec.it> for finding and
reporting these to us.
This is a bugfix release for the current production release family.
This section documents all changes and bug fixes that have been applied since the last official MySQL release. If you would like to receive more fine-grained and personalized update alerts about fixes that are relevant to the version and features you use, please consider subscribing to MySQL Enterprise (a commercial MySQL offering). For more details please see http://www.mysql.com/products/enterprise.
Functionality added or changed:
Security Enhancement:
Added the global max_prepared_stmt_count
system variable to limit the total number of prepared statements
in the server. This limits the potential for denial-of-service
attacks based on running the server out of memory by preparing
huge numbers of statements. The current number of prepared
statements is available through the
prepared_stmt_count system variable.
(Bug#16365)
MySQL Cluster:
It is now possible to perform a partial start of a cluster. That
is, it is now possible to bring up the cluster without first
running ndbd --initial on
all configured data nodes.
(Bug#18606)
MySQL Cluster:
Added the --nowait-nodes startup option for
ndbd, making it possible to skip specified
nodes without waiting for them to start when starting the
cluster. See
Section 17.6.5.1, “Command Options for ndbd”.
MySQL Cluster:
It is now possible to install MySQL with Cluster support to a
non-default location and change the search path for font
description files using either the --basedir or
--character-sets-dir options. (Previously in
MySQL 5.0, ndbd searched only the default
path for character sets.)
Packaging:
The
MySQL-shared-compat-5.0.
shared compatibility RPMs no longer contain libraries for MySQL
5.1. This avoids a conflict because the 5.0 and 5.1 libraries
share the same soname number. They now contain libraries for
MySQL 3.23, 4.0, 4.1, and 5.0 only.
(Bug#19288)X-.i386.rpm
The default for the innodb_thread_concurrency
system variable was changed to 8.
(Bug#15868)
Server and clients ignored the --sysconfdir
option that was passed to configure. The
directory specified by this option, if set, now is used as one
of the standard locations in which to look for option files.
(Bug#15069)
In result set metadata, the
MYSQL_FIELD.length value for
BIT columns now is reported in number of
bits. For example, the value for a BIT(9)
column is 9. (Formerly, the value was related to number of
bytes.)
(Bug#13601)
Bugs fixed:
Security Fix:
Invalid arguments to
DATE_FORMAT() caused a server
crash. Thanks to Jean-David Maillefer for discovering and
reporting this problem to the Debian project and to Christian
Hammers from the Debian Team for notifying us of it.
(Bug#20729, CVE-2006-3469)
Security Fix:
A malicious client, using specially crafted invalid
COM_TABLE_DUMP packets was able to trigger an
exploitable buffer overflow on the server. Thanks to Stefano Di
Paola <stefano.dipaola@wisec.it> for finding and
reporting this bug.
(CVE-2006-1518)
Security Fix:
A malicious client, using specially crafted invalid login or
COM_TABLE_DUMP packets was able to read
uninitialized memory, which potentially, though unlikely in
MySQL, could have led to an information disclosure. (, ) Thanks
to Stefano Di Paola <stefano.dipaola@wisec.it> for
finding and reporting this bug.
(CVE-2006-1516, CVE-2006-1517)
MySQL Cluster:
A simultaneous DROP TABLE and table update
operation utilising a table scan could trigger a node failure.
(Bug#18597)
MySQL Cluster: When multiple node restarts were attempted without allowing each restart to complete, the error message returned was Array index out of bounds rather than Too many crashed replicas. (Bug#18349)
MySQL Cluster:
In a 2-node cluster with a node failure, restarting the node
with a low value for StartPartialTimeout
could cause the cluster to come up partitioned
(“split-brain” issue).
A similar issue could occur when the cluster was first started with a sufficiently low value for this parameter. (Bug#16447, Bug#18612)
MySQL Cluster: On systems with multiple network interfaces, data nodes would get “stuck” in startup phase 2 if the interface connecting them to the management server was working on node startup while the interface interconnecting the data nodes experienced a temporary outage. (Bug#15695)
MySQL Cluster:
On slow networks or CPUs, the management client
SHOW command could sometimes erroneously show
all data nodes as being master nodes belonging to nodegroup 0.
(Bug#15530)
MySQL Cluster:
Unused open handlers for tables in which the metadata had
changed were not properly closed. This could result in stale
results from NDB tables following an
ALTER TABLE statement.
(Bug#13228)
MySQL Cluster: Uninitialized internal variables could lead to unexpected results. (Bug#11033, Bug#11034)
MySQL Cluster:
When attempting to create an index on a BIT
or BLOB column, Error 743:
Unsupported character set in table or index was
returned instead of Error 906: Unsupported attribute
type in index.
InnoDB could read a delete mark from its
system tables incorrectly.
(Bug#19217)
Corrected a syntax error in mysql-test-run.sh. (Bug#19190)
Index corruption could occur in cases when
key_cache_block_size was not a multiple of
myisam_block_size (for example, with
key_cache_block_size=1536 and
myisam_block_size=1024).
(Bug#19079)
The optimizer could cause a server crash or use a non-optimal
subset of indexes when evaluating whether to use Index
Merge/Intersection variant of
index_merge optimization.
(Bug#19021)
A missing DBUG_RETURN() caused the server
to emit a spurious error message: missing DBUG_RETURN
or DBUG_VOID_RETURN macro in function
"open_table".
(Bug#18964)
Creating a table in an InnoDB database with a
column name that matched the name of an internal
InnoDB column (including
DB_ROW_ID, DB_TRX_ID,
DB_ROLL_PTR and DB_MIX_ID)
would cause a crash. MySQL now returns Error 1005
Cannot create table with
errno set to -1.
(Bug#18934)
MySQL would not compile on Linux distributions that use the
tinfo library.
(Bug#18912)
mysql_reconnect() sent a SET
NAMES statement to the server, even for pre-4.1
servers that do not understand the statement.
(Bug#18830)
For a reference to a non-existent stored function in a stored
routine that had a CONTINUE handler, the
server continued as though a useful result had been returned,
possibly resulting in a server crash.
(Bug#18787)
For single-SELECT union constructs of the
form (SELECT ... ORDER BY order_list1
[LIMIT n]) ORDER BY
order_list2, the ORDER
BY lists were concatenated and the
LIMIT clause was ignored.
(Bug#18767)
CREATE VIEW statements would not be
replicated to the slave if the
--replicate-wild-ignore-table rule was enabled.
(Bug#18715)
Conversion of a number to a CHAR UNICODE
string returned an invalid result.
(Bug#18691)
UNCOMPRESS(NULL) could cause
subsequent UNCOMPRESS() calls to
return NULL for legal
non-NULL arguments.
(Bug#18643)
If the second or third argument to
BETWEEN was a constant
expression such as '2005-09-01 - INTERVAL 6
MONTH and the other two arguments were columns,
BETWEEN was evaluated
incorrectly.
(Bug#18618)
A LOCK TABLES statement that failed could
cause MyISAM not to update table statistics
properly, causing a subsequent CHECK TABLE to
report table corruption.
(Bug#18544)
The yaSSL library returned a cipher list in a manner incompatible with OpenSSL. (Bug#18399)
InnoDB did not use a consistent read for
CREATE ... SELECT when
innodb_locks_unsafe_for_binlog was set.
(Bug#18350)
DROP DATABASE did not drop stored routines
associated with the database if the database name was longer
than 21 characters.
(Bug#18344)
The euro sign (€) was not stored
correctly in columns using the
latin1_german1_ci or
latin1_general_ci collation.
(Bug#18321)
A recent change caused the mysql client not
to display NULL values correctly and to
display numeric columns left-justified rather than
right-justified. The problems have been corrected.
(Bug#18265)
COUNT(*) on a
MyISAM table could return different results
for the base table and a view on the base table.
(Bug#18237)
EXTRACT(QUARTER FROM
returned unexpected
results.
(Bug#18100)date)
Executing SELECT on a large table that had
been compressed within myisampack could cause
a crash.
(Bug#17917)
Updating a field value when also requesting a lock with
GET_LOCK() would cause slave
servers in a replication environment to terminate.
(Bug#17284)
Casting a string to DECIMAL worked, but
casting a trimmed string (using
LTRIM() or
RTRIM()) resulted in loss of
decimal digits.
(Bug#17043)
mysql-test-run could not be run as
root.
(Bug#17002)
Queries of the form SELECT DISTINCT
did not return
all matching rows.
(Bug#16710)timestamp_column WHERE
date_function(timestamp_col)
= constant
IA-64 RPM packages for Red Hat and SuSE Linux that were built with the icc compiler incorrectly depended on icc runtime libraries. (Bug#16662)
MySQL-shared-compat-5.0.13-0.i386.rpm,
MySQL-shared-compat-5.0.15-0.i386.rpm,
MySQL-shared-compat-5.0.18-0.i386.rpm,
MySQL-shared-compat-5.0.19-0.i386.rpm,
MySQL-shared-compat-5.0.20-0.i386.rpm, and
MySQL-shared-compat-5.0.20a-0.i386.rpm
incorrectly depended on glibc 2.3 and could
not be installed on a glibc 2.2 system.
(Bug#16539)
The presence of multiple equalities in a condition after reading a constant table could cause the optimizer not to use an index. This resulted in certain queries being much slower than in MySQL 4.1. (Bug#16504)
Within a trigger,
CONNECTION_ID() did not return
the connection ID of the thread that caused the trigger to be
activated.
(Bug#16461)
For tables created in a MySQL 4.1 installation upgraded to MySQL 5.0 and up, multiple-table updates could update only the first matching row. (Bug#16281)
A query using WHERE (column_1,
column_2) IN
((value_1,
value_2)[, (..., ...), ...]) would
return incorrect results.
(Bug#16248)
For mysql.server, if the
basedir option was specified after
datadir in an option file, the setting for
datadir was ignored and assumed to be located
under basedir.
(Bug#16240)
If the first argument to
BETWEEN was a
DATE or TIME column of a
view and the other arguments were constants,
BETWEEN did not perform
conversion of the constants to the appropriate temporary type,
resulting in incorrect evaluation.
(Bug#16069)
After calling FLUSH STATUS, the
max_used_connections variable did not
increment for existing connections and connections which use the
thread cache.
(Bug#15933)
Lettercase in database name qualifiers was not consistently
handled properly in queries when
lower_case_table_names was set to 1.
(Bug#15917)
DELETE and UPDATE
statements that used large NOT IN
( clauses could
use large amounts of memory.
(Bug#15872)value_list)
InnoDB failure to release an adaptive hash
index latch could cause a server crash if the query cache was
enabled.
(Bug#15758)
LAST_INSERT_ID() in a stored
function or trigger returned zero. .
(Bug#15728)
DELETE with LEFT JOIN for
InnoDB tables could crash the server if
innodb_locks_unsafe_for_binlog was enabled.
(Bug#15650)
When running a query that contained a
GROUP_CONCAT(SELECT GROUP_CONCAT(...)
), the result was NULL except in
the ROLLUP part of the result, if there was
one.
(Bug#15560)
Use of CONVERT_TZ() in a view
definition could result in spurious syntax or access errors.
(Bug#15153)
CAST( for large
double AS
SIGNED INT)double values outside the signed
integer range truncated the result to be within range, but the
result sometimes had the wrong sign, and no warning was
generated.
(Bug#15098)
TRUNCATE did not reset the
AUTO_INCREMENT counter for
MyISAM tables when issued inside a stored
procedure.
This bug did not affect InnoDB tables.
In addition, TRUNCATE does not reset the
AUTO_INCREMENT counter for
NDB tables regardless of when it is called.
See also Bug#18864
For InnoDB tables, an expression of the form
when used in a join
returned incorrect results.
(Bug#14360)col_name BETWEEN
col_name2 - INTERVAL
x DAY AND
col_name2 + INTERVAL
x DAY
Prevent recursive views caused by using RENAME
TABLE on a view after creating it.
(Bug#14308)
INSERT DELAYED into a view caused an infinite
loop.
(Bug#13683)
Avoid trying to include
<asm/atomic.h> when it doesn't work
in C++ code.
(Bug#13621)
Within stored routines, usernames were parsed incorrectly if they were enclosed within quotes. (Bug#13310)
The server was always built as though
--with-extra-charsets=complex had been
specified.
(Bug#12076)
This is a bugfix release for the current production release family. It replaces MySQL 5.0.20.
Additional information about SSL support
Please note that the original 5.0.20 announcement included
inexact wording: SSL support is “included” in both
server and client, but by default not “enabled”.
SSL can be enabled by passing the SSL-related options
(--ssl, --ssl-key=...,
--ssl-cert=..., --ssl-ca=...)
when starting the server and the client or by specifying these
options in an option file. For more information, see
Section 5.5.7, “Using SSL for Secure Connections”.
With version 5.0.20a, SSL support is contained in all binaries
for all Unix (including Linux) and Windows platforms except AIX,
HP-UX, OpenServer 6, and the RPMs specific for RHAS3/RHAS4/SLES9
on Itanium CPUs (ia64); It is also not
contained in those for Novell Netware. We are trying to add
these platforms in future versions.
Bugs fixed:
The fix for “Command line options are ignored for mysql client” has been revoked because it introduced an incompatible change in the way the mysql command-line client selects the server to connect to. In the worst case, this might have led to a client issuing commands to a server for which they were not intended, and this must not happen. To help all users in understanding this subject, Section 4.2.1, “Invoking MySQL Programs” now includes additional explanation of how command options with regard to host selection. (Bug#16855)
The code of the yaSSL library has been
improved to avoid the dependency on a C++ runtime library, so a
link with pure C applications is now possible on additional (but
not yet all) platforms. We are working on fixing the remaining
issues.
Functionality added or changed:
MySQL Cluster:
The NDBCluster storage engine now supports
INSERT IGNORE and REPLACE
statements. Previously, these statements failed with an error.
(Bug#17431)
Builds for Windows, Linux, and Unix (except AIX) platforms now have SSL support enabled, in the server as well as in the client libraries. Because part of the SSL code is written in C++, this does introduce dependencies on the system's C++ runtime libraries in several cases, depending on compiler specifics. (Bug#18195)
Large file support added to build for QNX
platform.
(Bug#17336)
InnoDB: The InnoDB storage
engine now provides a descriptive error message if
ibdata file information is omitted from
my.cnf.
(Bug#16827)
Triggers from older servers that included no
DEFINER clause in the trigger definition now
execute with the privileges of the invoker (which on the slave
is the slave SQL thread). Previously, replication slaves could
not replicate such triggers.
(Bug#16266)
Added the --sysdate-is-now option to
mysqld to enable
SYSDATE() to be treated as an
alias for NOW(). See
Section 11.6, “Date and Time Functions”.
(Bug#15101)
Large file support was re-enabled for the MySQL server binary for the AIX 5.2 platform. (Bug#13571)
The syntax for CREATE PROCEDURE and
CREATE FUNCTION statements now includes a
DEFINER clause. The
DEFINER value specifies the security context
to be used when checking access privileges at routine invocation
time if the routine has the SQL SECURITY
DEFINER characteristic. See
Section 19.2.1, “CREATE PROCEDURE and CREATE
FUNCTION Syntax”, for more information.
When mysqldump is invoked with the
--routines option, it now dumps the
DEFINER value for stored routines.
Bugs fixed:
MySQL Cluster:
A timeout in the handling of an ABORT
condition with more that 32 operations could yield a node
failure.
(Bug#18414)
MySQL Cluster:
A node restart immediately following a CREATE
TABLE would fail.
This fix supports 2-node Clusters only.
MySQL Cluster: In event of a node failure during a rollback, a “false” lock could be established on the backup for that node, which lock could not be removed without restarting the node. (Bug#18352)
MySQL Cluster: The cluster created a crashed replica of a table having an ordered index — or when logging was not enabled, of a table having a table or unique index — leading to a crash of the cluster following 8 successive restarts. (Bug#18298)
MySQL Cluster: When replacing a failed master node, the replacement node could cause the cluster to crash from a buffer overflow if it had an excessively large amount of data to write to the cluster log. (Bug#18118)
MySQL Cluster:
Certain queries using ORDER BY ... ASC in the
WHERE clause could return incorrect results.
(Bug#17729)
MySQL Cluster: If a mysql or other client could not parse the result set returned from a mysqld process acting as an SQL node in a cluster, the client would crash instead of returning the appropriate error. For example, this could happen when the client attempted to use a character set was not available to the mysqld. (Bug#17380)
MySQL Cluster: Some query cache statistics were not always correctly reported for Cluster tables. (Bug#16795)
MySQL Cluster: Restarting nodes were allowed to start and join the cluster too early. (Bug#16772)
MySQL Cluster:
Inserting and deleting BLOB column values
while a backup was in process could cause data nodes to shut
down.
(Bug#14028)
MySQL Cluster:
The server would not compile with NDB support
on AIX 5.2.
(Bug#10776)
A SELECT ... ORDER BY ... from a view defined
using a function could crash the server. An example of such a
view is CREATE VIEW v1 AS SELECT SQRT(c1) FROM
t1.
(Bug#18386)
InnoDB had a memory leak for duplicate-key
errors with tables having 90 columns or more.
(Bug#18384)
A DELETE using a subquery could crash the
server.
(Bug#18306)
If a row was inserted inside a stored procedure using the parameters passed to the procedure in the INSERT statement, the resulting binlog entry was not escaped properly. (Bug#18293)
If InnoDB encountered a
HA_ERR_LOCK_TABLE_FULL error and rolled back
a transaction, the transaction was still written to the binary
log.
(Bug#18283)
When using ORDER BY with a non-string column
inside GROUP_CONCAT() the
result's character set was converted to binary.
(Bug#18281)
See also Bug#14169
Complex queries with nested joins could cause a server crash. (Bug#18279)
For InnoDB tables created in MySQL 4.1 or
earlier, or created in 5.0 or later with compact format,
updating a row so that a long column is updated or the length of
some column changes, InnoDB later would fail
to reclaim the BLOB storage space if the row
was deleted.
(Bug#18252)
If InnoDB ran out of buffer space for row
locks and adaptive hashes, the server would crash. Now
InnoDB rolls back the transaction.
(Bug#18238)
Views that incorporated tables from the
INFORMATION_SCHEMA database resulted in a
server crash when queried.
(Bug#18224)
REPAIR TABLE, OPTIMIZE
TABLE, and ALTER TABLE operations
on transactional tables (or on tables of any type on Windows)
could corrupt triggers associated with those tables.
(Bug#18153)
The server could deadlock under heavy load while writing to the binary log. (Bug#18116)
A SELECT * query on an
INFORMATION_SCHEMA table by a user with
limited privileges resulted in a server crash.
(Bug#18113)
Connecting to a server with a UCS2 default character set with a client using a non-UCS2 character set crashed the server. (Bug#18004)
MyISAM: Performing a bulk insert on a table
referenced by a trigger would crash the table.
(Bug#17764)
Updating a view that filters certain rows to set a filtered out
row to be included in the table caused infinite loop. For
example, if the view has a WHERE clause of salary >
100 then issuing an UPDATE statement of SET
salary = 200 WHERE id = 10, caused an infinite loop.
(Bug#17726)
MyISAM: Keys for which the first part of the
key was a CHAR or VARCHAR
column using the UTF-8 character set and longer than 254 bytes
could become corrupted.
(Bug#17705)
Updating the value of a Unicode VARCHAR
column with the result returned by a stored function would cause
the insertion of ASCII characters into the column instead of
Unicode, even where the function's return type was also declared
as Unicode.
(Bug#17615)
For FEDERATED tables, a
SELECT statement with an ORDER
BY clause did not return rows in the proper order.
(Bug#17377)
SELECT ... WHERE , when column LIKE
'A%'column had a key
and used the latin2_czech_cs collation,
caused the wrong number of rows to be returned.
(Bug#17374)
A LEFT JOIN with a UNION
that selects literal values could crash the server.
(Bug#17366)
Checks for permissions on database operations could be performed
in a case-insensitive manner (a user with permissions on
database MYDATABASE could by accident get
permissions on database myDataBase), if the
privilege data were still cached from a previous check.
(Bug#17279)
Stored procedures that call UDFs and pass local string variables caused server crashes. (Bug#17261)
If the WHERE condition of a query contained
an OR-ed FALSE term, the
set of tables whose rows cannot serve for null-complements in
outer joins was determined incorrectly. This resulted in
blocking possible conversions of outer joins into joins by the
optimizer for such queries.
(Bug#17164)
Use of TRUNCATE TABLE for a
TEMPORARY table on a master server was
propagated to slaves properly, but slaves did not decrement the
Slave_open_temp_tables counter properly.
(Bug#17137)
InnoDB tables with an adaptive hash blocked
other queries during CHECK TABLE statements
while the entire hash was checked. This could be a long time for
a large hash.
(Bug#17126)
Stored routine names longer than 64 characters were silently truncated. Now the limit is properly enforced and an error occurs. (Bug#17015)
InnoDB: The LATEST FOREIGN KEY
ERROR section in the output of SHOW INNODB
STATUS was sometimes formatted incorrectly, causing
problems with scripts that parsed the output of this statement.
(Bug#16814)
If the server was started with the
--skip-grant-tables option, it was impossible
to create a trigger or a view without explicitly specifying a
DEFINER clause.
(Bug#16777)
The FORMAT() function returned
an incorrect result when the client's
character_set_connection value was
utf8.
(Bug#16678)
Using ORDER BY within a stored procedure (where
intvar
intvar is an integer variable or
expression) would crash the server.
The use of an integer i in an
ORDER BY
clause for sorting the result by the
ii th
column is deprecated (and non-standard). It should
not be used in new applications. See
Section 12.2.7, “SELECT Syntax”.
The DEFINER value for stored routines was not
replicated.
(Bug#15963)
Character set conversion of string constants for
UNION of constant and table column was not
done when it was safe to do so.
(Bug#15949)
Triggers created in MySQL 5.0.16 and earlier could not be dropped after upgrading the server to 5.0.17 or later. (Bug#15921)
The mysql_close() C API
function leaked handles for shared-memory connections on
Windows.
(Bug#15846)
COUNT(DISTINCT
and
col1,
col2)COUNT(DISTINCT
CONCAT( operations produced
different results if one of the columns was an indexed
col1,
col2))DECIMAL column.
(Bug#15745)
A SELECT using a function against a nested
view would crash the server.
(Bug#15683)
The server displayed garbage in the error message warning about
bad assignments to DECIMAL columns or routine
variables.
(Bug#15480)
During conversion from one character set to
ucs2, multi-byte characters with no
ucs2 equivalent were converted to multiple
characters, rather than to 0x003F QUESTION
MARK.
(Bug#15375)
Certain combinations of joins with mixed ON
and USING clauses caused unknown column
errors.
(Bug#15229)
SELECT COUNT(*) for a
MyISAM table could return different results
depending on whether an index was used.
(Bug#14980)
Attempting to access an InnoDB table after
starting the server with --skip-innodb caused a
server crash.
(Bug#14575)
Use of stored functions with DISTINCT or
GROUP BY can produce incorrect results when
ORDER BY is also used.
(Bug#13575)
The server would execute stored routines that had a non-existent definer. (Bug#13198)
mysql_config returned incorrect libraries on
x86_64 systems.
(Bug#13158)
Loading of UDFs in a statically linked MySQL caused a server crash. UDF loading is now blocked if the MySQL server is statically linked. (Bug#11835)
Functionality added or changed:
Incompatible Change:
The InnoDB storage engine no longer ignores
trailing spaces when comparing BINARY or
VARBINARY column values. This means that (for
example) the binary values 'a' and
'a ' are now regarded as
unequal any time they are compared, as they
are in MyISAM tables.
See Section 10.4.2, “The BINARY and VARBINARY Types” for more information
about the BINARY and
VARBINARY types.
(Bug#14189)
MySQL Cluster:
More descriptive warnings are now issued when inappropriate
logging parameters are set in config.ini.
(Formerly, the warning issued was simply Could not
add logfile destination.)
(Bug#11331)
MySQL Cluster:
The ndb_mgm client commands
and
node_id START now
work with management nodes as well as data nodes. However, using
node_id STOPALL for node_id
continues to affect all data nodes only.
mysql no longer terminates data value display when it encounters a NUL byte. Instead, it displays NUL bytes as spaces. (Bug#16859)
New charset command added to
mysql command-line client. By typing
charset or
name\C (such as
name\C UTF8), the client character set can be
changed without reconnecting.
(Bug#16217)
Added the --wait-timeout option to
mysqlmanager to allow configuration of the
timeout for dropping an inactive connection, and increased the
default timeout from 30 seconds to 28,800 seconds (8 hours).
(Bug#15980, Bug#12674)
The INFORMATION_SCHEMA now skips data
contained in unlistable/unreadable directories rather than
returning an error.
(Bug#15851)
InnoDB now caches a list of unflushed files
instead of scanning for unflushed files during a table flush
operation. This improves performance when
--innodb_file_per_table is set on a system with
a large number of InnoDB tables.
(Bug#15653)
Added the --port-open-timeout option to
mysqld to control how many seconds the server
should wait for the TCP/IP port to become free if it cannot be
opened.
(Bug#15591)
Wording of error 1329 changed to No data - zero rows fetched, selected, or processed. (Bug#15206)
The message for error 1109 changed from Unknown table ... in order clause to Unknown table ... in field list. (Bug#15091)
A number of performance issues were resolved that had previously
been encountered when using statements that repeatedly invoked
stored functions. For example, calling
BENCHMARK() using a stored
function executed much more slowly than when invoking it with
inline code that accomplished the same task. In most cases the
two should now execute with approximately the same speed.
(Bug#14946, Bug#15014)
mysqldump now surrounds the
DEFINER, SQL SECURITY
DEFINER and WITH CHECK OPTION
clauses of a CREATE VIEW statement with
"not in version" comments to prevent errors in earlier
versions of MySQL.
(Bug#14871)
When using the GROUP_CONCAT()
function where the group_concat_max_len
system variable was greater than 512, the type of the result was
BLOB only if the query included an
ORDER BY clause; otherwise the result was a
VARCHAR.
The result type of the
GROUP_CONCAT() function is now
VARCHAR only if the value of the
group_concat_max_len system variable is less
than or equal to 512. Otherwise, this function returns a
BLOB.
(Bug#14169)
The mysql_ping function will now retry if
the reconnect flag is set and error
CR_SERVER_LOST is encountered during the
first attempt to ping the server.
(Bug#14057)
The mysqltest utility now converts all
CR/LF combinations to LF
to allow test cases intended for Windows to work properly on
UNIX-like systems.
(Bug#13809)
libmysqlclient now uses versioned symbols
with GNU ld.
(Bug#3074)
The client API now attempts to reconnect using TCP/IP if the
reconnect flag is set, as is the case with
sockets.
(Bug#2845)
Added the --check-upgrade to
mysqlcheck that invokes CHECK
TABLE with the FOR UPGRADE option.
Added the FOR UPGRADE option for the
CHECK TABLE statement. This option checks
whether tables are incompatible with the current version of
MySQL Server.
Two new Hungarian collations are included:
utf8_hungarian_ci and
ucs2_hungarian_ci. These support the correct
sort order for Hungarian vowels. However, they do not support
the correct order for sorting Hungarian consonant contractions;
this issue will be fixed in a future release.
Several changes were made to make upgrades easier:
Added the mysql_upgrade program that checks all tables for incompatibilities with the current version of MySQL Server and repairs them if necessary. This program should be run for each MySQL upgrade (rather than mysql_fix_privilege_tables). See Section 4.4.9, “mysql_upgrade — Check Tables for MySQL Upgrade”.
Added the FOR UPGRADE option for the
CHECK TABLE statement. This option checks
whether tables are incompatible with the current version of
MySQL Server.
Added the --check-upgrade to
mysqlcheck that invokes CHECK
TABLE with the FOR UPGRADE
option.
Added the mysql_upgrade program that checks all tables for incompatibilities with the current version of MySQL Server and repairs them if necessary. This program should be run for each MySQL upgrade (rather than mysql_fix_privilege_tables). See Section 4.4.9, “mysql_upgrade — Check Tables for MySQL Upgrade”.
Bugs fixed:
MySQL Cluster:
Cluster log file paths were truncated to 128 characters. They
may now be as long as MAX_PATH (the maximum
path length permitted by the operating system).
(Bug#17411)
MySQL Cluster:
Following multiple forced shutdowns and restarts of data nodes,
DROP DATABASE could fail.
(Bug#17325)
MySQL Cluster:
The REDO log would become corrupted (and thus
unreadable) in some circumstances, due to a failure in the query
handler.
(Bug#17295)
MySQL Cluster:
An UPDATE with an inner join failed to match
any records if both tables in the join did not have a primary
key.
(Bug#17257)
MySQL Cluster:
A DELETE with a join in the
WHERE clause failed to retrieve any records
if both tables in the join did not have a primary key.
(Bug#17249)
MySQL Cluster:
The error message returned by perror
was prefixed with OS
error code: instead of NDB error
code:.
(Bug#17235)--ndb
MySQL Cluster:
In some cases, LOAD DATA INFILE did not load
all data into NDB tables.
(Bug#17081)
MySQL Cluster:
ndb_delete_all ran out of memory when
processing tables containing BLOB columns.
(Bug#16693)
MySQL Cluster:
A BIT column whose offset and length totaled
32 caused the cluster to crash.
(Bug#16125)
MySQL Cluster:
UNIQUE keys in Cluster tables were limited to
225 bytes in length.
(Bug#15918)
MySQL Cluster:
The ndb_autodiscover test failed sporadically
due to a node not being permitted to connect to the cluster.
(Bug#15619)
MySQL Cluster:
NDB returned an incorrect Can't
find file error for OS error 24; this has been
changed to Too many open files.
(Bug#15020)
MySQL Cluster:
No error message was generated for setting
NoOfFragmentLogFiles too low.
(Bug#13966)
MySQL Cluster:
No error message was generated for setting
MaxNoOfAttributes too low.
(Bug#13965)
MySQL Cluster: When running more than one management process in a cluster:
ndb_mgm -c
host:port
-e "node_id STOP"
stopped a management process running only on the same
system where the command was issued.
ndb_mgm -e "SHUTDOWN" failed to shut down any management processes at all.
MySQL Cluster:
ndb_mgm -c
host:port
-e "node_id STOP" would
stop a management process running only on the same system on
which the command was issued.
MySQL Cluster: ndb_mgm -e "SHUTDOWN" failed to shut down any management processes at all.
Cluster API: Upon the completion of a scan where a key request remained outstanding on the primary replica and a starting node died, the scan did not terminate. This caused incomplete error handling for the failed node. (Bug#15908)
type_decimal failed with the prepared
statement protocol.
(Bug#17826)
The MySQL server could crash with out of memory errors when
performing aggregate functions on a DECIMAL
column.
(Bug#17602)
Using DROP FUNCTION IF EXISTS
to drop a
user-defined function caused a server crash if the server was
running with the func_name--skip-grant-tables option.
(Bug#17595)
Data truncations on non-UNIQUE indexes could
crash InnoDB when using multi-byte character
sets.
(Bug#17530)
A natural join between INFORMATION_SCHEMA
tables failed.
(Bug#17523)
A stored procedure failed to return data the first time it was called per connection. (Bug#17476)
For certain MERGE tables, the optimizer
wrongly assumed that using
index_merge/intersection was too expensive.
(Bug#17314)
The parser allowed CREATE AGGREGATE FUNCTION
for creating stored functions, even though
AGGREGATE does not apply. (It is used only
for CREATE FUNCTION only when creating
user-defined functions.)
(Bug#16896)
Cursors in stored routines could cause a server crash. (Bug#16887)
Triggers created without BEGIN and
END clauses resulted in “You have an
error in your SQL syntax” errors when dumping and
replaying a binary log.
(Bug#16878)
Using ALTER TABLE to increase the length of a
BINARY( column
caused column values to be padded with spaces rather than
M)0x00 bytes.
(Bug#16857)
A RETURN statement within a trigger caused a
server crash. RETURN now is disallowed within
triggers. To exit immediately, use LEAVE.
(Bug#16829)
For a MySQL 5.0 server, using MySQL 4.1 tables in queries with a
GROUP BY clause could result in buffer
overrun or a server crash.
(Bug#16752)
An INSERT statement in a stored procedure
corrupted the binary log.
(Bug#16621)
If the query optimizer transformed a GROUP BY
clause in a subquery, it did not also transform the
HAVING clause if there was one, producing
incorrect results.
(Bug#16603)
In a highly concurrent environment, a server crash or deadlock could result from execution of a statement that used stored functions or activated triggers coincident with alteration of the tables used by these functions or triggers. (Bug#16593)
A race condition could occur when dropping the adaptive hash
index for a B-tree page in InnoDB.
(Bug#16582)
When evaluation of the test in a CASE failed
in a stored procedure that contained a
CONTINUE handler, execution resumed at the
beginning of the CASE statement instead of at the end.
(Bug#16568)
For a transaction that used MyISAM and
InnoDB tables, interruption of the
transaction due to a dropped connection on a master server
caused slaves to lose synchrony.
(Bug#16559)
Clients compiled from source with the
--without-readline did not save command history
from session to session.
(Bug#16557)
The DECIMAL data type was not being handled
correctly with prepared statements.
(Bug#16511)
Instance Manager searched wrong location for password file on some platforms. (Bug#16499)
UPDATE statement crashed multi-byte character
set FULLTEXT index if update value was almost
identical to initial value only differing in some spaces being
changed to .
(Bug#16489)
The --replicate-do and
--replicate-ignore options were not being
enforced on multiple-table statements.
(Bug#16487, Bug#15699)
Certain nested LEFT JOIN operations were not
properly optimized.
(Bug#16393)
Dropping InnoDB constraints named
could crash the server.
(Bug#16387)tbl_name_ibfk_0
SELECT with GROUP BY on a
view could cause a server crash.
(Bug#16382)
An invalid stored routine could not be dropped. (Bug#16303)
InnoDB: After upgrading an
InnoDB table having a VARCHAR
BINARY column created in MySQL 4.0 to MySQL 5.0,
update operations on the table would cause the server to crash.
(Bug#16298)
Parallel builds occasionally failed on Solaris. (Bug#16282)
A call to the IF() function using decimal
arguments could return incorrect results.
(Bug#16272)
MySQL server dropped client connection for certain
SELECT statements against views defined that
used MERGE algorithm.
(Bug#16260)
InnoDB used full explicit table locks in
trigger processing.
(Bug#16229)
Using GROUP BY on column used in
WHERE clause could cause empty set to be
returned.
(Bug#16203)
A memory leak caused warnings on slaves for certain statements that executed without warning on the master. (Bug#16175)
The FORCE INDEX keyword in a query would
prevent an index merge from being used where an index merge
would normally be chosen by the optimizer.
(Bug#16166)
Setting InnoDB path settings to an empty
string caused InnoDB storage engine to crash
upon server startup.
(Bug#16157)
The mysql_stmt_sqlstate() C API
function incorrectly returned an empty string rather than
'00000' when no error occurred.
(Bug#16143)
MIN() and
MAX() operations were not
optimized for views.
(Bug#16016)
Performing a RENAME TABLE on an
InnoDB table when the server was started with
the --innodb_file_per_table option and the data
directory was a symlink caused a server crash.
(Bug#15991)
Executing a SHOW CREATE VIEW query of an
invalid view caused the mysql_next_result()
function of libMySQL.dll to hang.
(Bug#15943)
Test suite sp test left behind tables when
the test failed that could cause future tests to fail.
(Bug#15866)
STR_TO_DATE(1,NULL) caused a
server crash.
(Bug#15828, CVE-2006-3081)
CAST(... AS TIME) operations
returned different results when using versus not using
prepared-statement protocol.
(Bug#15805)
Issuing a DROP USER command could cause some
users to encounter a
error.
(Bug#15775)hostname is not allowed to connect to
this MySQL server
The contents of fill_help_tables.sql could
not be loaded in strict SQL mode.
(Bug#15760)
fill_help_tables.sql was not included in
binary distributions for several platforms.
(Bug#15759)
Certain LEAVE statements in stored procedures
were not properly optimized.
(Bug#15737)
The mysql_real_connect() C API function
incorrectly reset the MYSQL_OPT_RECONNECT
option to its default value.
(Bug#15719)
Created a user function with an empty string (that is,
CREATE FUNCTION ''()), was accepted by the
server. Following this, calling SHOW FUNCTION
STATUS would cause the server to crash.
(Bug#15658)
Trying to compile the server on Windows generated a stack
overflow warning due to a recursive definition of the internal
Field_date::store() method.
(Bug#15634)
In some cases the query optimizer did not properly perform multiple joins where inner joins followed left joins, resulting in corrupted result sets. (Bug#15633)
Certain permission management statements could create a
NULL hostname for a user, resulting in a
server crash.
(Bug#15598)
Improper memory handling for stored routine variables could cause memory overruns and binary log corruption. (Bug#15588)
The COALESCE() function
truncated data in a TINYTEXT column.
(Bug#15581)
Binary distributions for Solaris contained files with group
ownership set to the non-existing wheel
group. Now the bin group is used.
(Bug#15562)
The absence of a table in the left part of a left or right join was not checked prior to name resolution, which resulted in a server crash. (Bug#15538)
A SELECT of a stored function that references
the INFORMATION_SCHEMA could crash the
server.
(Bug#15533)
Characters in the gb2312 and
euckr character sets which did not have
Unicode mappings were truncated.
(Bug#15377)
Certain subqueries where the inner query was the result of a aggregate function would return different results with MySQL 5.0 than with MySQL 4.1.
Subselects could also return wrong results when the query cache and grouping were involved. (Bug#15347)
Performing an ORDER BY on an indexed
ENUM column returned error.
(Bug#15308)
A SELECT query which contained a
GROUP_CONCAT() and an
ORDER BY clause against the
INFORMATION_SCHEMA resulted in an empty
result set.
(Bug#15307)
The NOT FOUND condition handler for stored
procedures did not distinguish between a NOT
FOUND condition and an exception or warning.
(Bug#15231)
The SELECT privilege was required for
triggers that performed no selects.
(Bug#15196)
An attempt to open a table that requires a disabled storage engine could cause a server crash. (Bug#15185)
The UPDATE privilege was required for
triggers that performed no updates.
(Bug#15166)
Tarball install package was missing a proper
fill_help_tables.sql file.
(Bug#15151)
Setting innodb_log_file_size to a value
greater than 4G crashed the server.
(Bug#15108)
When multiple handlers are created for the same MySQL error number within nested blocks, the outermost handler took precedence. (Bug#15011)
A statement containing GROUP BY and
HAVING clauses could return incorrect results
when the HAVING clause contained logic that
returned FALSE for every row.
(Bug#14927)
Stored routines that contained only a single statement were not
written properly to the dumpfile when using
mysqldump.
(Bug#14857)
Killing a long-running query containing a subquery could cause a server crash. (Bug#14851)
GRANT statements specifying schema names that
included underscore characters (i.e.
my_schema) did not match if the underscore
was escaped in the GRANT statement (i.e.
GRANT ALL ON `my\_schema` ...).
(Bug#14834)
Previously, a stored function invocation was written to the
binary log as DO
if the
invocation changes data and occurs within a non-logged
statement, or if the function invokes a stored procedure that
produces an error. These invocations now are logged as
func_name()SELECT
instead for better control over error code checking (slave
servers could stop due to detecting a different error than
occurred on the master).
(Bug#14769)func_name()
Generating an AUTO_INCREMENT value through a
FEDERATED table did not set the value
returned by LAST_INSERT_ID().
(Bug#14768)
SUBSTRING_INDEX() could yield
inconsistent results when applied with the same arguments to
consecutive rows in a query.
(Bug#14676)
Running out of diskspace in the location specified by the
tmpdir option resulted in incorrect error
message.
(Bug#14634)
InnoDB: Comparison of indexed
VARCHAR CHARACTER SET ucs2 COLLATE ucs2_bin
columns using LIKE could fail.
(Bug#14583)
A stored procedure with an undefined variable and an exception handler would hang the client when called. (Bug#14498)
A FULLTEXT query in a prepared statement
could result in unexpected behavior.
(Bug#14496)
Using an aggregate function as the argument for a
HAVING clause resulted in the aggregate
function always returning FALSE.
(Bug#14274)
The use of LOAD INDEX within a stored routine
was permitted and caused the server to crash.
LOAD INDEX statements within stored
routines are not supported, and now yield
an error if attempted. This behavior is intended.
A COMMIT statement followed by a
ALTER TABLE statement on a BDB table caused
server crash.
(Bug#14212)
The mysql_stmt_store_result() C
API function could not be used for a prepared statement if a
cursor had been opened for the statement.
(Bug#14013)
SET sql_mode = ,
where NN > 31, did not work
properly.
(Bug#13897)
Attempts to create FULLTEXT indexes on
VARCHAR columns larger than 1000 bytes
resulted in error.
(Bug#13835)
The RENAME TABLE statement did not move
triggers to the new table.
(Bug#13525)
BIT fields were not properly handled when
using row-based replication.
(Bug#13418)
The length of a VARCHAR() column that used
the utf8 character set would increase each
time the table was re-created in a stored procedure or prepared
statement, eventually causing the CREATE
TABLE statement to fail.
(Bug#13134)
Instance Manager erroneously accepted a list of instance
identifiers for the START INSTANCE and
STOP INSTANCE commands (should accept only a
single identifier).
(Bug#12813)
A prepared statement created from a SELECT ...
LIKE query (such as PREPARE stmt1 FROM
'SELECT col_1 FROM tedd_test WHERE col_1 LIKE ?';)
would begin to produce erratic results after being executed
repeatedly numerous (thousands) of times.
(Bug#12734)
Multi-byte path names for LOAD DATA and
SELECT ... INTO OUTFILE caused errors. Added
the character_set_filesystem system variable,
which controls the interpretation of string literals that refer
to filenames.
(Bug#12448)
Temporary table aliasing did not work inside stored functions. (Bug#12198)
The embedded server did not allow binding of columns to the
MYSQL_TYPE_VAR_STRING data type in prepared
statements.
(Bug#12070)
When MyODBC or any other client called
my_init()/my_end()
several times, it caused corruption of charset data stored in
once_mem_pool.
(Bug#11892)
Setting the myisam_repair_threads system
variable to a value larger than 1 could cause corruption of
large MyISAM tables.
(Bug#11527)
The mysqlbinlog utility did not output
DELIMITER statements, causing syntax errors
for stored routine creation statements.
(Bug#11312)
The embedded server failed various tests in the automated test suite. (Bug#10801, Bug#10925, Bug#15433, Bug#9633, Bug#10926, Bug#9631, Bug#10930, Bug#10911, Bug#9630, Bug#10924)
A large BIGINT value specified in a
WHERE clause could be treated differently
depending on whether it is specified as a quoted string. (For
example, WHERE bigint_col =
17666000000000000000 versus WHERE bigint_col
= '17666000000000000000').
(Bug#9088)
CHECKSUM TABLE returned different values for
MyISAM tables depending on whether the
QUICK or EXTENDED option
was used.
(Bug#8841)
Using the TRUNCATE() function with a
negative number for the second argument on a
BIGINT column returned incorrect results.
(Bug#8461)
Issuing GRANT EXECUTE on a procedure would
display any warnings related to the creation of the procedure.
(Bug#7787)
Repeated invocation of my_init() and
my_end() caused corruption of character set
data and connection failure.
(Bug#6536)
An INSERT ... SELECT statement between tables
in a MERGE set can return errors when
statement involves insert into child table from merge table or
vice-versa.
(Bug#5390)
Functionality added or changed:
The server treats stored routine parameters and local variables
(and stored function return values) according to standard SQL.
Previously, parameters, variables, and return values were
treated as items in expressions and were subject to automatic
(silent) conversion and truncation. Now the data type is
observed. Data type conversion and overflow problems that occur
in assignments result in warnings, or errors in strict mode. The
CHARACTER SET clause for character data type
declarations is used. Parameters, variables, and return values
must be scalars; it is no longer possible to assign a row value.
Also, stored functions execute using the
sql_mode value in force at function creation
time rather than ignoring it. For more information, see
Section 19.2.1, “CREATE PROCEDURE and CREATE
FUNCTION Syntax”.
(Bug#13808, Bug#12903, Bug#9078, Bug#14161, Bug#13705, Bug#13909, Bug#15148, Bug#8769, Bug#8702, Bug#9572, Bug#8768)
It is now possible to build the server such that
MyISAM tables can support up to 128 keys
rather than the standard 64. This can be done by configuring the
build using the option
--with-max-indexes=, where N
N≤128 is the
maximum number of indexes to permit per table.
(Bug#10932)
Bugs fixed:
MySQL Cluster: If an abort by the Transaction Coordinator timed out, the abort condition was incorrectly handled, causing the transaction record to be released prematurely. (Bug#15685)
MySQL Cluster:
The ndb_read_multi_range.test script failed
to drop a table, causing the test to fail.
(Bug#15675)
See also Bug#15402
MySQL Cluster: Under some circumstances, it was possible for a restarting node to undergo a forced shutdown. (Bug#15632)
MySQL Cluster: A node which failed during cluster startup was sometimes not removed from the internal list of active nodes. (Bug#15587)
When a connection using yaSSL was aborted, the server would
continue to try to read the closed socket, and the thread
continued to appear in the output of SHOW
PROCESSLIST. Note that this issue did not affect
secure connection attempts using OpenSSL.
(Bug#15772)
API function
mysql_stmt_prepare() returned
wrong field length for TEXT columns.
(Bug#15613)
InnoDB: Having two tables in a parent-child
relationship enforced by a foreign key where one table used
ROW_FORMAT=COMPACT and the other used
ROW_FORMAT=REDUNDANT could result in a MySQL
server crash. Note that this problem did not exist prior to
MySQL 5.0.3, when the compact row format for
InnoDB was introduced.
(Bug#15550)
BDB: A DELETE,
INSERT, or UPDATE of a
BDB table could cause the server to crash
where the query contained a subquery using an index read.
(Bug#15536)
Resolution of the argument to the
VALUES() function to a variable
inside a stored routine caused a server crash. The argument must
be a table column.
(Bug#15441)
A left join on a column that having a NULL
value could cause the server to crash.
(Bug#15268)
The output of mysqldump --triggers did not
contain the DEFINER clause in dumped trigger
definitions.
(Bug#15110)
Reversing the order of operands in a WHERE
clause testing a simple equality (such as WHERE t1.col1
= t2.col2) would produce different output from
EXPLAIN.
(Bug#15106)
The output of SHOW TRIGGERS contained
extraneous whitespace.
(Bug#15103)
Creating a trigger caused a server crash if the table or trigger database was not known because no default database had been selected. (Bug#14863)
Column aliases were displayed incorrectly in a
SELECT from a view following an update to a
base table of the view.
(Bug#14861)
A replication slave server could sometimes crash on a
BEFORE UPDATE trigger if the
UPDATE query was not executed in the same
database as the table with the trigger.
(Bug#14614)
SHOW [FULL] COLUMNS and SHOW
INDEX did not function with temporary tables.
(Bug#14387, Bug#15224)
The INFORMATION_SCHEMA.COLUMNS table did not report the size of BINARY or VARBINARY columns. (Bug#14271)
InnoDB: If
FOREIGN_KEY_CHECKS was 0,
InnoDB allowed inconsistent foreign keys to
be created.
(Bug#13778)
The server would not compile under Cygwin. (Bug#13640)
DESCRIBE did not function with temporary
tables.
(Bug#12770)
Set functions could not be aggregated in outer subqueries. (Bug#12762)
A race condition when creating temporary files caused a deadlock
on Windows with threads in Opening tables or
Waiting for table states.
(Bug#12071)
Functionality added or changed:
The syntax for CREATE TRIGGER now includes a
DEFINER clause for specifying which access
privileges to check at trigger invocation time. See
Section 20.1, “CREATE TRIGGER Syntax”, for more information.
Known issue.
If you attempt to replicate from a master server older than
MySQL 5.0.17 to a slave running MySQL 5.0.17 through 5.0.19,
replication of CREATE TRIGGER statements
fails on the slave with a Definer not fully
qualified error. A workaround is to create
triggers on the master using a version-specific comment
embedded in each CREATE TRIGGER statement:
CREATE /*!50017 DEFINER = 'root'@'localhost' */ TRIGGER ... ;
CREATE TRIGGER statements written this way
will replicate to newer slaves, which pick up the
DEFINER clause from the comment and execute
successfully.
Support files for compiling with Visual Studio 6 have been removed. (Bug#15094)
In the latin5_turkish_ci collation, the order
of the characters A WITH CIRCUMFLEX,
I WITH CIRCUMLEX, and U WITH
CIRCUMFLEX was changed. If you have used these
characters in any indexed columns, you should rebuild those
indexes.
(Bug#13421)
Recursion is allowed in stored procedures. Recursive stored functions and triggers still are disallowed. (Bug#10100)
MySQL-*-pro-5.0.17-1.rhel3.i386.rpm, MySQL-*-pro-5.0.17-1.rhel3.ia64.rpm, MySQL-*-pro-5.0.17-1.rhel3.x86_64.rpm
MySQL-*-pro-gpl-5.0.17-1.rhel3.i386.rpm, MySQL-*-pro-gpl-5.0.17-1.rhel3.ia64.rpm, MySQL-*-pro-gpl-5.0.17-1.rhel3.x86_64.rpm
Added a DEFINER column to the
INFORMATION_SCHEMA.TRIGGERS table.
Invoking a stored function or trigger creates a new savepoint level. When the function or trigger finishes, the previous savepoint level is restored.
See also Bug#13825
The maximum key length for InnoDB indexes was
increased from 1024 bytes to 3072 bytes for all builds. (In
MySQL 5.0.15, the length was increased but only for 64-bit
builds.)
MySQL-{Max,client,devel,server,shared,ndb*}-5.0.17-1.i386.rpm
MySQL-*-standard-5.0.17-1.rhel3.i386.rpm, MySQL-*-standard-5.0.17-1.rhel3.ia64.rpm, MySQL-*-standard-5.0.17-1.rhel3.x86_64.rpm
Added the SHOW FUNCTION CODE and
SHOW PROCEDURE CODE statements (available
only for servers that have been built with debugging support).
See Section 12.5.4.19, “SHOW PROCEDURE CODE and SHOW FUNCTION
CODE Syntax”.
Bugs fixed:
MySQL Cluster:
A forced cluster shutdown occurred when the management daemon
was restarted with a changed config.ini
file that added an API or SQL node.
(Bug#15512)
MySQL Cluster: There was a small window for a node failure to occur during a backup without an error being reported. (Bug#15425)
MySQL Cluster:
Using ORDER BY
when
selecting from a table having the primary key on a
primary_key_columnVARCHAR column caused a forced shutdown of
the cluster.
(Bug#15240, Bug#15682, Bug#14828, Bug#15517)
MySQL Cluster: Under certain circumstances, when mysqld connected to a cluster management server, the connection would fail before a node ID could be allocated. (Bug#15215)
MySQL Cluster:
Creating a table with packed keys failed silently.
NDB now supports the
PACK_KEYS option to CREATE
TABLE correctly.
(Bug#14514)
MySQL Cluster:
REPLACE failed when attempting to update a
primary key value in a Cluster table.
(Bug#14007)
Corrected an error-handling problem within stored routines on 64-bit platforms. (Bug#15630)
Slave SQL thread cleanup was not handled properly on Mac OS X when a statement was killed, resulting in a slave crash. (Bug#15623, Bug#15668)
The CREATE test case in
mysql-test-run.pl failed on AIX and SCO.
(Bug#15607)
A bug in mysql-test/t/mysqltest.test caused
that test to fail.
(Bug#15605)
A statement that produced a warning, when fetched via
mysql_stmt_fetch(), did not
produce a warning count according to
mysql_warning_count().
(Bug#15510)
The database-changing code for stored routine handling caused an error-handling problem resulting in a server crash. (Bug#15392)
The original Linux RPM packages (5.0.17-0) had an issue with a
zlib dependency that would result in an error
during an install or upgrade. They were replaced by new
binaries, 5.0.17-1. Here is a list of the new RPM binaries:
MySQL-{Max,client,devel,server,shared,ndb*}-5.0.17-1.i386.rpm
MySQL-*-standard-5.0.17-1.rhel3.i386.rpm, MySQL-*-standard-5.0.17-1.rhel3.ia64.rpm, MySQL-*-standard-5.0.17-1.rhel3.x86_64.rpm
MySQL-*-pro-5.0.17-1.rhel3.i386.rpm, MySQL-*-pro-5.0.17-1.rhel3.ia64.rpm, MySQL-*-pro-5.0.17-1.rhel3.x86_64.rpm
MySQL-*-pro-gpl-5.0.17-1.rhel3.i386.rpm, MySQL-*-pro-gpl-5.0.17-1.rhel3.ia64.rpm, MySQL-*-pro-gpl-5.0.17-1.rhel3.x86_64.rpm
mysqld would not start on Windows 9X operating systems including Windows Me. (Bug#15209)
Queries that select records based on comparisons to a set of column could crash the server if there was one index covering the columns, and a set of other non-covering indexes that taken together cover the columns. (Bug#15204)
Selecting from a view processed with the temptable algorithm caused a server crash if the query cache was enabled. (Bug#15119)
mysql --help was missing a newline after the
version string when the bundled readline
library was not used.
(Bug#15097)
Creating a view that referenced a stored function that selected from a view caused a crash upon selection from the view. (Bug#15096)
The server crashed if compiled without any transactional storage engines. (Bug#15047)
Multiple-table update operations were counting updates and not updated rows. As a result, if a row had several updates it was counted several times for the “rows matched” value but updated only once. (Bug#15028)
Symbolic links did not function properly on Windows platforms. (Bug#14960, Bug#14310)
ROW_COUNT() returned an
incorrect result after EXECUTE of a prepared
statement.
(Bug#14956)
When using an aggregate function to select from a table that has
a multiple-column primary key, adding ORDER
BY to the query could produce an incorrect result.
(Bug#14920)
ANALYZE TABLE did not properly update table
statistics for a MyISAM table with a
FULLTEXT index containing stopwords, so a
subsequent ANALYZE TABLE would not recognize
the table as having already been analyzed.
(Bug#14902)
Creating a view within a stored procedure could result in an out of memory error or a server crash. (Bug#14885)
GROUP BY on a view column did not correctly
account for the possibility that the column could contain
NULL values.
(Bug#14850)
The mysql_stmt_fetch() C API
function could return MYSQL_NO_DATA for a
SELECT COUNT(*) FROM
statement, which should return 1 row.
(Bug#14845)tbl_name WHERE 1 = 0
Selecting from a view used filesort retrieval
when faster retrieval was possible.
(Bug#14816)
InnoDB: A race condition allowed two threads
to drop a hash index simultaneously.
(Bug#14747)
SHOW CREATE TABLE for a view could fail if
the client had locked the view.
(Bug#14726)
The grammar for supporting the DEFINER =
CURRENT_USER clause in CREATE VIEW
and ALTER VIEW was incorrect.
(Bug#14719)
ALTER TABLE ... SET DEFAULT had no effect.
(Bug#14693)
Using ORDER BY on a column from a view, when
also selecting the column normally, and via an alias, caused a
mistaken Column 'x' in order clause is
ambiguous error.
(Bug#14662)
SELECT queries that began with an opening
parenthesis were not being placed in the query cache.
(Bug#14652)
In a stored procedure, continuing (via a condition handler) after a failed variable initialization caused a server crash. (Bug#14643)
A LIMIT-related optimization failed to take
into account that MyISAM table indexes can be
disabled, causing Error 124 when it tried to use such an index.
(Bug#14616)
mysqlhotcopy tried to copy
INFORMATION_SCHEMA tables.
(Bug#14610)
A server crash resulted from the following sequence of events:
1) With no default database selected, create a stored procedure
with the procedure name explicitly qualified with a database
name (CREATE PROCEDURE
). 2) Create another stored procedure with no
database name qualifier. 3) Execute db_name.proc_name
...SHOW PROCEDURE
STATUS.
(Bug#14569)
mysqldump --triggers did not account for the
SQL mode and could dump trigger definitions with missing
whitespace if the IGNORE_SPACE mode was
enabled.
(Bug#14554)
CREATE TABLE could crash the server and write invalid
data into the tbl_name (...)
SELECT ....frm file if the
CREATE TABLE and SELECT
both contained a column with the same name. Also, if a default
value is specified in the column definition, it is now actually
used.
(Bug#14480)
The value of
INFORMATION_SCHEMA.TABLES.TABLE_TYPE
sometimes was reported as empty.
(Bug#14476)
mysql_fix_privilege_tables.sql contained an
erroneous comment that resulted in an error when the file
contents were processed.
(Bug#14469)
Queries on ARCHIVE tables that used the
filesort sorting method could result in a
server crash.
(Bug#14433)
Creating a table containing an ENUM or
SET column from within a stored procedure or
prepared statement caused a server crash later when executing
the procedure or statement.
(Bug#14410)
For a table that had been opened with HANDLER
OPEN, issuing OPTIMIZE TABLE,
ALTER TABLE, or REPAIR
TABLE caused a server crash.
(Bug#14397)
Declaring a stored routine variable to have a
DEFAULT value that referred to a variable of
the same name caused a server crash. (For example:
DECLARE x INT DEFAULT x) Now the
DEFAULT variable is interpreted as referring
to a variable in an outer scope, if there is one.
(Bug#14376)
Complex subqueries could cause improper internal query execution environment initialization and crash the server. (Bug#14342)
Within a stored procedure, inserting with INSERT ...
SELECT into a table with an
AUTO_INCREMENT column did not generate the
correct sequence number.
(Bug#14304)
Space truncation was being ignored when inserting into
BINARY or VARBINARY
columns. Now space truncation results in a warning, or an error
in strict mode.
(Bug#14299)
Casting a FLOAT or DOUBLE
whose value was less than 1.0E-06 to
DECIMAL would yield an inappropriate value.
(Bug#14268)
CAST() did not pad
with 0x00 to a length of expr AS
BINARY(N)N bytes.
(Bug#14255)
Manual manipulation of the mysql.proc table
could cause a server crash. This should not happen, but it is
also not supported that the server will notice such changes.
(Bug#14233)
A UNION of DECIMAL columns
could produce incorrect results.
(Bug#14216)
The maximum value of MAX_ROWS was handled
incorrectly on 64-bit systems.
(Bug#14155)
CHAR(... USING ...) and
CONVERT(CHAR(...) USING ...),
though logically equivalent, could produce different results.
(Bug#14146)
The server could misinterpret old trigger definition files created before MySQL 5.0.17. Now they are interpreted correctly, but this takes more time and the server issues a warning that the trigger should be re-created. (Bug#14090)
Stored functions making use of cursors were not replicated. (Bug#14077)
For a invalid view definition, selecting from the
INFORMATION_SCHEMA.VIEWS table or using
SHOW CREATE VIEW failed, making it difficult
to determine what part of the definition was invalid. Now the
server returns the definition and issues a warning.
(Bug#13818)
InnoDB: Activity on an
InnoDB table caused execution time for
SHOW CREATE TABLE for the table to increase.
(Bug#13762)
Within a stored procedure, exception handling for
UPDATE statements that caused a duplicate-key
error caused a Packets out of order error for
the following statement.
(Bug#13729)
Statements that implicitly commit a transaction are prohibited in stored functions and triggers. An attempt to create a function or trigger containing such a statement produces an error. (The originally reported symptom was that a trigger that dropped another trigger could cause a server crash. That problem was fixed by the patch for Bug#13343.) (Bug#13627)
A newline character in a column alias in a view definition caused an error when selecting from the view later. (Bug#13622)
Invoking a stored procedure within another stored procedure caused the server to crash. (Bug#13549)
Warnings from a previous command were not being reset when fetching from a cursor. (Bug#13524)
In some cases, a left outer join could yield an invalid result
or cause the server to crash, due to a
MYSQL_DATA_TRUNCATED error.
(Bug#13488)
DELETE from CSV tables
reported an incorrect rows-affected value.
(Bug#13406)
A server crash could occur if a prepared statement updated a table for which a trigger existed when the statement was prepared but had been dropped prior to statement execution. (Bug#13399)
RESET MASTER failed to delete log files on
Windows. One consequence of this change is that server opens the
general query and slow log files in shared mode, so now they can
be renamed while the server has them open (something not true in
previous versions).
(Bug#13377)
For binary string data types, mysqldump
--hex-blob produced an illegal output value of
0x rather than ''.
(Bug#13318)
REPAIR TABLES, BACKUP
TABLES, RESTORE TABLES within a
stored procedure caused a server crash.
(Bug#13012)
Implicit versus explicit conversion of float to integer (such as
inserting a float value into an integer column versus using
CAST(... AS UNSIGNED) before
inserting the value) could produce different results. Implicit
and explicit typecasts now are done the same way, with a value
equal to the nearest integer according to the prevailing
rounding mode.
(Bug#12956)
Some comparisons for the IN()
operator were inconsistent with equivalent comparisons for the
= operator.
(Bug#12612)
A server crash could occur if a prepared statement invoked a stored procedure that existed when the statement was prepared but had been dropped and re-created prior to statement execution. (Bug#12329)
make failed when attempting to build MySQL in different directory other than that containing the source. (Bug#11827)
On Windows, the server could crash during shutdown if both replication threads and normal client connection threads were active. (Bug#11796)
Revised table locking to allow proper assessment of view security. (Bug#11555)
Perform character set conversion of constant values whenever possible without data loss. (Bug#10446)
InnoDB: During replication, There was a
failure to record events in the binary log that still occurred
even in the event of a ROLLBACK. For example,
this sequence of commands:
BEGIN; CREATE TEMPORARY TABLE t1 (a INT) ENGINE=INNODB; ROLLBACK; INSERT INTO t1 VALUES (1);
would succeed on the replication master as expected. However,
the INSERT would fail on the slave because
the ROLLBACK would (erroneously) cause the
CREATE TEMPORARY TABLE statement not to be
written to the binlog.
(Bug#7947)
Within a trigger definition the
CURRENT_USER() function
evaluated to the user whose actions caused the trigger to be
activated. Now that triggers have a DEFINER
value, CURRENT_USER() evaluates
to the trigger definer.
(Bug#5861)
mysql ignored the
MYSQL_TCP_PORT environment variable.
(Bug#5792)
Functionality added or changed:
When a date column is set NOT NULL and
contains 0000-00-00, it will be updated for
UPDATE statements that contains
in the
WHERE clause.
(Bug#14186)columnname IS NULL
When trying to run the server with yaSSL enabled, MySQL now
tries to open /dev/random automatically if
/dev/urandom is not available.
(Bug#13164)
MySQL 5.0 now supports character set conversion for
seven additional cp950 characters into the
big5 character set:
0xF9D6, 0xF9D7,
0xF9D8, 0xF9D9,
0xF9DA, 0xF9DB, and
0xF9DC.
If you move data containing these additional characters to an older MySQL installation which does not support them, you may encounter errors.
You must now declare a prefix for an index on any column of any
Geometry class, the only exception being when
the column is a POINT.
(Bug#12267)
The read_only system variable no longer
applies to TEMPORARY tables.
(Bug#4544)
Due to changes in binary logging, the restrictions on which
stored routine creators can be trusted not to create unsafe
routines have been lifted for stored procedures (but not stored
functions). Consequently, the
log_bin_trust_routine_creators system
variable and the corresponding
--log-bin-trust-routine-creators server option
were renamed to
log_bin_trust_function_creators and
--log-bin-trust-function-creators. For backward
compatibility, the old names are recognized but result in a
warning. See Section 19.4, “Binary Logging of Stored Routines and Triggers”.
The CHECK TABLE statement now works for
ARCHIVE tables.
Added a --hexdump option to
mysqlbinlog that displays a hex dump of the
log in comments. This output can be helpful for replication
debugging.
In MySQL 5.0.13, syntax for DEFINER and
SQL SECURITY clauses was added to the
CREATE VIEW and ALTER VIEW
statements, but the clauses had no effect. They now are enabled.
They specify the security context to be used when checking
access privileges at view invocation time. See
Section 21.2, “CREATE VIEW Syntax”, for more information.
The InnoDB, NDB,
BDB, and ARCHIVE storage
engines now support spatial columns. See
Chapter 18, Spatial Extensions.
Added the Compression status variable, which
indicates whether the client connection uses compression in the
client/server protocol.
Bugs fixed:
MySQL Cluster:
Repeated transactions using unique index lookups could cause a
memory leak leading to error 288, Out of index
operations in transaction coordinator.
(Bug#14199)
MySQL Cluster: A memory leak occurred when performing ordered index scans using indexes on columns larger than 32 bytes. This would eventually lead to the forced shutdown of all mysqld server processes used with the cluster. (Bug#13078)
For some stored functions dumped by mysqldump --routines, the function definition could not be reloaded later due to a parsing error. (Bug#14723)
Deletes from a CSV table could cause table
corruption.
(Bug#14672)
Executing REPAIR TABLE, ANALYZE
TABLE, or OPTIMIZE TABLE on a view
for which an underlying table had been dropped caused a server
crash.
(Bug#14540)
mysqlmanager did not start up correctly on Windows 2003. (Bug#14537)
Selecting from a table in both an outer query and a subquery could cause a server crash. (Bug#14482)
ORDER BY DESC within the
GROUP_CONCAT() function was not
honored when used in a view.
(Bug#14466)
The input polling loop for Instance Manager did not sleep properly. Instance Manager used up too much CPU as a result. (Bug#14388)
Indexes for BDB tables were being limited
incorrectly to 255 bytes.
(Bug#14381)
The mysql parser did not properly strip the
delimiter from input lines less than nine characters long. For
example, this could cause USE abc; to result
in an Unknown database: abc; error.
(Bug#14358)
The displayed value for the
CHARACTER_MAXIMUM_LENGTH column in the
INFORMATION_SCHEMA.COLUMNS table was not
adjusted for multi-byte character sets.
(Bug#14290)
The parser did not correctly recognize wildcards in the host
part of the DEFINER user in CREATE
VIEW statements.
(Bug#14256)
Memory corruption and a server crash could be caused by
statements that used a cursor and generated a result set larger
than max_heap_table_size.
(Bug#14210)
A bugfix in MySQL 5.0.15 caused the displayed values for the
CHARACTER_MAXIMUM_LENGTH and
CHARACTER_OCTET_LENGTH columns in the
INFORMATION_SCHEMA.COLUMNS table to be
reversed.
(Bug#14207)
Statements of the form CREATE TABLE ... SELECT
... that created a column with a multi-byte character
set could incorrectly calculate the maximum length of the
column, resulting in a Specified key was too
long error.
(Bug#14139)
Use of WITH ROLLUP PROCEDURE ANALYSE() could
hang the server.
(Bug#14138)
On Windows, the value of character_sets_dir
in SHOW VARIABLES output was displayed
inconsistently (using both “ / ”
and “ \ ” as pathname component
separators).
(Bug#14137)
A comparison with an invalid date (such as WHERE
)
caused any index on col_name > '2005-09-31'col_name not to
be used and a string comparison for each row, resulting in slow
performance.
(Bug#14093)
Subqueries in the FROM clause failed if the
current database was INFORMATION_SCHEMA.
(Bug#14089)
For InnoDB tables, using a column prefix for
a utf8 column in a primary key caused
Cannot find record errors when attempting to
locate records.
(Bug#14056)
Some updatable views could not be updated. (Bug#14027)
A prepared statement that selected from a view processed using the merge algorithm could crash on the second execution. (Bug#14026)
When the DATE_FORMAT() function appeared in
both the SELECT and ORDER
BY clauses of a query but with arguments that differ
by case (i.e. %m and %M), incorrect sorting may have occurred.
(Bug#14016)
TIMEDIFF(),
ADDTIME(), and
STR_TO_DATE() were not reporting
that they could return NULL, so functions
that invoked them might misinterpret their results.
(Bug#14009)
Within stored routines,
REPLACE() could return an empty
string (rather than the original string) when no replacement was
done, and IFNULL() could return
garbage results.
(Bug#13941)
Inserting a new row into an InnoDB table
could cause DATETIME values already stored in
the table to change.
(Bug#13900)
An update of a CSV table could cause a server
crash.
(Bug#13894)
Corrected a parser precedence problem that resulted in an
Unknown column ... in 'on clause' error for
some joins.
(Bug#13832)
Trying to take the logarithm of a negative value is now handled
in the same fashion as division by zero. That is, it produces a
warning when ERROR_FOR_DIVISION_BY_ZERO is
set, and an error in strict mode.
(Bug#13820)
The example configuration files supplied with MySQL
distributions listed the thread_cache_size
variable as thread_cache.
(Bug#13811)
mysqld_safe did not correctly start the
-max version of the server (if it was
present) if the --ledir option was given.
(Bug#13774)
SHOW CREATE TABLE did not display the
CONNECTION string for
FEDERATED tables.
(Bug#13724)
For a MyISAM table originally created in
MySQL 4.1, INSERT DELAYED could cause a
server crash.
(Bug#13707)
The server incorrectly accepted column definitions of the form
DECIMAL(0, for
D)D less than 11.
(Bug#13667)
Trying to create a stored routine with no database selected would crash the server. (Bug#13587, Bug#13514)
Inserts of too-large DECIMAL values were
handled inconsistently (sometimes set to the maximum
DECIMAL value, sometimes set to 0).
(Bug#13573)
TIMESTAMPDIFF() returned an
incorrect result if one argument but not the other was a leap
year and a date was from March or later.
(Bug#13534)
Specifying --default-character-set=cp-932 for
mysqld would cause SQL scripts containing
comments written using that character set to fail with a syntax
error.
(Bug#13487)
Use of in the
col_name =
VALUES(col_name)ON DUPLICATE KEY UPDATE clause of an
INSERT statement failed with an
Column ' error.
(Bug#13392)col_name' in field
list is ambiguous
The default value of query_prealloc_size was
set to 8192, lower than its minimum of 16384. The minimum has
been lowered to 8192.
(Bug#13334)
InnoDB: When dropping and adding a
PRIMARY KEY, if a loose index scan using only
the second part of multiple-part index was chosen, incorrect
keys were created and an endless loop resulted.
(Bug#13293)
mysqladmin and mysqldump would hang on SCO OpenServer. (Bug#13238)
SELECT DISTINCT
CHAR( returned
incorrect results after col_name)SET NAMES utf8.
(Bug#13233)
For queries with nested outer joins, the optimizer could choose join orders that query execution could not handle. The fix is that now the optimizer avoids choosing such join orders. (Bug#13126)
The server did not take character set into account in checking
the width of the mysql.user.Password column.
As a result, it could incorrectly generate long password hashes
even if the column was not long enough to hold them.
(Bug#13064)
The source distribution failed to compile when configured with
the --without-geometry option.
(Bug#12991)
Use of the deprecated --sql-bin-update-same
option caused a server crash.
(Bug#12974)
Maximum values were handled incorrectly for command-line options
of type GET_LL.
(Bug#12925)
mysqldump could not dump views if the
-x option was given.
(Bug#12838)
Two threads that were creating triggers on an
InnoDB table at the same time could deadlock.
(Bug#12739)
InnoDB: Large
innobase_buffer_pool_size and
innobase_log_file_size values were displayed
incorrectly on 64-bit systems.
(Bug#12701)
For LIKE ... ESCAPE, an escape sequence
longer than one character was accepted as valid. Now the
sequence must be empty or one character long. If the
NO_BACKSLASH_ESCAPES SQL mode is enabled, the
sequence must be one character long.
(Bug#12595)
Inserting cp932 strings into a
VARCHAR column caused a server crash rather
than string truncation if the string was longer than the column
definition.
(Bug#12547)
A prepared statement failed with Illegal mix of
collations if the client character set was
utf8 and the statement used a table that had
a character set of latin1.
(Bug#12371)
Using ALTER TABLE to add an index could fail
if the operation ran out of temporary file space. Now it
automatically makes a second attempt that uses a slower method
but no temporary file. In this case, problems that occurred
during the first attempt can be displayed with SHOW
WARNINGS.
(Bug#12166)
mysqlimport now issues a SET
@@character_set_database = binary statement before
loading data so that a file containing mixed character sets
(columns with different character sets) can be loaded properly.
(Bug#12123)
Running OPTIMIZE TABLE and other
data-updating statements concurrently on an
InnoDB table could cause a crash or the
following warnings in the error log: Warning: Found
locks from different threads in write: enter
write_lock, Warning: Found locks from
different threads in write: start of release lock.
(Bug#11704)
LOAD DATA INFILE would not accept the same
character for both the ESCAPED BY and the
ENCLOSED BY clauses.
(Bug#11203)
The value of Last_query_cost was not updated
for queries served from the query cache.
(Bug#10303)
Starting mysqld with the
--skip-innodb and
--default-storage-engine=innodb (or
--default-table-type=innodb caused a server
crash.
(Bug#9815)
The --exit-info=65536 option conflicted with
--temp-pool and caused problems with the
server's use of temporary files. Now
--temp-pool is ignored if
--exit-info=65536 is specified.
(Bug#9551)
For a user that has the SELECT privilege on a
view, the server erroneously was also requiring the user to have
the EXECUTE privilege at view execution time
for stored functions used in the view definition.
(Bug#9505)
Where one stored procedure called another stored procedure: If
the second stored procedure generated an exception, the
exception was not caught by the calling stored procedure. For
example, if stored procedure A used an
EXIT statement to handle an exception,
subsequent statements in A would be executed
regardless when A was called by another
stored procedure B, even if an exception that
should have been handled by the EXIT was
generated in A.
(Bug#7049)
On Windows, the server was not ignoring hidden or system directories that Windows may have created in the data directory, and would treat them as available databases. (Bug#4375)
Functionality added or changed:
Incompatible Change:
For BINARY columns, the pad value and how it
is handled has changed. The pad value for inserts now is
0x00 rather than space, and there is no
stripping of the pad value for selects. For details, see
Section 10.4.2, “The BINARY and VARBINARY Types”.
Incompatible Change:
The CHAR() function now returns
a binary string rather than a string in the connection character
set. An optional USING
clause may be used
to produce a result in a specific character set instead. Also,
arguments larger than 256 produce multiple characters. They are
no longer interpreted modulo 256 to produce a single character
each. These changes may cause some incompatibilities, as noted
in Section 2.4.17.2, “Upgrading from MySQL 4.1 to 5.0”.
charset
MySQL Cluster: The ndb_mgm client now reports node startup phases automatically. (Bug#16197)
MySQL Cluster:
A new “smart” node allocation algorithm means that
it is no longer necessary to use sequential IDs for cluster
nodes, and that nodes not explicitly assigned IDs should now
have IDs allocated automatically in most cases. In practical
terms, this means that it is now possible to assign a set of
node IDs such as 1, 2,
4, 5 without an error
being generated due to the missing 3.
(Bug#13009)
MySQL Cluster: A number of new or improved error messages have been implemented in this release in order to provide better and more accurate diagnostic information regarding cluster configuration issues and problems. (Bug#12786, Bug#11749, Bug#13197, Bug#11739, Bug#12044)
The following statements now cause an implicit
COMMIT:
CREATE VIEW
ALTER VIEW
DROP VIEW
CREATE TRIGGER
DROP TRIGGER
CREATE USER
RENAME USER
DROP USER
Added the --tz-utc option to
mysqldump. This option adds SET
TIME_ZONE='+00:00' to the dump file so that
TIMESTAMP columns can be dumped and reloaded
between servers in different time zones and protected from
changes due to daylight saving time.
(Bug#13052)
When executing single-table UPDATE or
DELETE queries containing an ORDER
BY ... LIMIT clause, but
not having any NWHERE clause, MySQL can now
take advantage of an index to read the first
N rows in the ordering specified in
the query. If an index is used, only the first
N records will be read, as opposed to
scanning the entire table.
(Bug#12915)
The MySQL-server RPM now explicitly assigns
the mysql system user to the
mysql user group during the postinstallation
process. This corrects an issue with upgrading the server on
some Linux distributions whereby a previously existing
mysql user was not changed to the
mysql group, resulting in wrong groups for
files created following the installation.
(Bug#12823)
CREATE VIEW
The maximum key length for InnoDB indexes was
increased from 1024 bytes to 3072 bytes for 64-bit builds.
DROP USER
DROP VIEW
DROP TRIGGER
CREATE USER
ALTER VIEW
CREATE TRIGGER
When declaring a local variable (or parameter) named
password or name, and
setting it with SET (for example,
SET password = ''), the new error message
ERROR 42000: Variable 'nnn' must be quoted with `...`,
or renamed is returned (where 'nnn' is 'password' or
'names'). This means there is a syntax conflict with special
sentences like SET PASSWORD = PASSWORD(...)
(for setting a user's password) and set names
default (for setting charset and collation).
This must be resolved either by quoting the variable name:
SET `password` = ..., which will set the
local variable `password`, or by renaming the
variable to something else (if setting the user's password is
the desired effect).
RENAME USER
Bugs fixed:
MySQL Cluster:
The perror utility included with the
MySQL-Server RPM did not provide support for
the --ndb option. It now supports this option,
and so can be used to obtain error message text for MySQL
Cluster error codes.
(Bug#13740)
MySQL Cluster:
Placing multiple [tcp default] sections in
the cluster's config.ini file crashed
ndb_mgmd. (The process now exits gracefully
in such cases, with an appropriate error message.)
(Bug#13611)
MySQL Cluster: ndb_mgmd allowed a node to be stopped or restarted while another node was still starting up, which could crash the cluster. It should now not be possible to issue a node stop or restart while a different node is still restarting, and the cluster management client should issue an error when such an attempt is made. (Bug#13461)
MySQL Cluster:
Trying to run ndbd as system
root when connecting to a
mysqld process running as the
mysql system user via SHM caused the
ndbd process to crash.
(ndbd should now exit gracefully with an
appropriate error message instead.)
(Bug#9249)
Tests containing SHOW TABLE STATUS or
INFORMATION_SCHEMA failed on opnsrv6c.
(Bug#14064, Bug#14065)
mysqldump could not dump views. (Bug#14061)
mysqlcheck --all-databases
--analyze --optimize
failed because it also tried to analyze and optimize
the INFORMATION_SCHEMA tables which it can't.
(Bug#13783)
Character set conversion was not being done for
FIND_IN_SET().
(Bug#13751)
On BSD systems, the system crypt() call could
return an error for some salt values. The error was not handled,
resulting in a server crash.
(Bug#13619)
When calling a stored procedure with the syntax CALL
and no default schema selected, schema.procedurename
ERROR
1046 was displayed after the procedure returned.
(Bug#13616)
A column in the ON condition of a join that
referenced a table in a nested join could not be resolved if the
nested join was a right join.
(Bug#13597)
The server could over-allocate memory when performing a
FULLTEXT search for stopwords only.
(Bug#13582)
CREATE DEFINER=... VIEW ... caused the server
to crash when run with --skip-grant-tables.
(Bug#13504)
InnoDB: Queries that were executed using an
index_merge union or intersection could
produce incorrect results if the underlying table used the
InnoDB storage engine and had a primary key
containing VARCHAR members.
(Bug#13484)
A qualified reference to a view column in the
HAVING clause could not be resolved.
(Bug#13410)
CAST(1E+300 TO SIGNED INT)
produced an incorrect result on little-endian machines.
(Bug#13344)
Queries that use indexes in normal SELECT
statements may cause range scans in VIEWs.
(Bug#13327)
SELECT * INTO OUTFILE ... FROM
INFORMATION_SCHEMA.schemata failed with an
Access denied error.
(Bug#13202)
mysqldump --triggers did not quote
identifiers properly if the --compatible option
was given, so the dump output could not be reloaded.
(Bug#13146)
A table or view named Ç (C-cedilla) couldn't be dropped. (Bug#13145)
For XA transaction IDs (
), uniqueness is supposed to be assessed based on
gtrid.bqual.formatID
gtrid and
bqual. MySQL was also including
formatID in the uniqueness check.
(Bug#13143)
Trying to create a view dynamically using a prepared statement within a stored procedure failed with error 1295. (Bug#13095)
comp_err did not detect when multiple error messages for a language were given for an error symbol. (Bug#13071)
If special characters such as '_' ,
'%', or the escape character were included
within the prefix of a column index, LIKE
pattern matching on the indexed column did not return the
correct result.
(Bug#13046, Bug#13919)
Using an undefined variable in an IF or
SET clause inside a stored routine produced
an incorrect unknown column ... in 'order
clause' error message.
(Bug#13037)
With --log-slave-updates
Exec_master_log_pos of SQL thread lagged IO
(Bug#13023)
SHOW CREATE TABLE did not display any
FOREIGN KEY clauses if a temporary file could
not be created. Now SHOW CREATE TABLE
displays an error message in an SQL comment if this occurs.
(Bug#13002)
Local (non-XA) and XA transactions are supposed to be mutually exclusive within a given client connection, but this prohibition was not always enforced. (Bug#12935)
Server crashed during a SELECT statement,
writing a message like this to the error log:
InnoDB: Error: MySQL is trying to perform a SELECT InnoDB: but it has not locked any tables in ::external_lock()!
An UPDATE query using a join would be
executed incorrectly on a replication slave.
(Bug#12618)
An expression in an ORDER BY clause failed
with Unknown column
' if the expression referred to a column alias.
(Bug#11694)col_name' in 'order
clause'
Issuing STOP SLAVE after having acquired a
global read lock with FLUSH TABLES WITH READ
LOCK caused a deadlock. Now STOP
SLAVE is generates an error in such circumstances.
(Bug#10942)
Corrected a memory-copying problem for big5
values when using icc compiler on Linux IA-64
systems.
(Bug#10836)
The --interactive-timeout and
--slave-net-timeout options for
mysqld were not being obeyed on Mac OS X and
other BSD-based platforms.
(Bug#8731)
Queries of the form (SELECT ...) ORDER BY ...
were being treated as a UNION. This
improperly resulted in only distinct values being returned
(because UNION by default eliminates
duplicate results). Also, references to column aliases in
ORDER BY clauses following parenthesized
SELECT statements were not resolved properly.
(Bug#7672)
Character set file parsing during
mysql_real_connect() read past
the end of a memory buffer.
(Bug#6413)
Functionality added or changed:
Multiple-table UPDATE and
DELETE statements that do not affect any rows
are now written to the binary log and will replicate.
(Bug#13348, Bug#12844)
Range scans can now be performed for queries on VIEWs such as
column IN (<constants>) and
column BETWEEN ConstantA AND ConstantB.
(Bug#13317)
The limit of 255 characters on the input buffer for mysql on Windows has been lifted. The exact limit depends on what the system allows, but can be up to 64K characters. A typical limit is 16K characters. (Bug#12929)
Added the myisam_stats_method, which controls
whether NULL values in indexes are considered
the same or different when collecting statistics for
MyISAM tables. This influences the query
optimizer as described in
Section 7.4.7, “MyISAM Index Statistics Collection”.
(Bug#12232)
The CHAR() function now takes
into account the character set and collation given by the
character_set_connection and
collation_connection system variables. For an
argument n to
CHAR(), the result is
n mod 256 for single-byte character
sets. For multi-byte character sets,
n must be a valid code point in the
character set. Also, the result string from
CHAR() is checked for
well-formedness. For invalid arguments, or a result that is not
well-formed, MySQL generates a warning (or, in strict SQL mode,
an error).
(Bug#10504)
Re-enabled the --delayed-inserts option for
mysqldump, which now checks for each table
dumped whether its storage engine supports
DELAYED inserts.
(Bug#7815)
RENAME TABLE now works for views as well, as
long as you do not try to rename a view into a different
database.
(Bug#5508)
Configure-time checking for the availability of multi-byte
macros and functions in the bundled readline
library. This improves handling of multi-byte character sets in
the mysql client.
(Bug#3982)
When an InnoDB foreign key constraint is
violated, the error message now indicates which table, column,
and constraint names are involved.
(Bug#3443)
Bugs fixed:
MySQL Cluster:
A trigger updating the value of an
AUTO_INCREMENT column in an
NDB table would insert an error code rather
than the expected value into the column.
(Bug#13961)
MySQL Cluster: If ndb_restore could not find a free mysqld process, it crashed. (Bug#13512)
MySQL Cluster: Adding an index to a table with a large number of columns (more then 100) crashed the storage node. (Bug#13316)
MySQL Cluster:
BIT columns and following columns in
NDB tables were corrupt when dumped by
mysqldump.
(Bug#13152)
MySQL Cluster:
Queries on NDB tables that were executed
using index_merge could produce incorrect
results.
(Bug#13081)
MySQL Cluster:
Receipt of several ENTER SINGLE USER MODE
commands by multiple ndb_mgmd processes
within a short period of time resulted in cluster shutdown.
(Bug#13053)
MySQL Cluster: Multiple ndb_mgmd processes in a cluster did not know each other's IP addresses. (Bug#12037)
MySQL Cluster:
With two mgmd processes in a cluster,
ndb_mgm output for SHOW
would display the same IP address for both processes, even when
they were on different hosts.
(Bug#11595)
MySQL Cluster:
LOAD DATA INFILE with a large data file
failed.
(Bug#10694)
MySQL Cluster:
When deleting a great many (tens of thousands of) rows at once
from an NDB table, an improperly dereferenced
pointer could cause the mysqld process to
crash.
(Bug#9282)
Certain joins using Range checked for each
record in the query execution plan could cause the
server to crash.
(Bug#24776)
Joins nested under NATURAL or
USING joins were sometimes not initialized
properly, causing a server crash.
(Bug#13545)
After running configure with the
--with-embedded-privilege-control option, the
embedded server failed to build.
(Bug#13501)
The optimizer chose a less efficient execution plan for
than for col_name BETWEEN
const AND
const
, even though the two
expressions are logically equivalent. Now the optimizer can use
the col_name =
constref access method for both expressions.
(Bug#13455)
Locking a view with the query cache enabled and
query_cache_wlock_invalidate enabled could
cause a server crash.
(Bug#13424)
A HAVING clause that references an
unqualified view column name could crash the server.
(Bug#13411)
The --skip-innodb-doublewrite option disables
use of the InnoDB doublewrite buffer.
However, having this option in effect when creating a new MySQL
installation prevented the buffer from even being created,
resulting in a server crash later.
(Bug#13367)
Calling the FORMAT() function
with a DECIMAL column value caused a server
crash when the value was NULL.
(Bug#13361)
Comparisons involving row constructors containing constants could cause a server crash. (Bug#13356)
Aggregate functions sometimes incorrectly were allowed in the
WHERE clause of UPDATE and
DELETE statements.
(Bug#13180)
NATURAL joins and joins with
USING against a view could return
NULL rather than the correct value.
(Bug#13127)
For queries with DISTINCT and WITH
ROLLUP, the DISTINCT should be
applied after the rollup operation, but was not always.
(Bug#12887)
It was possible to create a view that executed a stored function
for which you did not have the EXECUTE
privilege.
(Bug#12812)
Shared-memory connections were not working on Windows. (Bug#12723)
The server was not rejecting
FLOAT(
or
M,D)DOUBLE(
columns specifications when M,D)M was
less than D.
(Bug#12694)
CHECKSUM TABLE locked
InnoDB tables and did not use a consistent
read.
(Bug#12669)
Incorrect creation of DECIMAL local variables
in a stored procedure could cause a server crash.
(Bug#12589)
For queries for which the optimizer determined a join type of
“Range checked for each record” (as shown by
EXPLAIN, the query sometimes could cause a
server crash, depending on the data distribution.
(Bug#12291)
After running configure with the
--without-server option, the distribution
failed to build.
(Bug#11680, Bug#13550)
Use of a user-defined function within the
HAVING clause of a query resulted in an
Unknown column error.
(Bug#11553)
The server crashed when processing a view that invoked the
CONVERT_TZ() function.
(Bug#11416)
When SELECT ... FOR UPDATE or SELECT
... LOCK IN SHARE MODE for an
InnoDB table were executed from within a
stored function or a trigger, they were converted to a
non-locking consistent read.
(Bug#11238)
The --replicate-rewrite-db and
--replicate-do-table options did not work for
statements in which tables were aliased to names other than
those listed by the options.
(Bug#11139)
Queries against a MERGE table that has a
composite index could produce incorrect results.
(Bug#9112)
MySQL programs in binary distributions for Solaris 8/9/10 x86 systems would not run on Pentium III machines. (Bug#6772)
Nested handlers within stored procedures didn't work. (Bug#6127)
Functionality added or changed:
OPTIMIZE TABLE and HANDLER
now are prohibited in stored procedures and functions and in
triggers.
(Bug#12953, Bug#12995)
The LEAST() and
GREATEST() functions used to
return NULL only if all arguments were
NULL. Now they return NULL
if any argument is NULL, the same as Oracle.
(Bug#12791)
InnoDB: The TRUNCATE TABLE
statement for InnoDB tables always resets the
counter for an AUTO_INCREMENT column now,
regardless of whether there is a foreign key constraint on the
table. (Beginning with 5.0.3, TRUNCATE TABLE
reset the counter, but only if there was no such constraint.)
(Bug#11946)
Reorder network startup to come after all other initialization, particularly storage engine startup which can take a long time. This also prevents MySQL from being run on a privileged port (any port under 1024) unless run as the root user. (Bug#11707)
The restriction on the use of PREPARE,
EXECUTE, and DEALLOCATE
PREPARE within stored procedures was lifted. The
restriction still applies to stored functions and triggers.
(Bug#10975, Bug#10605)
See also Bug#7115
A new command line argument was added to mysqld to ignore client character set information sent during handshake, and use server side settings instead, to reproduce 4.0 behavior :
mysqld --skip-character-set-client-handshake
(Bug#9948)
Added a --routines option for
mysqldump that enables dumping of stored
routines.
(Bug#9056)
RAND() no longer allows
non-constant initializers. (Prior to MySQL 5.0.13, the effect of
non-constant initializers is undefined.)
(Bug#6172)
Better detection of connection timeout for replication servers
on Windows allows elimination of extraneous Lost
connection errors in the error log.
(Bug#5588)
The syntax for CREATE VIEW and ALTER
VIEW statements now includes
DEFINER and SQL SECURITY
clauses for specifying the security context to be used when
checking access privileges at view invocation time. (The syntax
is present in 5.0.13, but these clauses have no effect until
5.0.16.) See Section 21.2, “CREATE VIEW Syntax”, for more
information.
The --hex-dump option for
mysqldump now also applies to
BIT columns.
Two new collations have been added for Esperanto:
utf8_esperanto_ci and
ucs2_esperanto_ci.
The Windows binary packages are now compiled with the Microsoft Visual Studio 2003 compiler instead of Microsoft Visual C++ 6.0.
The connection string for FEDERATED tables
now is specified using a CONNECTION table
option rather than a COMMENT table option.
The binaries compiled with the Intel icc compiler are now built using icc 9.0 instead of icc 8.1. You will have to install new versions of the Intel icc runtime libraries, which are available from here: ( http://dev.mysql.com/downloads/os-linux.html)
Bugs fixed:
Incompatible Change:
A lock wait timeout caused InnoDB to roll
back the entire current transaction. Now it rolls back only the
most recent SQL statement.
(Bug#12308)
MySQL Cluster:
The cluster management client START BACKUP
command could be interrupted by a SHOW
command.
(Bug#13054)
MySQL Cluster: A cluster shutdown following the crash of a data node failed to terminate any remaining node processes, even though ndb_mgm showed the shutdown request as having been completed. (Bug#9996, Bug#10938, Bug#11623)
MySQL Cluster:
The average row size for Cluster tables was calculated
incorrectly. This affected the values shown for the
Data_length and
Avg_row_length columns in the output
generated by SHOW TABLE STATUS as well as the
values for the data_length and
data_length/table_rows columns shown in the
TABLES table of the
INFORMATION_SCHEMA database with respect to
Cluster tables.
Tables using storage engines other than NDB
were not affected by this bug.
(Bug#9896)
Local variables in stored routines were not always initialized correctly. (Bug#13133)
The FEDERATED storage engine does not support
ALTER TABLE, but no appropriate error message
was issued.
(Bug#13108)
Columns named in the USING() clause of
JOIN ... USING() were incorrectly resolved in
case-sensitive fashion.
(Bug#13067)
For a server compiled with yaSSL, clients that used MySQL Connector/J were not able to establish SSH connections. (Bug#13029)
When used in view definitions,
DAYNAME(,
expr)DAYOFWEEK(,
expr)WEEKDAY(
were incorrectly treated as though the expression was
expr)TO_DAYS(
or
expr)TO_DAYS(TO_DAYS(.
(Bug#13000)expr))
Using AS to rename a column selected from a
view in a subquery made it not possible to refer to that column
in the outer query.
(Bug#12993)
Using an INOUT parameter with a
DECIMAL data type in a stored procedure
caused a server crash.
(Bug#12979)
SELECT ... JOIN ... ON ... JOIN ... USING
caused a server crash.
(Bug#12977)
A bug introduced in MySQL 5.0.12 caused SHOW TABLE
STATUS to display an Auto_increment
value of 0 for InnoDB tables.
(Bug#12973)
On HP-UX 11.x (PA-RISC), the -L option caused
mysqlimport to crash.
(Bug#12958)
InnoDB: A consistent read could return
inconsistent results due to a bug introduced in MySQL 5.0.5.
(Bug#12947)
Incorrect implicit nesting of joins caused the parser to fail on
queries of the form SELECT ... FROM t1 JOIN t2 JOIN t3
ON t1.t1col = t3.t3col with an Unknown column
't1.t1col' in 'on clause' error.
(Bug#12943)
Incorrect results could be returned from a view processed using a temporary table. (Bug#12941)
Multiplying a DECIMAL value within a loop in
a stored routine could incorrectly result in a value of
NULL.
(Bug#12938)
Using GROUP BY when selecting from a view in
some cases could cause incorrect results to be returned.
(Bug#12922)
The counters for the Key_read_requests,
Key_reads,
Key_write_requests, and
Key_writes status variables were changed from
unsigned long to unsigned
longlong to accommodate larger values before the
variables roll over and restart from 0.
(Bug#12920)
mysql and mysqldump were
ignoring the --defaults-extra-file option.
(Bug#12917)
SHOW FIELDS FROM
caused error 1046 when no default schema was set.
(Bug#12905)schemaname.viewname
UNION [DISTINCT] was not removing all
duplicates for multi-byte character values.
(Bug#12891)
A column that can be NULL was not handled
properly for WITH ROLLUP in a subquery or
view.
(Bug#12885)
Within a transaction, the following statements now cause an
implicit commit: CREATE FUNCTION,
DROP FUNCTION, DROP
PROCEDURE, ALTER FUNCTION,
ALTER PROCEDURE, CREATE
PROCEDURE. This corrects a problem where these
statements followed by ROLLBACK might not be
replicated properly.
(Bug#12870)
GROUP_CONCAT() ignored an empty
string if it was the first value to occur in the result.
(Bug#12863)
If a client has opened an InnoDB table for
which the .ibd file is missing,
InnoDB would not honor a DROP
TABLE statement for the table.
(Bug#12852)
Within a stored procedure, a server crash was caused by
assigning to a VARCHAR INOUT parameter the
value of an expression that included the variable itself. (For
example, SET c = c.)
(Bug#12849)
The server crashed when one thread resized the query cache while another thread was using it. (Bug#12848)
A concurrency problem for CREATE ... SELECT
could cause a server crash.
(Bug#12845)
DO IFNULL(NULL, NULL) and SELECT
CAST(IFNULL(NULL, NULL) AS DECIMAL) caused a server
crash.
(Bug#12841)
After changing the character set with SET CHARACTER
SET, the result of the
GROUP_CONCAT() function was not
converted to the proper character set.
(Bug#12829)
The Windows installer made a change to one of the
mysql.proc table files, causing stored
routine functionality to be compromised. The Windows installer
now never overwrites files in the MySQL data directory. During
an upgrade from one version to another, a file in the data
directory will not be overwritten even if it has not been
modified since it was put there by an older installer.
If you have already lost access to stored routines because of this problem, you can get them back using the following procedure:
Stop the server.
In the mysql\data directory under your
MySQL installation directory, and replace the
proc.frm file with corresponding file
from the version of MySQL that you were using before you
upgraded.
Start the server
Start the mysql command-line client (use
the root account or another account that
has full database privileges) and execute the
mysql_fix_privilege_tables.sql script
that upgrades the grant tables to the current structure.
Instructions for doing this are given in
Section 4.4.5, “mysql_fix_privilege_tables — Upgrade MySQL System Tables”.
After this, all stored routine functionality should work. (Bug#12820)
Queries with subqueries, where the inner subquery uses the
range or index_merge
access method, could return incorrect results.
(Bug#12720)
The server failed to disallow SET AUTOCOMMIT
in stored functions and triggers. It is allowed to change the
value of AUTOCOMMIT in stored procedures, but
a runtime error might occur if the procedure is invoked from a
stored function or trigger.
(Bug#12712)
Simultaneous execution of DML statements and CREATE
TRIGGER or DROP TRIGGER statements
on the same table could cause server crashes or errors.
(Bug#12704)
Performing an IS NULL check on
the MIN() or
MAX() of an indexed column in a
complex query could produce incorrect results.
(Bug#12695)
Use of PREPARE and EXECUTE
with a statement that selected from a view in a subquery could
cause a server crash.
(Bug#12651)
If the binary log is enabled, execution of a stored procedure that modifies table data and uses user variables could cause a server crash or incorrect information to be written to the binary log. (Bug#12637)
The LIKE ... ESCAPE syntax produced invalid
results when escape character was larger than one byte.
(Bug#12611)
mysqldump did not dump triggers properly. (Bug#12597)
InnoDB: Limit recursion depth to 200 in
deadlock detection to avoid running out of stack space.
(Bug#12588)
The mysql.server script contained an
incorrect path for the libexec directory.
(Bug#12550)
A UNION of long utf8
VARCHAR columns was sometimes returned as a
column with a LONGTEXT data type rather than
VARCHAR. This could prevent such queries from
working at all if selected into a MEMORY
table because the MEMORY storage engine does
not support the TEXT data types.
(Bug#12537)
A client connection thread cleanup problem caused the server to crash when closing the connection if the binary log was enabled. (Bug#12517)
Use of the mysql client
HELP command from within a stored routine
caused a “packets out of order” error and a lost
connection. Now HELP is detected and
disallowed within stored routines.
(Bug#12490)
The SYSDATE() function now
returns the time at which it was invoked. In particular, within
a stored routine or trigger,
SYSDATE() returns the time at
which it executes, not the time at which the stored routine or
triggering statement began to execute.
(Bug#12480)
CREATE VIEW inside a stored procedure caused
a server crash if the table underlying the view had been
deleted.
(Bug#12468)
Deadlock occurred when several account management statements
were run (particularly between FLUSH
PRIVILEGES/SET PASSWORD and
GRANT/REVOKE statements).
(Bug#12423)
InnoDB was too permissive with LOCK
TABLE ... READ LOCAL and allowed new inserts into the
table. Now READ LOCAL is equivalent to
READ for InnoDB. This will
cause slightly more locking in mysqldump, but
makes InnoDB table dumps consistent with
MyISAM table dumps.
(Bug#12410)
If a stored function invoked from a SELECT
failed with an error, it could cause the client connection to be
dropped. Now such errors generate warnings instead so as not to
interrupt the SELECT.
(Bug#12379)
The value of character_set_results could be
set to NULL, but returned the string
"NULL" when retrieved.
(Bug#12363)
On Windows, the server was preventing tables from being created
if the table name was a prefix of a forbidden name. For example,
nul is a forbidden name because it's the same
as a Windows device name, but a table with the name of
n or nu was being
forbidden as well.
(Bug#12325)
ALTER TABLE ... DISCARD TABLESPACE for
non-InnoDB table caused the client to lose
the connection. (The server was not returning the error
properly.)
(Bug#12207)
Outer join elimination was erroneously applied for some queries
that used a NOT BETWEEN condition, an
IN(
condition, or an value_list)IF() condition.
(Bug#12102, Bug#12101)
Foreign keys were not properly enforced in
TEMPORARY tables. Foreign keys now are
disallowed in TEMPORARY tables.
(Bug#12084)
When using a cursor, a SELECT statement that
uses a GROUP BY clause could return incorrect
results.
(Bug#11904)
Replication of LOAD DATA INFILE failed
between systems using different pathname syntax (such as
delimiter characters).
(Bug#11815)
The character_set_system system variable
could not be selected with SELECT
@@character_set_system.
(Bug#11775)
A memory leak resulting from repeated SELECT ...
INTO statements inside a stored procedure could cause
the server to crash.
(Bug#11333)
Use of yaSSL for a secure client connection caused LOAD
DATA LOCAL INFILE to fail.
(Bug#11286)
mysqld_multi now quotes arguments on command lines that it constructs to avoid problems with arguments that contain shell metacharacters. (Bug#11280)
The server allowed privileges to be granted explicitly for the
INFORMATION_SCHEMA database. Such privileges
are always implicit and should not be grantable.
(Bug#10734)
SHOW CREATE PROCEDURE and SHOW
CREATE FUNCTION no longer qualify the routine name
with the database name, for consistency with the behavior of
SHOW CREATE TABLE.
(Bug#10362)
The server incorrectly generated an Unknown
table error message when for attempts to drop tables
in the INFORMATION_SCHEMA database. Now it
issues an Access denied message.
(Bug#9846)
Within a stored procedure, fetching a large number of rows in a
loop using a cursor could result in a server crash or an out of
memory error. Also, values inserted within a stored procedure
using a cursor were interpreted as latin1
even if character set variables had been set to a different
character set.
(Bug#9819, Bug#6513)
The server allowed TEMPORARY tables and
stored procedures to be created in the
INFORMATION_SCHEMA database.
(Bug#9683, Bug#10708)
SHOW FIELDS truncated the
TYPE column to 40 characters.
(Bug#7142)
See also Bug#12817
A view-creation statement of the form CREATE VIEW
failed with a
name AS SELECT ... FROM
tbl_name AS
nameNot unique table/alias:
' error.
(Bug#6808)name'
myisampack did not properly pack
BLOB values larger than
224 bytes.
(Bug#4214)
Stop the server.
Start the server
In the mysql\data directory under your
MySQL installation directory, and replace the
proc.frm file with corresponding file from
the version of MySQL that you were using before you upgraded.
Start the mysql command-line client (use the
root account or another account that has full
database privileges) and execute the
mysql_fix_privilege_tables.sql script that
upgrades the grant tables to the current structure. Instructions
for doing this are given in
Section 4.4.5, “mysql_fix_privilege_tables — Upgrade MySQL System Tables”.
Functionality added or changed:
Incompatible Change:
Beginning with MySQL 5.0.12, natural joins and joins with
USING, including outer join variants, are
processed according to the SQL:2003 standard. The changes
include elimination of redundant output columns for
NATURAL joins and joins specified with a
USING clause and proper ordering of output
columns. The precedence of the comma operator also now is lower
compared to JOIN.
In addition, a Duplicate column name
error no longer occurs when selecting from a view
defined as SELECT * from a join that uses a
USING clause on tables that have a common
column name.
These changes make MySQL more compliant with standard SQL.
However, they can result in different output columns for some
joins. Also, some queries that appeared to work correctly prior
to 5.0.12 must be rewritten to comply with the standard. For
details about the scope of the changes and examples that show
what query rewrites are necessary, see Section 12.2.7.1, “JOIN Syntax”.
(Bug#6495, Bug#6136, Bug#10972, Bug#9978, Bug#10428, Bug#10646, Bug#6276, Bug#6489, Bug#6558, Bug#9067, Bug#4789, Bug#12065, Bug#13551)
MySQL Cluster:
The parsing of the CLUSTERLOG command by
ndb_mgm was corrected to allow multiple
items.
(Bug#12833)
A query of the form SHOW TABLE STATUS FROM
would crash
the server.
(Bug#12636)db_name WHERE name IN
(select_query)
Using DESCRIBE on a view after renaming a
column in one of the view's base tables caused the server to
crash.
(Bug#12533)
If a thread (connection) has tables locked, the query cache is switched off for that thread. This prevents invalid results where the locking thread inserts values between a second thread connecting and selecting from the table. (Bug#12385)
Interleaved execution of stored procedures and functions could be written to the binary log incorrectly, causing replication slaves to get out of sync. (Bug#12335)
Calls to stored procedures were written to the binary log even within transactions that were rolled back, causing them to be executed on replication slaves. (Bug#12334)
SHOW TABLE STATUS FROM INFORMATION_SCHEMA now
sorts output by table name the same as it does for other
databases.
(Bug#12315)
It is no longer possible to issue FLUSH
commands from within stored functions or triggers. See
Section F.1, “Restrictions on Stored Routines and Triggers”, for details.
(Bug#12280, Bug#12307)
SHOW OPEN TABLES now supports
FROM and LIKE clauses.
(Bug#12183)
Recursive triggers are detected and disallowed. Also, within a stored function or trigger, it is not allowable to modify a table that is already being used (for reading or writing) by the statement that invoked the function or trigger. (Bug#11896, Bug#12644)
INFORMATION_SCHEMA objects are now reported
as a SYSTEM VIEW table type.
(Bug#11711)
The stability of cursors when used with
InnoDB tables was greatly improved.
(Bug#11309, Bug#11832, Bug#12243)
Trying to drop the default keycache by setting
@@global.key_buffer_size to zero now returns
a warning that the default keycache cannot be dropped.
(Bug#10473)
SHOW ENGINE INNODB STATUS now can display
longer query strings.
(Bug#7819)
Added the SLEEP() function,
which pauses for the number of seconds given by its argument.
(Bug#6760)
SHOW TABLE STATUS for a view now shows
VIEW in uppercase, consistent with
SHOW TABLES and
INFORMATION_SCHEMA.
(Bug#5501)
Bugs fixed:
MySQL Cluster: When it could not copy a fragment, ndbd exited without printing a message about the condition to the error log. Now the message is written. (Bug#12900)
MySQL Cluster: When a Disk is full condition occurred, ndbd exited without reporting this condition in the error log. (Bug#12716)
MySQL Cluster: Cluster failed to take character set data into account when recomputing hashes (and thus could not locate records for updating or deletion) following a configuration change and node restart. (Bug#12220)
MySQL Cluster:
An ALTER TABLE command caused loss of data
stored prior to the issuing of the command.
(Bug#12118)
MySQL Cluster:
Invalid values in config.ini caused
ndb_mgmd to crash.
(Bug#12043)
MySQL Cluster: When a schema was detected to be corrupt, ndb neglected to close it, resulting in a file already open error if the schema was opened again later. written. (Bug#12027)
MySQL Cluster: Improved error messages related to filesystem issues. (Bug#11218)
MySQL Cluster: The wrong error message was displayed when the cluster management server port was closed while a mysqld process was trying to connect. (Bug#10950)
An optimizer estimate of zero rows for a non-empty
InnoDB table used in a left or right join
could cause incomplete rollback for the table.
(Bug#12779)
mysql_fix_privilege_tables.sql was missing
a comma, causing a syntax error when executed.
(Bug#12705)
Invocations of the SLEEP()
function incorrectly could get optimized away for statements in
which it occurs. Statements containing
SLEEP() incorrectly could be
stored in the query cache.
(Bug#12689)
Improper use of loose index scan in InnoDB
sometimes caused incorrect query results.
(Bug#12672)
A SELECT DISTINCT query with a constant value
for one of the columns would return only a single row.
(Bug#12625)
SHOW TABLES FROM returned wrong error message
if the schema specified did not exist.
(Bug#12591)
A server crash could result from an update of a view defined as a join, even though the update updated only a single table. (Bug#12569)
DELETE or UPDATE for an
indexed MyISAM table could fail. This was due
to a change in end-space comparison behavior from 4.0 to 4.1.
(Bug#12565)
Some statements executed on a master server caused the SQL thread on a slave to run out of memory. (Bug#12532)
The COLUMN_DEFAULT column of the
INFORMATION_SCHEMA.COLUMNS table should be
returned as NULL if a column has no default
value. An empty string was being returned if the column was
defined as NOT NULL.
(Bug#12518)
The ROW() contructor returned an incorrect
result when comparison involved NULL values.
(Bug#12509)
Trigger and stored procedure execution could break replication. (Bug#12482)
NOW(),
CURRENT_TIME() and values
generated by timestamp columns are now constant for the duration
of a stored function or trigger. This prevents the breaking of
statements-based replication.
(Bug#12481)
Selecting from a view defined as a join over many tables could
result in a server crash due to miscalculation of the number of
conditions in the WHERE clause.
(Bug#12470)
MEMORY tables using B-Tree
index on 64-bit platforms could produce false table is full
errors.
(Bug#12460)
The CREATE_OPTIONS column of
INFORMATION_SCHEMA.TABLES showed incorrect
options for tables in INFORMATION_SCHEMA.
(Bug#12397)
Mishandling of comparison for rows containing
NULL values against rows produced by an
IN subquery could cause a server crash.
(Bug#12392)
Selecting from a view after INSERT statements
for the view's underlying table yielded different results than
subsequent selects.
(Bug#12382)
Concatenating USER() or
DATABASE() with a column
produced invalid results.
(Bug#12351)
Comparison of InnoDB multi-part primary keys
that include VARCHAR columns can result in
incorrect results.
(Bug#12340)
Renamed the rest() macro in
my_list.h to list_rest()
to avoid name clashes with user code.
(Bug#12327)
When restoring INFORMATION_SCHEMA as the
default database after failing to execute a stored procedure in
an inaccessible database, the server returned a spurious
ERROR 42000: Unknown database
'information_schema' message.
(Bug#12318)
Users created using an IP address or other alias rather than a
hostname listed in /etc/hosts could not set
their own passwords.
(Bug#12302)
The NUMERIC_SCALE column of the
INFORMATION_SCHEMA.COLUMNS table should be
returned as 0 for integer columns. It was
being returned as NULL.
(Bug#12301)
Creating a view that included the
TIMESTAMPDIFF() function
resulted in a invalid view.
(Bug#12298)
CHECKSUM TABLE command returned incorrect
results for tables with deleted rows. After upgrading, users who
used stored checksum information to detect table changes should
rebuild their checksum data.
(Bug#12296)
Inserting NULL into a
GEOMETRY column for a table that has a
trigger could result in a server crash if the table was
subsequently dropped.
(Bug#12281)
myisampack failed to delete
.TMD temporary files when run with
-T option.
(Bug#12235)
A race condition between server threads could cause a crash if one thread deleted a stored routine while another thread was executing a stored routine. (Bug#12228)
Duplicate instructions in stored procedures resulted in incorrect execution when the optimizer optimized the duplicate code away. (Bug#12168)
XA allowed two active transactions to be
started with the same XID.
(Bug#12162)
NULL column definitions read incorrectly for
inner tables of nested outer joins.
(Bug#12154)
GROUP_CONCAT ignores the
DISTINCT modifier when used in a query
joining multiple tables where one of the tables has a single
row.
(Bug#12095)
A failure to obtain a lock for an IN SHARE
MODE query could result in a server crash.
(Bug#12082)
SELECT ... INTO within a trigger could cause a server crash.
(Bug#11973)var_name
Using cursors and nested queries for the same table, corrupted results were returned for the outer query. (Bug#11909)
A query using a LEFT JOIN, an
IN subquery on the outer table, and an
ORDER BY clause, caused the server to crash
when cursors were enabled.
(Bug#11901)
UNION query with FULLTEXT
could cause server crash.
(Bug#11869)
Some subqueries of the form SELECT ... WHERE ROW(...)
IN ( were being
handled incorrectly.
(Bug#11867)subquery)
Column names in subqueries must be unique, but were not being checked for uniqueness. (Bug#11864)
TRUNCATE TABLE did not work with
TEMPORARY InnoDB tables.
(Bug#11816)
The mysql_info() C API function
could return incorrect data when executed as part of a
multi-statement that included a mix of statements that do and do
not return information.
(Bug#11688)
A trigger that included a SELECT statement
could cause a server crash.
(Bug#11587)
Built-in commands for the mysql client, such
as delimiter and \d are
now always parsed within files that are read using the
\. and source commands.
(Bug#11523)
Added portability check for Intel compiler to address a problem
compiling InnoDB code.
(Bug#11510)
ALTER TABLE did not move the table to
default database unless the new name was qualified with the
database name.
(Bug#11493)db_name.t RENAME
t
Joins on VARCHAR columns of different lengths
could produce incorrect results.
(Bug#11398)
For PKG installs on Mac OS X, the preinstallation and postinstallation scripts were being run only for new installations and not for upgrade installations, resulting in an incomplete installation process. (Bug#11380)
Prepared statement parameters could cause errors in the binary
log if the character set was cp932.
(Bug#11338)
Columns defined as TINYINT(1) were redefined
as TINYINT(4) when incorporated into a
VIEW.
(Bug#11335)
Stored procedures with particularly long loops could crash server due to memory leak. (Bug#11247, Bug#12297)
SET GLOBAL TRANSACTION ISOLATION LEVEL was
not working.
(Bug#11207)
A view was allowed to depend on a function that referred to a temporary table. (Bug#10970)
Issuing FLUSH INSTANCES followed by
STOP INSTANCE caused instance manager to
crash.
(Bug#10957)
User variables were not automatically cast for comparisons, causing queries to fail if the column and connection character sets differed. Now when mixing strings with different character sets but the same coercibility, allow conversion if one character set is a superset of the other. (Bug#10892)
An incorrect conversion from double to
ulonglong caused indexes not to be used for
BDB tables on HP-UX.
(Bug#10802)
Slave I/O threads were considered to be in the running state
when launched (rather than after successfully connecting to the
master server), resulting in incorrect SHOW SLAVE
STATUS output.
(Bug#10780)
DATE_ADD() and
DATE_SUB() were converting
invalid dates to NULL in
TRADITIONAL SQL mode rather than rejecting
them with an error.
(Bug#10627)
Views with multiple UNION and UNION
ALL produced incorrect results.
(Bug#10624)
It was not possible to create a stored function with a spatial return value data type. (Bug#10499)
INSERT ... SELECT ... ON DUPLICATE KEY UPDATE
could fail with an erroneous “Column
'col_name' specified twice”
error.
(Bug#10109)
The only valid values for the PACK_KEYS table
option are 0 and 1, but other values were being accepted.
(Bug#10056)
Using a stored procedure that referenced tables in the
INFORMATION_SCHEMA database would return an
empty result set.
(Bug#10055, Bug#12278)
FLUSH TABLES WITH READ LOCK combined with
LOCK TABLE .. WRITE caused deadlock.
(Bug#9459)
A data type of CHAR BINARY was not recognized
as valid for stored routine parameters.
(Bug#9048)
ISO-8601 formatted dates were not being
parsed correctly.
(Bug#7308)
On Windows when the
--innodb_buffer_pool_awe_mem_mb option has been
given, the server detects whether AWE support is available and
has been compiled into the server, and displays an appropriate
error message if not.
(Bug#6581)
Pathame values for options such as ---basedir
or --datadir didn't work on Japanese Windows
machines for directory names containing multi-byte characters
having a second byte of 0x5C (“
\ ”).
(Bug#5439)
If a DROP DATABASE fails on a master server
due to the presence of a non-database file in the database
directory, the master have the database tables deleted, but not
the slaves. To deal with failed database drops, we now write
DROP TABLE statements to the binary log for
the tables so that they are dropped on slaves.
(Bug#4680)
SHOW TABLE STATUS sometimes reported a
Row_format value of
Dynamic for MEMORY tables,
though such tables always have a format of
Fixed.
(Bug#3094)
Functionality added or changed:
MySQL Cluster:
Improved handling of the configuration variables
NoOfPagesToDiskDuringRestartACC,
NoOfPagesToDiskAfterRestartACC,
NoOfPagesToDiskDuringRestartTUP, and
NoOfPagesToDiskAfterRestartTUP should result
in noticeably faster startup times for MySQL Cluster.
(Bug#12149)
Added an optimization that avoids key access with
NULL keys for the ref
method when used in outer joins.
(Bug#12144)
Added support of where clause for queries with FROM
DUAL.
(Bug#11745)
Maximum size of stored procedures increased from 64k to 4Gb. (Bug#11602)
SHOW CHARACTER SET and
INFORMATION_SCHEMA now properly report the
Latin1 character set as
cp1252.
(Bug#11216)
Added new ER_STACK_OVERRUN_NEED_MORE error
message to indicate that, while the stack is not completely
full, more stack space is required.
(Bug#11213)
mysqldump now dumps triggers for each dumped
table. This can be suppressed with the
--skip-triggers option.
(Bug#10431)
Added error message for users who attempt CREATE TABLE
... LIKE and specify a non-table in the
LIKE clause.
(Bug#6859)
Security improvement: Applied a patch that addresses a potential
zlib data vulnerability that could result in
an application crash. This only affects the binaries for
platforms that are linked statically against the bundled zlib
(most notably Microsoft Windows and HP-UX).
(CVE-2005-1849)
Bugs fixed:
MySQL Cluster: The MySQL Cluster backup log was invalid where the number of Cluster nodes was not equal to a power of 2. (Bug#11675)
Creation of the mysql group account failed
during the RPM installation.
(Bug#12348)
Updated dependency list for RPM builds to include missing
dependencies such as useradd and
groupadd.
(Bug#12233)
A delayed insert that would duplicate an existing record crashed the server instead. (Bug#12226)
When DROP DATABASE was called concurrently
with a DROP TABLE of any table, the MySQL
Server crashed.
(Bug#12212)
InnoDB: True VARCHAR:
Return NULL columns in the format expected by
MySQL.
(Bug#12186)
Information about a trigger was not displayed in the output of
SELECT ... FROM INFORMATION_SCHEMA.TRIGGERS
when the selected database was
INFORMATION_SCHEMA, prior to the trigger's
first invocation.
(Bug#12127)
InnoDB: Do not flush after each write, not
even before setting up the doublewrite buffer. Flushing can be
extremely slow on some systems.
(Bug#12125)
Two threads could potentially initialize different characters sets and overwrite each other. (Bug#12109)
big5 strings were not being stored in
FULLTEXT index.
(Bug#12075)
Character data truncated when GBK characters
0xA3A0 and 0xA1 are
present.
(Bug#11987)
ALTER TABLE when SQL_MODE =
'TRADITIONAL' gave rise to an invalid error message.
(Bug#11964)
Issuing successive FLUSH TABLES WITH READ
LOCK would cause the mysql client
to hang.
(Bug#11934)
mysql_install_db used static
localhost value in GRANT
tables even when server hostname is not
localhost, such as
localhost.localdomain. This change is applied
to version 5.0.10b on Windows.
(Bug#11822)
Comparisons like SELECT "A\\" LIKE
"A\\"; fail when using SET NAMES
utf8;.
(Bug#11754)
Attempting to repair a table having a fulltext index on a column
containing words whose length exceeded 21 characters and where
myisam_repair_threads was greater than 1
would crash the server.
(Bug#11684)
When used in a SELECT query against a view,
the GROUP_CONCAT() function
returned only a single row.
(Bug#11412)
Multiplying ABS() output by a
negative number would return incorrect results.
(Bug#11402)
The LPAD() and
RPAD() functions returned the
wrong length to
mysql_fetch_fields().
(Bug#11311)
A UNIQUE VARCHAR column would be
mis-identified as MUL in table descriptions.
(Bug#11227)
DDL statements now are allowed in stored procedures if the
procedure is not invoked from a stored function or a trigger.
Also fixed problems where a TEMPORARY
statement created by one stored routine was inaccessible to
another routine invoked during the same connection.
(Bug#11126)
Calling the C API function
mysql_stmt_fetch() after all
rows of a result set were exhausted would return an error
instead of MYSQL_NO_DATA.
(Bug#11037)
SELECT @@local... returned
@@session... in the column header.
(Bug#10724)
Incorrect error message displayed if user attempted to create a
table in a non-existing database using CREATE
syntax.
(Bug#10407)database_name.table_name
Unsigned LONG system variables may return
incorrect value when retrieved with a SELECT
for certain values.
(Bug#10351)
GROUP_CONCAT() sometimes
returned a result with a different collation from that of its
arguments.
(Bug#10201)
Prepared statements were not being written to the Slow Query log. (Bug#9968)
The value of max_connections_per_hour was
capped by the unrelated max_user_connections
setting.
(Bug#9947)
In stored procedures, a cursor that fetched an empty string into
a variable would set the variable to NULL
instead.
(Bug#8692)
Added checks to prevent error when allocating memory when there was insufficient memory available. (Bug#7003)
Multiple SELECT SQL_CACHE queries in a stored
procedure causes error and client hang.
(Bug#6897)
A trigger dependent on a feature of one
SQL_MODE setting would cause an error when
invoked after the SQL_MODE was changed.
(Bug#5891)
Functionality added or changed:
Incompatible Change:
The namespace for triggers has changed. Previously, trigger
names had to be unique per table. Now they must be unique within
the schema (database). An implication of this change is that
DROP TRIGGER syntax now uses a schema name
instead of a table name (schema name is optional and, if
omitted, the current schema will be used).
When upgrading from a previous version of MySQL 5 to MySQL
5.0.10 or newer, you must drop all triggers and re-create them
or DROP TRIGGER will not work after the
upgrade. A suggested procedure for doing this is given in
Section 2.4.17.2, “Upgrading from MySQL 4.1 to 5.0”.
(Bug#5892)
MySQL Cluster:
A new -P option is available for use with the
ndb_mgmd client. When called with this
option, ndb_mgmd prints all configuration
data to stdout, then exits.
On Windows, the search path used by MySQL applications for
my.ini now includes
..\my.ini (that is, the application's
parent directory, and hence, the installation directory).
(Bug#10419)
The viewing of triggers and trigger metadata has been enhanced as follows:
An extension to the SHOW command has been
added: SHOW TRIGGERS can be used to view
a listing of triggers. See Section 12.5.4.26, “SHOW TRIGGERS Syntax”,
for details.
The INFORMATION_SCHEMA database now
includes a TRIGGERS table. See
Section 22.16, “The INFORMATION_SCHEMA TRIGGERS Table”, for details.
(Bug#9586)
It is no longer necessary to issue an explicit LOCK
TABLES for any tables accessed by a trigger prior to
executing any statements that might invoke the trigger.
Previously, executing a statement that invoked a trigger would
cause problems unless a LOCK TABLES was first
issued for any tables accessed by the trigger. The exact nature
of the problem depended upon the MySQL 5.0 release being used:
prior to 5.0.3, this resulted in a crash; from 5.0.3 to 5.0.7,
MySQL would issue a warning; in 5.0.9, the server would issue an
error.
The same issue caused LOCK TABLES to fail
following UNLOCK TABLES if triggers were
involved.
(Bug#8406, Bug#9581)
The MySQL server now starts correctly with all combinations of
basedir and datadir
resolving an issue introduced by the original fix for this bug
in MySQL 4.1.9.
(Bug#7249)
See also Bug#7518
Added
mysql_get_character_set_info()
C API function for obtaining information about the default
character set of the current connection.
An extension to the SHOW command has been
added: SHOW TRIGGERS can be used to view a
listing of triggers. See Section 12.5.4.26, “SHOW TRIGGERS Syntax”, for
details.
Add the --defaults-group-suffix option. See
Section 4.2.2.2, “Using Option Files”.
The bundled version of the readline library
was upgraded to version 5.0.
Triggers can now reference tables by name. See
Section 20.1, “CREATE TRIGGER Syntax”, for more information.
Add table_lock_wait_timeout global server
system variable.
Bugs fixed:
Security Fix:
A vulnerability in zlib could result in a
buffer overflow and arbitrary code execution.
(Bug#11844, CVE-2005-2096, CVE-2005-1849)
MySQL Cluster:
The temporary tables created by an ALTER
TABLE on an NDB table were visible
to all SQL nodes in the cluster.
(Bug#12055)
MySQL Cluster:
NDB ignored the Hostname
option in the [ndbd default] section of the
cluster configuration file.
(Bug#12028)
MySQL Cluster:
The output of perror --help
did not display any information about the --ndb
option.
(Bug#11999)
MySQL Cluster: Attempting to create or drop tables during a backup would cause the cluster to shut down. (Bug#11942)
MySQL Cluster: ndb_mgmd leaked file descriptors. (Bug#11898)
MySQL Cluster: The MySQL Server left core files following shutdown if data nodes had failed. (Bug#11516)
MySQL Cluster:
When attempting to drop a table with a broken unique index,
NDB failed to drop the table and erroneously
report that the table was unknown.
(Bug#11355)
MySQL Cluster:
Trying to use a greater number of tables than specified by the
value of MaxNoOfTables caused table
corruption such that data nodes could not be restarted.
(Bug#9994)
Fixed compile error when using GCC4 on AMD64. (Bug#12040)
SHOW BINARY LOGS displayed a file size of 0
for all log files but the current one if the files were not
located in the data directory.
(Bug#12004)
Increased the version number of the
libmysqlclient shared library from 14 to 15
because it is binary incompatible with the MySQL 4.1 client
library.
(Bug#11893)
The server crashed when dropping a trigger that invoked a stored procedure, if the procedure was not yet in the connection-specific stored routine cache. (Bug#11889)
SELECT ... NOT IN() gave unexpected results
when only static value present between the
().
(Bug#11885)
A recent optimizer change caused DELETE ... WHERE ...
NOT LIKE and DELETE ... WHERE ... NOT
BETWEEN to not properly identify the rows to be
deleted.
(Bug#11853)
Execution of a prepared statement that invoked a non-existent or dropped stored routine would crash the server. (Bug#11834)
Selecting the result of an aggregate function for an
ENUM or SET column within
a subquery could result in a server crash.
(Bug#11821)
Creating a table with a SET or
ENUM column with the DEFAULT
0 clause caused a server crash if the table's
character set was utf8.
(Bug#11819)
Incorrect column values could be retrieved from views defined
using statements of the form SELECT * FROM
.
(Bug#11771)tbl_name
When invoked within a view,
SUBTIME() returned incorrect
values.
(Bug#11760)
For several character sets, MySQL incorrectly converted the
character code for the division sign to the
eucjpms character set.
(Bug#11717)
Performing an ORDER BY on a
SELECT from a VIEW
produced unexpected results when VIEW and
underlying table had the same column name on different columns.
(Bug#11709)
Execution of SHOW TABLES failed to increment
the Com_show_tables status variable.
(Bug#11685)
LIKE pattern matching using prefix index didn't return correct result. (Bug#11650)
Invoking the DES_ENCRYPT()
function could cause a server crash if the server was started
without the --des-key-file option.
(Bug#11643)
IP addresses not shown in ndb_mgm SHOW
command on second ndb_mgmd (or on ndb_mgmd restart).
(Bug#11596)
SHOW PROCEDURE/FUNCTION STATUS didn't work
for users with limited access.
(Bug#11577)
mysqlbinlog was failing the test suite on
Windows due to BOOL being incorrectly cast to
INT.
(Bug#11567)
The server crashed upon execution of a statement that used a
stored function indirectly (via a view) if the function was not
yet in the connection-specific stored routine cache and the
statement would update a
Handler_ status
variable. This fix allows the use of stored routines under
xxxLOCK TABLES without explicitly locking the
mysql.lock table. However, you cannot use
mysql.proc in statements that will combine
locking of it with modifications for other tables.
(Bug#11554)
Aliasing the column names in a VIEW did not
work when executing a SELECT query on the
VIEW.
(Bug#11399)
The mysql.proc table was not being created
properly with the proper utf8 character set
and collation, causing server crashes for stored procedure
operations if the server was using a multi-byte character set.
To take advantage of the bug fix,
mysql_fix_privilege_tables should be run to
correct the structure of the mysql.proc
table.
Note that it is necessary to run
mysql_fix_privileges_tables when upgrading
from a previous installation that contains the
mysql.proc table (that is, from a previous
5.0 installation). Otherwise, creating stored procedures might
not work.
(Bug#11365)
For prepared statements, the SQL parser did not disallow “
? ” parameter markers immediately
adjacent to other tokens, which could result in malformed
statements in the binary log. (For example, SELECT *
FROM t WHERE? = 1 could become SELECT * FROM
t WHERE0 = 1.)
(Bug#11299)
The C API function
mysql_stmt_reset() did not
clear error information.
(Bug#11183)
INFORMATION_SCHEMA.COLUMNS had some
inaccurate values for some data types.
(Bug#11057)
MySQL server would crash is a fetch was performed after a
ROLLBACK when cursors were involved.
(Bug#10760)
When two threads competed for the same table, a deadlock could
occur if one thread also had a lock on another table through
LOCK TABLES and the thread was attempting to
remove the table in some manner while the other thread tried to
place locks on both tables.
(Bug#10600)
When used within a subquery,
SUBSTRING() returned an empty
string.
(Bug#10269)
Multiple-table UPDATE queries using
CONVERT_TZ() would fail with an
error.
(Bug#9979)
With strict SQL mode enabled, ALTER TABLE
reported spurious “Invalid default value” messages
for columns that had no DEFAULT clause.
(Bug#9881)
mysql_fetch_fields() returned
incorrect length information for MEDIUM and
LONG TEXT and
BLOB columns.
(Bug#9735)
Within a stored procedure, selecting from a table through a view caused subsequent updates to the table to fail with a message that the table was read-locked. (Bug#9597)
Within a stored procedure that selects from a table, invoking another procedure that requires a write lock for the table caused that procedure to fail with a message that the table was read-locked. (Bug#9565)
Server-side prepared statements failed for columns with a
character set of ucs2.
(Bug#9442)
In SQL prepared statements, comparisons could fail for values
not equally space-padded. For example, SELECT 'a' =
'a '; returns 1, but PREPARE s FROM
'SELECT ?=?'; SET @a = 'a', @b = 'a '; PREPARE s FROM
'SELECT ?=?'; EXECUTE s USING @a, @b; incorrectly
returned 0.
(Bug#9379)
References to system variables in an SQL statement prepared with
PREPARE were evaluated during
EXECUTE to their values at prepare time, not
to their values at execution time.
(Bug#9359)
The server did not accept some fully-qualified trigger names. (Bug#8758)
Creating a trigger in one database that references a table in another database was being allowed without generating errors. (Bug#8751)
For server shutdown on Windows, error messages of the form
Forcing close of thread were being
written to the error log. Now connections are closed more
gracefully without generating error messages.
(Bug#7403)n
user: 'name'
For a stored procedure defined with SQL SECURITY
DEFINER characteristic,
CURRENT_USER() incorrectly
reported the use invoking the procedure, not the user who
defined it.
(Bug#7291)
Labels in stored routines did not work if the character set was
not latin1.
(Bug#7088)
Duplicate trigger names were allowed within a single schema. (Bug#6182)
For execution of a stored procedure that refers to a view, changes to the view definition were not seen. The procedure continued to see the old contents of the view. (Bug#6120)
The traditional SQL mode accepted invalid
dates if the date value provided was the result of an implicit
type conversion.
(Bug#5906)
In a shared Windows environment, MySQL could not find its
configuration file unless the file was in the
C:\ directory.
(Bug#5354)
Functions that evaluate to constants (such as
NOW() and
CURRENT_USER() were being
evaluated in the definition of a VIEW rather
than included verbatim.
(Bug#4663)
Functionality added or changed:
The handling of BIT columns has been
improved, and should now be much more reliable in a number of
cases.
(Bug#11572, Bug#11091, Bug#10617)
Recursion in stored routines is now disabled because it was crashing the server. We plan to modify stored routines to allow this to operate safely in a future release. (Bug#11394)
An attempt to create a TIMESTAMP column with
a display width (for example, TIMESTAMP(6))
now results in a warning. Display widths have not been supported
for TIMESTAMP since MySQL 4.1.
(Bug#10466)
mysql_real_escape_string() API
function now respects NO_BACKSLASH_ESCAPES
SQL mode.
(Bug#10214)
InnoDB: Made CHECK TABLE
killable.
(Bug#9730)
InnoDB: Make
innodb_thread_concurrency=20 by default.
Bypass the concurrency checking if the setting is greater than
or equal to 20.
InnoDB: Various optimizations. Removed
unreachable debug code from non-debug builds. Added hints for
the branch predictor in gcc. Made assertions
occupy less space.
InnoDB: When creating or extending an
InnoDB data file, at most one megabyte at a
time is allocated for initializing the file. Previously,
InnoDB allocated and initialized 1 or 8
megabytes of memory, even if only a few 16-kilobyte pages were
to be written. This improves the performance of CREATE
TABLE in innodb_file_per_table
mode.
Bugs fixed:
MySQL Cluster: When trying to open a table that could not be discovered or unpacked, the cluster returned error codes which the MySQL server falsely interpreted as operating system errors. (Bug#10365)
The --master-data option for
mysqldump resulted in no error if the binary
log was not enabled. Now an error occurs unless the
--force option is given.
(Bug#11678)
When a table had a primary key containing a
BLOB column, creation of another index failed
with the error BLOB/TEXT column used in key
specification without keylength, even when the new
index did not contain a BLOB column.
(Bug#11657)
Incorrect results when using GROUP BY ... WITH
ROLLUP on a VIEW.
(Bug#11639)
MySQL would not compile correctly on QNX due to missing
rint() function.
(Bug#11544)
A SELECT DISTINCT would work correctly with a col_name
MyISAM
table only when there was an index on
col_name.
(Bug#11484)
Using CONCAT_WS() on a column
set NOT NULL caused incorrect results when
used in a LEFT JOIN.
(Bug#11469)
Temporary tables were created in the data directory instead of
tmpdir.
(Bug#11440)
Running a CHECK TABLES on multiple views
crashed the server.
(Bug#11337)
Manually inserting a row with host='' into
mysql.tables_priv and performing a
FLUSH PRIVILEGES would cause the server to
crash.
(Bug#11330)
Wrong comparison method used in VIEW when
relaxed date syntax used (for example,
2005.06.10).
(Bug#11325)
Signed BIGINT would not accept
-9223372036854775808 as a
DEFAULT value.
(Bug#11215)
Optimizer performed range check when comparing unsigned integers to negative constants, could cause errors. (Bug#11185)
A cursor using a query with a filter on a
DATE or DATETIME column
would cause the server to crash server after the data was
fetched.
(Bug#11172)
The mysql_config script did not handle
symbolic linking properly.
(Bug#10986)
mysqldump failed when reloading a view if the view was defined in terms of a different view that had not yet been reloaded. mysqldump now creates a dummy table to handle this case. (Bug#10927)
If a prepared statement cursor is opened but not completely fetched, attempting to open a cursor for a second prepared statement will fail. (Bug#10794)
Combining cursors and subqueries could cause server crash or memory leaks. (Bug#10736)
Instances of the VAR_SAMP()
function in view definitions were converted