Commit graph

39651 commits

Author SHA1 Message Date
V Narayanan
2453e20f7d updating with mysql-5.0-bugteam 2008-12-10 14:26:57 +05:30
Georgi Kodinov
d506265f2c backported the fix for bug #34773 to 5.0 2008-12-09 20:35:02 +02:00
Patrick Crews
c69ca8476c merge 2008-12-09 10:08:52 -05:00
Sergey Glukhov
c5c64a30d4 Bug#31399 Wrong query result when doing join buffering over BIT fields
if table has bit fields then uneven bits(if exist) are stored into null bits place.
So we need to copy null bits in case of uneven bit field presence.
2008-12-09 16:59:47 +04:00
Sergey Glukhov
d2b5e0bb94 Bug#31291 ALTER TABLE CONVERT TO CHARACTER SET does not change some data types
added ability for TINY[MEDIUM] text fields 
to be converted to greater subtype during
alter if necessary(altered charset)
2008-12-09 16:38:52 +04:00
Sergey Glukhov
904c7c4409 automerge 2008-12-09 16:11:01 +04:00
Alexey Kopytov
73b48decf0 Merge from mysql-5.0-bugteam. 2008-12-09 13:22:55 +03:00
Alexey Kopytov
66fa3c09a3 Added a missing bit from the original patch for bug #27483 which was lost when re-applying
the patch manually to another tree.
2008-12-09 13:19:46 +03:00
Sergey Glukhov
0661c210d3 bug#35558 Wrong server metadata blows up the client
the problem: FORMAT func max_length value was calculated incorrectly
the fix: correct calculation of max_length
2008-12-09 14:00:43 +04:00
Sergey Glukhov
eb46763654 Bug#35796 SHOW CREATE TABLE and default value for BIT field
show default value for BIT field in printable format
2008-12-09 13:53:23 +04:00
Sergey Vojtovich
53e83e6e21 Merge. 2008-12-09 12:53:19 +04:00
Alexey Kopytov
b713958132 Fixed type_float failures in --ps-protocol mode introduced by the test case for bug #27483.
The reason for the failures was bug #21205 (fixed in 6.0 by dtoa, but still present in 5.0/5.1).
2008-12-09 11:05:36 +03:00
Patrick Crews
67fc961e6f merge 2008-12-08 16:22:16 -05:00
Andrei Elkin
0ec3e14e98 merge 5.0->5.0-bugteam for a local tree containing bug#33420 Test 'rpl_packet' fails randomly. 2008-12-08 16:29:13 +02:00
Alexey Kopytov
772685705c Pull from mysql-5.0-bugteam 2008-12-08 15:14:10 +03:00
Georgi Kodinov
64529257ad merged 5.0-main -> 5.0-bugteam 2008-12-08 11:54:41 +02:00
Patrick Crews
33cf11b428 Bug#41258: mysql-test-run does not copy subdirectories of std_data on Windows (5.0 only)
Altered how we copy data from mysql-test/std_data on Windows to match what we are doing in 5.1 and 6.0
2008-12-05 08:21:03 -05:00
Andrei Elkin
cea55f3dc6 Bug #33420 Test 'rpl_packet' fails randomly with changed "Exec_Master_Log_Pos"
Bug #41173 rpl_packet fails sporadically on pushbuild: query 'DROP TABLE t1' failed


The both issues appeared to be a race between the SQL thread executing CREATE table t1
and the IO thread that is expected to stop at the consequent big size event.
The two events need serialization which is implemented.
The early bug required back-porting a part fixes for bug#38350 exclusively for 5.0 version.
2008-12-04 18:36:45 +02:00
Joerg Bruehe
fdbb8d3acb Merge main 5.0 to 5.0-build 2008-12-04 14:43:48 +01:00
Luis Soares
5726574b0c BUG#38826 Race in MYSQL_LOG::purge_logs is impossible to debug in production
BUG#39325 Server crash inside MYSQL_LOG::purge_first_log halts replicaiton

The patch reverses the order of the purging and updating events for log and relay-log.info/index files respectively.
This solves the problem of having holes caused by crashes happening between updating info/index files and purging logs.

NOTE: This is a combined patch for BUG#38826 and BUG#39325. This patch is based on bugteam tree and takes into account reviewers suggestions.
2008-12-04 01:01:03 +00:00
Alexey Kopytov
5f7869a22a Fix for bug #27483: Casting 'scientific notation type' to 'unsigned
bigint' fails on windows.

Visual Studio does not take into account some x86 hardware limitations
which leads to incorrect results when converting large DOUBLE values
to BIGINT UNSIGNED ones.

Fixed by adding a workaround for double->ulonglong conversion on
Windows.
2008-12-03 19:15:39 +03:00
V Narayanan
d5bfbfb9c3 merging with mysql-5.0-bugteam tree. 2008-12-03 17:52:55 +05:30
Tatiana A. Nurnberg
e979ff9ad0 auto-merge 2008-12-03 07:38:26 +01:00
Tatiana A. Nurnberg
83f6af41c7 auto-merge 2008-12-03 07:19:26 +01:00
timothy.smith@sun.com
3742489c37 Remove bashisms from BUILD/compile-dist and configure.in, so Bootstrap works on Solaris box; force GNU make in compile-dist; remove unportable "grep -q" from configure.in 2008-12-03 05:11:48 +01:00
timothy.smith@sun.com
6a65d019d4 Raise version number after cloning 5.0.74 2008-12-03 01:09:05 +01:00
Georgi Kodinov
e37c9e7fc9 moved the version to 5.0-main 2008-12-02 14:50:40 +02:00
Georgi Kodinov
f0c49a6a7d addendum to the fix for bug #39920 : post-merge test suite fixes 2008-12-01 17:41:06 +02:00
Georgi Kodinov
f2a317b663 merged 5.0-main into 5.0-bugteam 2008-12-01 16:56:56 +02:00
Georgi Kodinov
d21c85037f merged bug 39920 to 5.0-bugteam 2008-12-01 16:41:22 +02:00
Georgi Kodinov
8f36a23c00 Bug #39920: MySQL cannot deal with Leap Second expression in string literal.
Updated MySQL time handling code to react correctly on UTC leap second additions.
MySQL functions that return the OS current time, like e.g. CURDATE(), NOW() etc
will return :59:59 instead of :59:60 or 59:61.
As a result the reader will receive :59:59 for 2 or 3 consecutive seconds 
during the leap second.
This fix will not affect the values returned by UNIX_TIMESTAMP() for leap seconds.
But note that when converting the value returned by UNIX_TIMESTAMP() to broken 
down time the correction of leap seconds will still be applied.
Note that this fix will make a difference *only* if the OS is specially configured
to return leap seconds from the OS time calls or when using a MySQL time zone 
defintion that has leap seconds.
Even after this change date/time literals (or other broken down time 
representations) with leap seconds (ending on :59:60 or 59:61) will still be 
considered illegal and discarded by the server with an error or 
a warning depending on the sql mode.
Added a test case to demonstrate the effect of the fix.
2008-12-01 16:18:35 +02:00
Georgi Kodinov
be5e6ee031 Addendum to bug #37339 : make the test case portable to windows
by using and taking out a full path.
2008-12-01 13:34:53 +02:00
Gleb Shchepa
a3cb8c68c3 After-push commit for bug #33461 to make valgrind happy:
TABLE_LIST doesn't free Strings in its string lists
(TABLE_LIST::use_index and TABLE_liST::ignore_index), so
calling c_ptr_safe() on that Strings leads to memleaks.
OTOH "safe" c_ptr_safe() is not necessary there and we can
replace it with c_ptr().
2008-12-01 12:14:02 +04:00
Matthias Leich
b9f919e143 Merge of last pushes into GCA tree, no conflicts
Diff to actual 5.0-bugteam is revno: 2725 only
2008-11-28 19:47:08 +01:00
Gleb Shchepa
228c913ee5 Bug #33461: SELECT ... FROM <view> USE INDEX (...) throws
an error

Even after the fix for bug 28701 visible behaviors of
SELECT FROM a view and SELECT FROM a regular table are
little bit different:

1. "SELECT FROM regular table USE/FORCE/IGNORE(non
   existent index)" fails with a "ERROR 1176 (HY000):
   Key '...' doesn't exist in table '...'"

2. "SELECT FROM view USING/FORCE/IGNORE(any index)" fails
   with a "ERROR 1221 (HY000): Incorrect usage of
   USE/IGNORE INDEX and VIEW".  OTOH "SHOW INDEX FROM
   view" always returns empty result set, so from the point
   of same behaviour view we trying to use/ignore non
   existent index.

To harmonize the behaviour of USE/FORCE/IGNORE(index)
clauses in SELECT from a view and from a regular table the
"ERROR 1221 (HY000): Incorrect usage of USE/IGNORE INDEX
and VIEW" message has been replaced with the "ERROR 1176
(HY000): Key '...' doesn't exist in table '...'" message
like for tables and non existent keys.
2008-11-28 20:13:12 +04:00
Georgi Kodinov
ccc3404f1b merged bug 37339 to 5.0-bugteam 2008-11-28 16:32:04 +02:00
Georgi Kodinov
0708ad5f98 Bug #37339: SHOW VARIABLES not working properly with multi-byte datadir
The SHOW VARIABLES LIKE .../SELECT @@/SELECT ... FROM INFORMATION_SCHEMA.VARIABLES
were assuming that all the system variables are in system charset (UTF-8).
However the variables that are settable through command line will have a different
character set (character_set_filesystem).
Fixed the server to remember the correct character set of basedir, datadir, tmpdir,
ssl, plugin_dir, slave_load_tmpdir, innodb variables; init_connect and init_slave 
variables and use it when processing data.
2008-11-28 16:25:16 +02:00
Sergey Vojtovich
85d4cbae24 BUG#37245 - Full text search problem
Certain boolean mode queries with truncation operator did
not return matching records and calculate relevancy
incorrectly.
2008-11-28 18:17:13 +04:00
Sergey Glukhov
68066aa5a1 error code is changed to satisfy Win NT 2008-11-28 17:12:43 +04:00
Sergey Glukhov
17cd69ccf4 pushbuild failure fixes 2008-11-28 14:50:13 +04:00
Tatiana A. Nurnberg
99fe5e523e auto-merge 2008-11-27 17:17:16 +01:00
Sergey Glukhov
63bca358ca Bug#37284 Crash in Field_string::type()
The bug is repeatable with latest(1.0.1) InnoDB plugin on Linux, Win,
If MySQL is compiled with valgrind there are errors about
using of uninitialized variable(orig_table).
The fix is to set field->orig_table correct value.
2008-11-27 18:54:23 +04:00
Sergey Glukhov
861eeb918d removed unused variable 2008-11-27 18:26:22 +04:00
Sergey Glukhov
2fb574214e Bug#37460 Assertion failed: !table->file || table->file->inited == handler::NONE
enable uncacheable flag if we update a view with check option
and check option has a subselect, otherwise, the check option
can be evaluated after the subselect was freed as independent
(See full_local in JOIN::join_free())
2008-11-27 17:57:34 +04:00
Tatiana A. Nurnberg
238c5bfa2f auto-merge 2008-11-27 14:45:41 +01:00
Sergey Glukhov
7b488c46a0 Bug#40365 Prepared statements may insert invalid dates.
set DATE|DATETIME value to 0 if ALLOW_INVALID_DATES sql_mode is not enabled.
2008-11-27 16:41:25 +04:00
Sergey Glukhov
29cced9440 Bug#34825 perror on windows doesn't know about win32 error codes
extended perror to enable printing of Win32 system errors
2008-11-27 16:33:40 +04:00
Tatiana A. Nurnberg
d57c7dcff8 auto-merge 2008-11-27 12:50:51 +01:00
Chad MILLER
0e44a4e94c Bug#32136: mysqld_multi --defaults-file not respected while using \
--mysqld=mysqld_safe

The server run didn't know the correct section to read in a
configuration file, and would read from "[mysqld]" even though
mysqld_multi had already read the defaults and made them into explicit
parameters. 

Worse, the "defaults-file" parameter says that it means "Read only
this configuration file, do not read the standard system-wide and
user-specific files", which should apply not only to mysql-multi, but
to the server also.

So, now if "defaults-file" is given, put "no-defaults" before all the
explicit parameters we read from the defaults-file and feed to the
mysqld or mysqld_safe.
2008-11-26 10:51:59 -05:00
Tatiana A. Nurnberg
ae0c6a949c Bug#37553: MySql Error Compare TimeDiff & Time
We pretended that TIMEDIFF() would always return positive results;
this gave strange results in comparisons of the TIMEDIFF(low,hi)<TIME(0)
type that rendered a negative result, but still gave false in comparison.
We also inadvertantly dropped the sign when converting times to
decimal.

CAST(time AS DECIMAL) handles signs of the times correctly.
TIMEDIFF() marked up as signed. Time/date comparison code switched to
signed for clarity.
2008-11-26 09:28:17 +01:00