Commit graph

24082 commits

Author SHA1 Message Date
anozdrin/alik@quad.
48058cf10b Merge quad.:/mnt/raid/alik/MySQL/devel/5.0-rt
into  quad.:/mnt/raid/alik/MySQL/devel/5.1-rt-merged
2008-02-18 18:12:05 +03:00
holyfoot/hf@hfmain.(none)
0c8df13cda Merge bk@192.168.21.1:mysql-5.1-opt
into  mysql.com:/home/hf/work/32942/my51-32942
2008-02-18 19:08:35 +04:00
holyfoot/hf@hfmain.(none)
377ecd81c7 Merge mysql.com:/home/hf/work/32942/my50-32942
into  mysql.com:/home/hf/work/32942/my51-32942
2008-02-18 16:07:47 +04:00
kaa@kaamos.(none)
93cbe28aac Initialization order cleanups to get rid of warnings from the
-Wreorder option added by the patch for bug#31326.
2008-02-18 14:35:44 +03:00
kaa@kaamos.(none)
7e43bc00f2 Merge ssh://bk-internal.mysql.com//home/bk/mysql-5.1-opt
into  kaamos.(none):/data/src/opt/mysql-5.1-opt
2008-02-17 16:59:26 +03:00
kaa@kaamos.(none)
443c1a8b19 Merge ssh://bk-internal.mysql.com//home/bk/mysql-5.0-opt
into  kaamos.(none):/data/src/opt/mysql-5.0-opt
2008-02-17 16:57:07 +03:00
kaa@kaamos.(none)
5647dee192 Merge kaamos.(none):/data/src/mysql-5.1
into  kaamos.(none):/data/src/opt/mysql-5.1-opt
2008-02-17 14:57:01 +03:00
holyfoot/hf@mysql.com/hfmain.(none)
7abba3b021 Bug #32942 now() - interval '7200' second NOT pre-calculated, causing "full table scan"
Problem is not about intervals and doesn't actually cause 'full table scan'.
We have an optimization for DISTINCT when we have
'DISTINCT field_from_first_join_table' we don't need to read all the
rows from the JOIN-ed table if we found one conforming row.
It stopped working in 5.0 as we return NESTED_LOOP_OK if we came upon
that case in the evaluate_join_record() and that doesn't break the
recordreading loop in sub_select().

Fixed by returning NESTED_LOOP_NO_MORE_ROWS in this case.
2008-02-17 15:48:17 +04:00
kaa@kaamos.(none)
3daeb40f1f Merge kaamos.(none):/data/src/mysql-5.0
into  kaamos.(none):/data/src/opt/mysql-5.0-opt
2008-02-17 14:37:39 +03:00
ramil/ram@ramil.myoffice.izhnet.ru
0f30fa7218 Merge mysql.com:/home/ram/work/b33304/b33304.5.0
into  mysql.com:/home/ram/work/b33304/b33304.5.1
2008-02-16 15:02:49 +04:00
gkodinov/kgeorge@magare.gmz
047b1a66a0 Merge magare.gmz:/home/kgeorge/mysql/work/B31887-5.0-opt
into  magare.gmz:/home/kgeorge/mysql/work/B31887-5.1-opt
2008-02-16 10:48:33 +02:00
istruewing@stella.local
4bbbd57c81 Merge stella.local:/home2/mydev/mysql-5.1-amain
into  stella.local:/home2/mydev/mysql-5.1-axmrg
2008-02-15 20:44:33 +01:00
istruewing@stella.local
b620694ba3 Merge stella.local:/home2/mydev/mysql-5.0-amain
into  stella.local:/home2/mydev/mysql-5.0-axmrg
2008-02-15 20:06:15 +01:00
mkindahl@dl145h.mysql.com
d277f9344f Merge dl145h.mysql.com:/data0/mkindahl/mysql-5.0-rpl-merge
into  dl145h.mysql.com:/data0/mkindahl/mysql-5.0-rpl
2008-02-15 17:51:35 +01:00
mkindahl@dl145h.mysql.com
c5273c1759 Merge dl145h.mysql.com:/data0/mkindahl/mysql-5.0-rpl
into  dl145h.mysql.com:/data0/mkindahl/mysql-5.1-rpl
2008-02-15 17:49:05 +01:00
gkodinov/kgeorge@magare.gmz
a781c1b140 Merge gkodinov@bk-internal.mysql.com:/home/bk/mysql-5.0-opt
into  magare.gmz:/home/kgeorge/mysql/autopush/B31887-5.0-opt
2008-02-15 18:34:03 +02:00
gkodinov/kgeorge@magare.gmz
490ec62be4 Bug #31887: DML Select statement not returning same results
when executed in version 5

Zero fill is a field attribute only. So we can't always 
propagate  constants for zerofill fields : the values and 
expression results don't have that flag.

Fixed by converting the const value to a string and 
using that in const propagation when the context allows it. 
Disable const propagation for fields with ZEROFILL flag in
all the other cases.
2008-02-15 15:47:32 +02:00
mats@kindahl-laptop.dnsalias.net
89e2fe8c05 Bug #34458 Extreneous use of templates in server code
Patch to remove white-space left over after removing anonymous
namespace.
2008-02-15 13:06:28 +01:00
ramil/ram@mysql.com/ramil.myoffice.izhnet.ru
fe6d4aef3a Fix for bug #33304: Test 'func_group' hangs on Mac OS X 10.4 PowerPC 64-bit
Problem: SLEEP(0) never returns on 64-bit Mac OS X due to a bug in 
pthread_cond_timedwait().

Fix: when given a very short timeout just return immediately.
2008-02-15 16:03:54 +04:00
mats@kindahl-laptop.dnsalias.net
25dc9eb10b Bug #34458 Extreneous use of templates in server code
Replacing a template function with a normal static function.
The template parameter, which previously was the class to
find a binlogging function in, is now passed as a pointer to
the actual binlogging function instead.

The patch requires change of indention, but that is submitted
as a separate patch.
2008-02-15 12:56:44 +01:00
aelkin/andrei@mysql1000.dsl.inet.fi
416001d8ed Merge aelkin@bk-internal.mysql.com:/home/bk/mysql-5.0-rpl
into  mysql1000.dsl.inet.fi:/home/andrei/MySQL/MERGE/5.0-bug33931-assert_write_ignored_ev_when_init_slave_fails
2008-02-14 21:38:30 +02:00
istruewing@stella.local
6c977025df Merge stella.local:/home2/mydev/mysql-5.0-ateam
into  stella.local:/home2/mydev/mysql-5.0-axmrg
2008-02-14 20:24:01 +01:00
istruewing@stella.local
9a4d57e319 Merge stella.local:/home2/mydev/mysql-5.1-amain
into  stella.local:/home2/mydev/mysql-5.1-axmrg
2008-02-14 16:53:03 +01:00
istruewing@stella.local
fb20c9dd5e Merge stella.local:/home2/mydev/mysql-5.1-ateam
into  stella.local:/home2/mydev/mysql-5.1-axmrg
2008-02-14 16:51:41 +01:00
istruewing@stella.local
b6c8f8a58b Merge stella.local:/home2/mydev/mysql-5.0-amain
into  stella.local:/home2/mydev/mysql-5.0-axmrg
2008-02-14 16:14:30 +01:00
anozdrin/alik@quad.
6bf1306b13 A patch for Bug#18834: ALTER TABLE ADD INDEX on table with
two timestamp fields.
  
The actual problem here was that CREATE TABLE allowed zero
date as a default value for a TIMESTAMP column in NO_ZERO_DATE mode.
  
The thing is that for TIMESTAMP date type specific rule is applied:
  column_name TIMESTAMP == column_name TIMESTAMP DEFAULT 0
whever for any other date data type
  column_name TYPE == column_name TYPE DEFAULT NULL
  
The fix is to raise an error when we're in NO_ZERO_DATE mode and
there is TIMESTAMP column w/o default value.
2008-02-14 18:13:40 +03:00
aelkin/andrei@mysql1000.dsl.inet.fi
871eb3e5ad bug#33329 extraneous ROLLBACK in binlog on connection does not use trans tables
changes for an assert and an updated results file.
2008-02-14 16:28:32 +02:00
svoj@mysql.com/april.(none)
7fa875e42b BUG#33946 - Join on Federated tables with Unique index gives error 1430
from storage engine

Federated may crash a server, return wrong result set, return
"ERROR 1030 (HY000): Got error 1430 from storage engine" message
when local (engine=federated) table has a key against nullable
column.

The problem was wrong implementation of function that creates
WHERE clause for remote query from key.
2008-02-14 16:27:01 +04:00
aelkin/andrei@mysql1000.dsl.inet.fi
f5fe34dcd1 Merge aelkin@bk-internal.mysql.com:/home/bk/mysql-5.0-rpl
into  mysql1000.dsl.inet.fi:/home/andrei/MySQL/MERGE/5.0-bug33931-assert_write_ignored_ev_when_init_slave_fails
2008-02-14 13:55:11 +02:00
kaa@kaamos.(none)
eeab00e3d0 Merge kaamos.(none):/data/src/opt/mysql-5.0-opt
into  kaamos.(none):/data/src/opt/mysql-5.1-opt
2008-02-14 12:54:23 +03:00
kaa@kaamos.(none)
88132e290a Merge ssh://bk-internal.mysql.com//home/bk/mysql-5.1-opt
into  kaamos.(none):/data/src/opt/mysql-5.1-opt
2008-02-14 12:49:39 +03:00
kaa@kaamos.(none)
f41a5edfc7 Merge ssh://bk-internal.mysql.com//home/bk/mysql-5.0-opt
into  kaamos.(none):/data/src/opt/mysql-5.0-opt
2008-02-14 12:48:25 +03:00
mkindahl@dl145h.mysql.com
8906700e13 Fixes to try to handle valgrind warnings identical to those in
BUG#24387, which is closed since long.
2008-02-14 09:53:01 +01:00
gshchepa/uchum@host.loc
e49dffa81d Merge host.loc:/home/uchum/work/5.1-opt-gca
into  host.loc:/home/uchum/work/5.1-opt
2008-02-14 01:33:06 +04:00
gshchepa/uchum@host.loc
814314be6b Merge host.loc:/home/uchum/work/5.0-opt-gca
into  host.loc:/home/uchum/work/5.0-opt
2008-02-13 19:47:39 +04:00
gshchepa/uchum@host.loc
e64b879510 Merge host.loc:/home/uchum/work/5.0-opt-gca
into  host.loc:/home/uchum/work/5.1-opt-gca
2008-02-13 19:37:05 +04:00
gshchepa/uchum@host.loc
18770a0de8 Fixed bug#31194: Privilege ordering does not order properly
for wildcard values.
The server ignored escape character before wildcards during
the calculation of priority values for sorting of a privilege
list. (Actually the server counted an escape character as an
ordinary wildcard like % or _). I.e. the table name template
with a wildcard character like 'tbl_1' had higher priority in
a privilege list than concrete table name without wildcards
like 'tbl\_1', and some privileges of 'tbl\_1' was hidden
by privileges for 'tbl_1'.

The get_sort function has been modified to ignore escaped
wildcards as usual.
2008-02-13 19:34:12 +04:00
gshchepa/uchum@host.loc
8f6ecbca82 Fixed bug#33764: Wrong result with IN(), CONCAT() and implicit
type conversion.

Instead of copying of whole character string from a temporary
buffer, the server copied a short-living pointer to that string
into a long-living structure. That has been fixed.
2008-02-13 19:32:19 +04:00
joerg@trift2.
51f81b0209 Merge trift2.:/MySQL/M51/clone-5.1
into  trift2.:/MySQL/M51/push-5.1
2008-02-13 13:40:53 +01:00
aelkin/andrei@mysql1000.dsl.inet.fi
22072c5c57 Bug #33931 assertion at write_ignored_events_info_to_relay_log if init_slave_thread() fails
and
bug#33932  assertion at handle_slave_sql if init_slave_thread() fails

the asserts were caused by 
  bug33931: having thd deleted at time of executing err: code plus
            a missed initialization;
  bug33932: initialization of slave_is_running member was missed;

fixed with relocating mi members initialization and removing delete thd
It is safe to do as deletion happens later explicitly in the caller of
init_slave_thread().

Todo: at merging the test is better to be moved into suite/bugs for 5.x (when x>0).
2008-02-13 14:09:41 +02:00
joerg@trift2.
341258dba4 Merge trift2.:/MySQL/M51/mysql-5.1
into  trift2.:/MySQL/M51/push-5.1
2008-02-13 13:05:07 +01:00
joerg@trift2.
e31275c481 Merge trift2.:/MySQL/M50/mysql-5.0
into  trift2.:/MySQL/M50/push-5.0
2008-02-13 12:48:25 +01:00
mikael@dator6.(none)
e1820b2e77 Merge dator6.(none):/home/mikael/mysql_clones/bug32943
into  dator6.(none):/home/mikael/mysql_clones/mysql-5.1-engines
2008-02-13 11:29:50 +01:00
mikael@dator6.(none)
2bff6fd22a Added comments on why we do reopen
Handle error case of not being able to reopen which
requires us to remove table from thread's open list
and table_cache.
2008-02-13 11:26:24 +01:00
kaa@kaamos.(none)
9f194149b8 Merge kaamos.(none):/data/src/opt/mysql-5.0-opt
into  kaamos.(none):/data/src/opt/mysql-5.1-opt
2008-02-13 12:12:00 +03:00
tomas@poseidon.bredbandsbolaget.se
cc6c696330 Merge poseidon.bredbandsbolaget.se:/home/tomas/mysql-5.1-rpl-merge
into  poseidon.bredbandsbolaget.se:/home/tomas/mysql-5.1-new-ndb-merge
2008-02-13 08:07:24 +01:00
kaa@kaamos.(none)
a44413741a Merge mbp:src/opt/bug33389/my51-bug25162
into  kaamos.(none):/data/src/opt/mysql-5.1-opt
2008-02-12 22:51:25 +03:00
kaa@kaamos.(none)
1a67148ccd Merge mbp:src/opt/bug33389/my50-bug25162
into  kaamos.(none):/data/src/opt/mysql-5.0-opt
2008-02-12 22:51:01 +03:00
kaa@mbp.
bc953966c4 Merge mbp.:/Users/kaa/src/opt/bug33389/my50-bug25162
into  mbp.:/Users/kaa/src/opt/bug33389/my51-bug25162
2008-02-12 22:21:33 +03:00
anozdrin/alik@quad.
d36d243d3d Fix for Bug#32538: View definition picks up character set,
but not collation.

The problem here was that text literals in a view were always
dumped with character set introducer. That lead to loosing
collation information.

The fix is to dump character set introducer only if it was
in the original query. That is now possible because there 
is no problem any more of loss of character set of string
literals in views -- after WL#4052 the view is dumped 
in the original character set.
2008-02-12 22:09:16 +03:00
evgen@moonbone.local
f264f92c97 Merge epotemkin@bk-internal.mysql.com:/home/bk/mysql-5.0-opt
into  moonbone.local:/work/31590-bug-5.0-opt-mysql
2008-02-12 21:58:41 +03:00
anozdrin/alik@quad.
d665fc3bd7 Fix for Bug#31222: com_% global status counters
behave randomly with mysql_change_user.
  
The problem was that global status variables were not updated
in THD::check_user(), so thread statistics were lost after
COM_CHANGE_USER.
  
The fix is to update global status variables with the thread ones
before preparing the thread for new user.
2008-02-12 20:59:09 +03:00
mkindahl@dl145h.mysql.com
a3fe485dfe Various fixes to fix memory leaks after merging replication
tree with main.
2008-02-12 18:21:17 +01:00
davi@mysql.com/endora.local
48ac77a95a Bug#23771 AFTER UPDATE trigger not invoked when there are no changes of the data
The problem is that AFTER UPDATE triggers will fire only if the
new data is different from the old data on the row. The trigger
should fire regardless of whether there are changes to the data.

The solution is to fire the trigger on UPDATE even if there are
no changes to the value (because the value is the same).
2008-02-12 09:44:27 -02:00
aelkin/andrei@mysql1000.dsl.inet.fi
0eba2cf0bf Merge mysql1000.dsl.inet.fi:/home/andrei/MySQL/FIXES/5.0/bug32790-assert_mdel_norm_tables
into  mysql1000.dsl.inet.fi:/home/andrei/MySQL/MERGE/pushed.mysql-5.0-rpl-bug33329-extra_rollback
2008-02-12 12:38:55 +02:00
tomas@poseidon.ndb.mysql.com
a4d8864b5e Merge poseidon.ndb.mysql.com:/home/tomas/mysql-5.0-rpl-merge
into  poseidon.ndb.mysql.com:/home/tomas/mysql-5.0-ndb-merge
2008-02-12 11:22:07 +01:00
tomas@poseidon.ndb.mysql.com
3a142141ec Merge poseidon.ndb.mysql.com:/home/tomas/mysql-5.1-rpl-merge
into  poseidon.ndb.mysql.com:/home/tomas/mysql-5.1-new-ndb-merge
2008-02-12 11:21:05 +01:00
kaa@mbp.
97c105cc17 Fix for bug #33389: Selecting from a view into a table from within SP
or trigger crashes server

Under some circumstances a combination of VIEWs, subselects with outer
references and PS/SP/triggers could lead to use of uninitialized memory
and server crash as a result.

Fixed by changing the code in Item_field::fix_fields() so that in cases
when the field is a VIEW reference, we first check whether the field
is also an outer reference, and mark it appropriately before returning.
2008-02-12 12:43:55 +03:00
mkindahl@dl145h.mysql.com
83dac31180 Merge dl145h.mysql.com:/data0/mkindahl/mysql-5.1
into  dl145h.mysql.com:/data0/mkindahl/mysql-5.1-rpl-merge
2008-02-11 18:10:56 +01:00
mkindahl@dl145h.mysql.com
23d670c33e Merge dl145h.mysql.com:/data0/mkindahl/mysql-5.0
into  dl145h.mysql.com:/data0/mkindahl/mysql-5.0-rpl-merge
2008-02-11 18:09:17 +01:00
tomas@poseidon.ndb.mysql.com
832b498e72 Merge poseidon.ndb.mysql.com:/home/tomas/cge-5.1
into  poseidon.ndb.mysql.com:/home/tomas/mysql-5.1-new-ndb-merge
2008-02-11 17:38:34 +01:00
istruewing@stella.local
16be963007 Merge stella.local:/home2/mydev/mysql-5.1-amain
into  stella.local:/home2/mydev/mysql-5.1-axmrg
2008-02-11 12:07:19 +01:00
anozdrin/alik@quad.
524cbe2e4c Disabling declaration of debug variable for non-debug builds.
(originally from Mats)
2008-02-11 14:05:27 +03:00
anozdrin/alik@quad.
a52a30e3e6 Patch to eliminate some valgrind warnings in debug printout code.
(originally from Mats)
2008-02-11 14:04:30 +03:00
mattiasj@client-10-129-10-147.upp.off.mysql.com
2335bfaa5b Bug#20129: ALTER TABLE ... ANALYZE/CHECK/OPTIMIZE/REPAIR PARTITION
Problem was that it did not work with corrupted/crashed tables.

Solution is to disable these commands until WL#4176 is completed
2008-02-11 11:32:46 +01:00
istruewing@stella.local
21534505d0 Merge stella.local:/home2/mydev/mysql-5.0-amain
into  stella.local:/home2/mydev/mysql-5.0-axmrg
2008-02-11 11:19:06 +01:00
aelkin/andrei@mysql1000.dsl.inet.fi
0cd061e98f Merge mysql1000.dsl.inet.fi:/home/andrei/MySQL/FIXES/5.0/bug33329-extra_rollback_when_innodb_in
into  mysql1000.dsl.inet.fi:/home/andrei/MySQL/MERGE/mysql-5.0-rpl-bug33329-extra_rollback
2008-02-11 11:26:02 +02:00
tnurnberg@blasphemy.intern.azundris.com
41461f5dc5 Merge tnurnberg@bk-internal.mysql.com:/home/bk/mysql-5.1-opt
into  mysql.com:/home/tnurnberg/21567/51-21567
2008-02-10 17:08:35 +01:00
tnurnberg@blasphemy.intern.azundris.com
5e23ea7288 Merge tnurnberg@bk-internal.mysql.com:/home/bk/mysql-5.0-opt
into  mysql.com:/home/tnurnberg/21567/50-21567
2008-02-10 16:54:41 +01:00
tnurnberg@blasphemy.intern.azundris.com
f76b9cf63b Merge blasphemy.intern.azundris.com:/home/tnurnberg/21567/50-21567
into  blasphemy.intern.azundris.com:/home/tnurnberg/21567/51-21567
2008-02-10 13:54:59 +01:00
kostja@dipika.(none)
b09af4bef4 Merge bk-internal.mysql.com:/home/bk/mysql-5.1-runtime
into  dipika.(none):/opt/local/work/mysql-5.1-runtime
2008-02-09 14:42:26 +03:00
kostja@dipika.(none)
84713274ba Fix a buffer overflow with strmake(). 2008-02-09 10:31:22 +03:00
malff@lambda.hsd1.co.comcast.net.
20e33c30a0 Fixed buffer overflow 2008-02-08 19:37:57 -07:00
kostja@dipika.(none)
add76ef5d5 Fix -ansi -pedantic compilation error 2008-02-08 19:33:24 +03:00
kostja@dipika.(none)
e9c887cc3d Merge bk-internal.mysql.com:/home/bk/mysql-5.1
into  dipika.(none):/opt/local/work/mysql-5.1-runtime
2008-02-08 18:55:07 +03:00
kostja@dipika.(none)
0e4b6ea058 Merge bk-internal.mysql.com:/home/bk/mysql-5.0
into  dipika.(none):/opt/local/work/mysql-5.0-runtime
2008-02-08 18:51:07 +03:00
kostja@dipika.(none)
d956281e1e Don't complain about a failure to write a log message if we were
simply killed.
2008-02-08 17:25:20 +03:00
gshchepa/uchum@host.loc
919f86fbb6 Merge gshchepa@bk-internal.mysql.com:/home/bk/mysql-5.0-opt
into  host.loc:/home/uchum/work/5.0-opt
2008-02-08 17:04:07 +04:00
kostja@dipika.(none)
209d3d2e18 Merge bk-internal.mysql.com:/home/bk/mysql-5.1-runtime
into  dipika.(none):/opt/local/work/mysql-5.1-runtime
2008-02-08 15:54:21 +03:00
kostja@dipika.(none)
015cdcad4b Silence the slow log errors (they won't make it to the client anyway). 2008-02-08 15:53:57 +03:00
davi@endora.local
9a5e3e103c Merge bk-internal.mysql.com:/home/bk/mysql-5.1-runtime
into  mysql.com:/Users/davi/mysql/mysql-5.1-runtime
2008-02-08 10:48:16 -02:00
davi@mysql.com/endora.local
15409e87d2 Manual merge of Bug 33798 2008-02-08 10:47:25 -02:00
davi@endora.local
31b22496f4 Merge mysql.com:/Users/davi/mysql/mysql-5.0-runtime
into  mysql.com:/Users/davi/mysql/mysql-5.1-runtime
2008-02-08 10:21:58 -02:00
gshchepa/uchum@host.loc
2e9f2b678c Fixed bug#15409: Columns with 64-element SET may not be updated with integers.
SET column storing procedure has been modified to be 64bit-clean.
2008-02-08 16:04:01 +04:00
davi@mysql.com/endora.local
24b9abf36d Bug#33798 prepared statements improperly handle large unsigned ints
The unsignedness of large integer user variables was not being
properly preserved when feeded to prepared statements. This was
happening because the unsigned flags wasn't being updated when
converting the user variable is converted to a parameter.

The solution is to copy the unsigned flag when converting the
user variable to a parameter and take the unsigned flag into
account when converting the integer to a string.
2008-02-08 08:55:55 -02:00
kostja@dipika.(none)
0d4667eb5c Merge bk-internal.mysql.com:/home/bk/mysql-5.1-runtime
into  dipika.(none):/opt/local/work/mysql-5.1-runtime
2008-02-08 13:36:39 +03:00
kostja@dipika.(none)
956e955938 Give a more informative message if we failed to write to mysql.general_log
table.
2008-02-08 13:35:11 +03:00
evgen@sunlight.local
a927bdbe3e Bug#31590: Wrong error message on sort buffer being too small.
The out of memory error was thrown when the sort buffer size were too small.
This led to a user confusion.

Now filesort throws the error message about sort buffer being too small.
2008-02-08 13:35:00 +03:00
mikael@dator6.(none)
6995b41ba2 Merge mronstrom@bk-internal.mysql.com:/home/bk/mysql-5.1-engines
into  dator6.(none):/home/mikael/mysql_clones/mysql-5.1-engines
2008-02-08 00:29:59 +01:00
davi@mysql.com/endora.local
24830674e8 Bug#31891 Meaningful stack trace
On crashes generate a user-friendly resolved and demangled stack
trace when libc provides the necessary functions (newer libc on i386,
x86_64, powerpc, ia64, alpha and s390). Otherwise print a numeric
stack trace as before, relying on resolve_stack_dump utility.
2008-02-07 19:58:06 -02:00
sven@riska.(none)
c33fc69253 WL#4078: Document binary format of binlog entries
Documented Table_map_log_event and packed integer format. Improved
other documentation. No change outside comments.
2008-02-07 19:21:23 +01:00
davi@endora.local
2e0ef9424d Merge mysql.com:/Users/davi/mysql/bugs/32633-5.1
into  mysql.com:/Users/davi/mysql/mysql-5.1-runtime
2008-02-07 16:14:39 -02:00
mikael@dator6.(none)
f0e7ceba50 Merge dator6.(none):/home/mikael/mysql_clones/bug33429
into  dator6.(none):/home/mikael/mysql_clones/mysql-5.1-engines
2008-02-07 16:14:01 +01:00
mikael@dator6.(none)
5855dac773 Merge dator6.(none):/home/mikael/mysql_clones/bug33182
into  dator6.(none):/home/mikael/mysql_clones/mysql-5.1-engines
2008-02-07 16:01:20 +01:00
mattiasj@witty.ndb.mysql.com
dc994bcb90 Merge witty.ndb.mysql.com:/Users/mattiasj/clones/mysql-5.1-bug33379
into  witty.ndb.mysql.com:/Users/mattiasj/clones/51-topush
2008-02-07 15:54:55 +01:00
mattiasj@witty.ndb.mysql.com
11923a5ec2 Merge witty.ndb.mysql.com:/Users/mattiasj/Public/shared-vms/mysql-5.1-bug33379
into  witty.ndb.mysql.com:/Users/mattiasj/clones/51-topush
2008-02-07 15:27:37 +01:00
mattiasj@witty.ndb.mysql.com
d5364e38c5 Bug#34358: Cannot find specified bit row in partitioned table
Problem was incorrect data length in the key_restore function
resulting in overwriting the search key.

Solution, remove one byte in length if uneven bits are used.
2008-02-07 15:09:59 +01:00
mattiasj@witty.local
5d4e9d040e Bug#33379: valgrind error in parts/partition_bit_myisam
Problem was that Field_bit used Field::hash() function that did not
know about using null-byte for storing bits.
Resulting in wrong length, which was caught by valgrind.

Solution: created a Field_bit::hash() that uses Field_bit::val_int()
and my_charset_bin-collation function hash_sort.
Also use the store function for platform independs
2008-02-07 12:28:38 +01:00
davi@mysql.com/endora.local
1c6768c487 Bug#32633 Can not create any routine if SQL_MODE=no_engine_substitution
The problem is that one can not create a stored routine if sql_mode
contains NO_ENGINE_SUBSTITUTION or PAD_CHAR_TO_FULL_LENGTH. Also when
a event is created, the mode is silently lost if sql_mode contains one
of the aforementioned.  This was happening because the table definitions
which stored sql_mode values weren't being updated to accept new values
of sql_mode.

The solution is to update, in a backwards compatible manner, the various
table definitions (columns) that store the sql_mode value to take into
account the new possible values. One incompatible change is that if a event
that is being created can't be stored to the mysql.event table, an error
will be raised.

The tests case also ensure that new SQL modes will be added to the mysql.proc
and mysql.event tables, otherwise the tests will fail.
2008-02-07 08:47:39 -02:00
mkindahl@dl145h.mysql.com
d221197729 Merge dl145h.mysql.com:/data0/mkindahl/mysql-5.1
into  dl145h.mysql.com:/data0/mkindahl/mysql-5.1-rpl
2008-02-07 08:48:31 +01:00
mkindahl@dl145h.mysql.com
507b5907fb Disabling declaration of debug variable for non-debug builds. 2008-02-07 08:41:32 +01:00
mkindahl@dl145h.mysql.com
9b79e4d91c Merge dl145h.mysql.com:/data0/mkindahl/mysql-5.1
into  dl145h.mysql.com:/data0/mkindahl/mysql-5.1-rpl
2008-02-07 07:30:06 +01:00
sergefp@mysql.com
954a16c6d3 BUG#27732 "Possible memory leak with index_merge"
The bug was that handler::clone/handler::ha_open() call caused allocation of 
cloned_copy->ref on the handler->table->mem_root. The allocated memory could not 
be reclaimed until the table is flushed, so it was possible to exhaust memory by 
repeatedly running index_merge queries without doing table flushes.  

The fix:
- make handler::clone() allocate new_handler->ref on the passed mem_root 
- make handler::ha_open() not allocate this->ref if it has already been allocated
There is no testcase as it is not possible to check small leaks from testsuite.
2008-02-07 05:10:04 +03:00
gshchepa/uchum@host.loc
368a8bb442 Merge host.loc:/home/uchum/work/5.0-opt-34223
into  host.loc:/home/uchum/work/5.0-opt
2008-02-07 04:57:21 +04:00
gshchepa/uchum@host.loc
8adc63ad36 Fixed bug#34223: Failure on assignment to my_innodb_autoextend_increment
and my_innodb_commit_concurrency global variables.

Type of the my_innodb_autoextend_increment and the
my_innodb_commit_concurrency variables has been changed to
GET_ULONG.
2008-02-07 04:14:50 +04:00
gshchepa/uchum@host.loc
8715855aa0 Fixed bug#30059.
Server handles truncation for assignment of too-long values
into CHAR/VARCHAR/TEXT columns in a different ways when the
truncated characters are spaces:
1. CHAR(N) columns silently ignore end-space truncation;
2. TEXT columns post a truncation warning/error in the
   non-strict/strict mode.
3. VARCHAR columns always post a truncation note in
   any mode.

Space truncation processing has been synchronised over
CHAR/VARCHAR/TEXT columns: current behavior of VARCHAR
columns has been propagated as standard.

Binary-encoded string/BLOB columns are not affected.
2008-02-07 02:33:21 +04:00
sven@riska.(none)
5746d8790d Merge riska.(none):/home/sven/bk/b34355-backslash_in_path_name_under_win/5.0-rpl
into  riska.(none):/home/sven/bk/b34355-backslash_in_path_name_under_win/5.1-new-rpl
2008-02-06 21:07:45 +01:00
tomas@whalegate.ndb.mysql.com
7376f136e8 Merge whalegate.ndb.mysql.com:/home/tomas/mysql-5.1
into  whalegate.ndb.mysql.com:/home/tomas/mysql-5.1-new-ndb-merge
2008-02-06 16:16:49 +01:00
davi@endora.local
8278d42586 Merge mysql.com:/Users/davi/mysql/bugs/21801-5.1
into  mysql.com:/Users/davi/mysql/mysql-5.1-runtime
2008-02-06 12:50:22 -02:00
mkindahl@dl145h.mysql.com
43f06a0557 Patch to eliminate some valgrind warnings in debug printout code. 2008-02-06 14:44:47 +01:00
davi@mysql.com/endora.local
2af5e25c1d Bug#32710: SHOW INNODB STATUS requires SUPER
Changed "SHOW ENGINE ... STATUS" and "SHOW ENGINE ... MUTEX"
to require the PROCESS privilege, instead of SUPER.

Fixed by Damien Katz
2008-02-06 11:20:15 -02:00
msvensson@pilot.mysql.com
6ee61e1196 Merge pilot.mysql.com:/data/msvensson/mysql/bug19911/my51-bug19911
into  pilot.mysql.com:/data/msvensson/mysql/mysql-5.1-build
2008-02-06 12:52:11 +01:00
msvensson@pilot.mysql.com
784eaab4ec Bug#19911 ndb does not work on sol10 x86 2008-02-06 11:44:07 +01:00
tomas@whalegate.ndb.mysql.com
1fa870fa88 Merge whalegate.ndb.mysql.com:/home/tomas/mysql-5.0
into  whalegate.ndb.mysql.com:/home/tomas/mysql-5.0-ndb-merge
2008-02-06 11:42:18 +01:00
tsmith@ramayana.hindu.god
c99d06a5f3 Merge ramayana.hindu.god:/home/tsmith/m/bk/51
into  ramayana.hindu.god:/home/tsmith/m/bk/build/51
2008-02-05 16:15:07 -07:00
tsmith@ramayana.hindu.god
6726c9e32d Merge ramayana.hindu.god:/home/tsmith/m/bk/50
into  ramayana.hindu.god:/home/tsmith/m/bk/build/50
2008-02-05 16:04:07 -07:00
aelkin/elkin@koti.dsl.inet.fi
51b33ea35d Bug #34305 show slave status handling segfaults when slave io is about
to leave

The artifact was caused by
a flaw in concurrent accessing the slave's io thd by
the io itself and a handling show slave status thread.
Namely, show_master_info did not acquire mi->run_lock mutex that is
specified for mi->io_thd member.

Fixed with deploying the mutex locking and unlocking. The mutex is kept
short time and without interleaving with mi->data_lock mutex.

Todo: to report and fix an issue with 
    sys_var_slave_skip_counter::{methods} 
seem to acquire incorrectly
     active_mi->rli.run_lock
instead of the specified
     active_mi->rli.data_lock

A test case is difficult to compose, so rpl_packet should continue serving
as the indicator.
2008-02-05 17:36:26 +02:00
mkindahl@dl145h.mysql.com
7e0f4a6fa7 Merge mkindahl@bk-internal.mysql.com:/home/bk/mysql-5.1-new-rpl
into  dl145h.mysql.com:/data0/mkindahl/mysql-5.1-rpl
2008-02-05 14:52:20 +01:00
tnurnberg@blasphemy.intern.azundris.com
9928dac5f3 Bug#21567: mysqld doesn't react to Ctrl-C when run under GDB even with the --gdb option
Don't block SIGINT (Control-C) when --gdb is passed to mysqld.
Was broken at least on OS X.

(kudos to Mattias Jonsson)
2008-02-05 12:56:49 +01:00
mkindahl@dl145h.mysql.com
6c6c278e0c Disabling test case binlog_old_version for embedded server. 2008-02-05 08:22:27 +01:00
davi@mysql.com/endora.local
1540830756 Bug#21801 SQL exception handlers and warnings
The problem is that deprecated syntax warnings were not being
suppressed when the stored routine is being parsed for the first
execution. It's doesn't make sense to print out deprecated
syntax warnings when the routine is being executed because this
kind of warning only matters when the routine is being created.

The solution is to suppress deprecated syntax warnings when
parsing the stored routine for loading into the cache (might
mean that the routine is being executed for the first time).
2008-02-04 16:39:55 -02:00
tomas@poseidon.ndb.mysql.com
04c26018a7 Bug #34275 mysqld leak if doing multiple statements within same transaction (or wo/ trans)
- in autocommit do not allocate statistics share, but instead use one directly on the handler
2008-02-04 15:40:04 +01:00
aelkin/elkin@koti.dsl.inet.fi
7880fade24 Bug#33329 extraneous ROLLBACK in binlog on connection
does not use trans tables

There had been two issues.
Rollback statement was recorded in binlog even though a multi-update
had not modified any non-transactional table.
The reason for this artifact was a false initial value of multi_update::transactional_tables.
Yet another artifact that explained on the bug page is that 
`ha_autocommit_or_rollback' works differently depending on whether
a transaction engine has been compiled in. 

Fixed: with setting multi_update::transactional_tables to zero at initialization
time. Multi-update on non-trans table won't cause ROLLBACK in binlog with
either compilation option.

The 2nd mentioned artifact comprises a self-standing issue (to be reported
separately).
2008-02-04 16:37:41 +02:00
aelkin/elkin@koti.dsl.inet.fi
991b48200e Bug #32790 crash in trigger.test with InnoDB for a table
the reason for the failure were incorrect asserts.

Removing asserts altogether as there is no the implication does not hold
(as explained in the comments for the file).
2008-02-04 16:35:41 +02:00
sven@riska.(none)
a25028ef64 Merge riska.(none):/home/sven/bktip/5.1-new-rpl
into  riska.(none):/home/sven/bk/b34141-mysqlbinlog_4.1_binlogs/5.1-new-rpl
2008-02-04 14:37:34 +01:00
mkindahl@dl145h.mysql.com
221ef88c6a Bug #34244 Test ndb_binlog_log_bin fails for 'drop table if
exists t1,t2,t3'
Bug #34245 Test ndb_binlog_multi fails for 'CREATE TABLE'
Bug #34246 Test rpl_ndb_transaction fails with 'Failed to create
           'mysql/ndb_apply_status'

Tests cases didn't wait for cluster to come up due to a typo
in have_multi_ndb.inc.
2008-02-03 11:48:45 +01:00
thek@adventure.(none)
83428ce932 Merge kpettersson@bk-internal.mysql.com:/home/bk/mysql-5.1-runtime
into  adventure.(none):/home/thek/Development/cpp/mysql-5.1-runtime
2008-02-01 17:00:54 +01:00
thek@adventure.(none)
9fc16fbfc0 Merge adventure.(none):/home/thek/Development/cpp/bug33201/my50-bug33201
into  adventure.(none):/home/thek/Development/cpp/bug33201/my51-bug33201
2008-02-01 14:14:37 +01:00
thek@adventure.(none)
323e9a4c53 Bug#33201 Crash occurs when granting update privilege on one column of a view
When issuing a column level grant on a table which require pre-locking the 
server crashed.

The reason behind the crash was that data structures used by the lock api
wasn't properly reinitialized in the case of a column level grant.
2008-02-01 14:10:46 +01:00
anozdrin/alik@quad.
1852fb971e Merge quad.:/mnt/raid/alik/MySQL/devel/5.1
into  quad.:/mnt/raid/alik/MySQL/devel/5.1-rt-merged
2008-02-01 13:55:39 +03:00
anozdrin/alik@quad.
9b4306b8eb Merge quad.:/mnt/raid/alik/MySQL/devel/5.0-rt
into  quad.:/mnt/raid/alik/MySQL/devel/5.1-rt-merged
2008-02-01 13:29:27 +03:00
kaa@mbp.local
e80794b3ee Merge mbp.local:/Users/kaa/src/opt/bug25162/my50-bug25162
into  mbp.local:/Users/kaa/src/opt/mysql-5.0-opt
2008-02-01 13:37:22 +05:00
kaa@mbp.local
663453d572 Fix for bug #25162: Backing up DB from 5.1 adds 'USING BTREE' to KEYs
on table creates

The problem was in incompatible syntax for key definition in CREATE
TABLE.

5.0 supports only the following syntax for key definition (see "CREATE
TABLE syntax" in the manual):

{INDEX|KEY} [index_name] [index_type] (index_col_name,...)

While 5.1 parser supports the above syntax, the "preferred" syntax was
changed to:

{INDEX|KEY} [index_name] (index_col_name,...) [index_type]

The above syntax is used in 5.1 for the SHOW CREATE TABLE output, which
led to dumps generated by 5.1 being incompatible with 5.0.

Fixed by changing the parser in 5.0 to support both 5.0 and 5.1 syntax
for key definition.
2008-02-01 13:00:40 +05:00
evgen@moonbone.local
f967e24718 Bug#30787: Stored function ignores user defined alias.
Simple subselects are pulled into upper selects. This operation substitutes the
pulled subselect for the first item from the select list of the subselect.
If an alias is defined for a subselect it is inherited by the replacement item.
As this is done after fix_fields phase this alias isn't showed if the
replacement item is a stored function. This happens because the Item_func_sp::make_field
function makes send field from its result_field and ignores the defined alias.

Now when an alias is defined the Item_func_sp::make_field function sets it for
the returned field.
2008-01-31 23:46:26 +03:00
holyfoot/hf@hfmain.mysql.com
612b263bbe Merge bk@192.168.21.1:mysql-5.1-opt
into  mysql.com:/home/hf/work/25426/my51-25426
2008-01-31 21:04:00 +04:00
mkindahl@dl145h.mysql.com
4c95b29614 Merge dl145h.mysql.com:/data0/mkindahl/mysql-5.1
into  dl145h.mysql.com:/data0/mkindahl/mysql-5.1-rpl-merge
2008-01-31 17:46:50 +01:00
svoj@april.(none)
6053cfc5e6 Merge mysql.com:/home/svoj/devel/mysql/BUG22989/mysql-5.0-engines
into  mysql.com:/home/svoj/devel/mysql/BUG22989/mysql-5.1-engines
2008-01-31 19:24:24 +04:00
mkindahl@dl145h.mysql.com
7cfdd60045 Merge dl145h.mysql.com:/data0/mkindahl/mysql-5.0
into  dl145h.mysql.com:/data0/mkindahl/mysql-5.0-rpl-merge
2008-01-31 16:15:46 +01:00
aelkin/andrei@mysql1000.(none)
e06d0c7983 Merge mysql1000.(none):/mnt/nb/home/elkin/MySQL/TEAM/FIXES/5.1/bug32971-error_propag_slave
into  mysql1000.(none):/home/andrei/MySQL/FIXES/5.1/bug32971-rbr_error_prop
2008-01-31 17:02:29 +02:00
svoj@mysql.com/april.(none)
3b5c25ba65 BUG#22989 - START SLAVE causes Error on COM_REGISTER_SLAVE: 1105
'Wrong parameters to functi

START SLAVE reports vague error when it fails to register on master:
"Wrong parameters to function register_slave".

If master failed to register slave because of too long
'report-host'/'report-user'/'report-password', return better error
messages:
"Failed to register slave: too long 'report-host'"
"Failed to register slave: too long 'report-user'"
"Failed to register slave; too long 'report-password'"

No test case for this fix.
2008-01-31 18:51:20 +04:00
aelkin/elkin@koti.dsl.inet.fi
c9461608e7 Bug #32971 No user level error message from slave sql thread when ER_NO_DEFAULT_FOR_FIELD
The error message due to lack of the default value for an extra field
was not as informative as it should be.

Fixed with improving the scheme of gathering, propagating and reporting
errors in applying rows events. 
The scheme is in the following.
Any kind of error of processing of a row event incidents are to be 
registered with my_error().
In the end Rows_log_event::do_apply_event() invokes rli->report() with the 
message to display consisting of all the errors.
This mimics `show warnings' displaying.
A simple test checks three errors in processing an event.
Two hunks - a user level error and pushing it into the list - 
have been devoted to already fixed Bug@31702.

Some open issues relating to this artifact listed on BUG@21842 page and
on WL@3679.
Todo: to synchronize the statement in the tests comments on Update and Delete
events may not stop when an extra field does not have a default with wl@3228 spec.
2008-01-31 14:54:03 +02:00
holyfoot/hf@mysql.com/hfmain.(none)
128b9b0727 Bug #25426 Prefix index on DECIMAL column causes warning.
Error message modified to be consistent with the manual.
2008-01-31 15:56:02 +04:00
mkindahl@dl145h.mysql.com
6aacc6415a Merge dl145h.mysql.com:/data0/mkindahl/mysql-5.0-rpl-merge
into  dl145h.mysql.com:/data0/mkindahl/mysql-5.1-rpl-merge
2008-01-31 12:32:48 +01:00
mattiasj@witty.ndb.mysql.com
1dfeec5ced Merge witty.ndb.mysql.com:/Users/mattiasj/clones/mysql-5.1-bug30459
into  witty.ndb.mysql.com:/Users/mattiasj/clones/mysql-5.1-topush
2008-01-31 10:11:19 +01:00
mkindahl@dl145h.mysql.com
b8428d1560 Fixes to make code compile on Windows. 2008-01-31 07:19:29 +01:00
tsmith@ramayana.hindu.god
9965472d43 Merge ramayana.hindu.god:/home/tsmith/m/bk/build/50
into  ramayana.hindu.god:/home/tsmith/m/bk/build/51
2008-01-30 19:00:46 -07:00
tsmith@ramayana.hindu.god
c74959c9e0 Bug #32149 Long semaphore wait for adaptive hash latch
Fix by calling ha_release_temporary_latches() before ::filesort().
2008-01-30 19:00:20 -07:00
kostja@dipika.(none)
917c7952ba Fix a build failure (embedded server). 2008-01-30 23:04:55 +03:00
sven@riska.(none)
772ff3d43a Merge riska.(none):/home/sven/bktip/5.1-new-rpl
into  riska.(none):/home/sven/bk/b32434-version_replication/5.1-new-rpl
2008-01-30 19:40:12 +01:00
mkindahl@dl145h.mysql.com
7552798971 Merge dl145h.mysql.com:/data0/mkindahl/mysql-5.1-rpl
into  dl145h.mysql.com:/data0/mkindahl/mysql-5.1-rpl-merge
2008-01-30 17:46:37 +01:00
mkindahl@dl145h.mysql.com
31355747d2 Fixing return value. 2008-01-30 17:35:25 +01:00
kostja@dipika.(none)
b46ce80902 A fix and a test case for Bug#34166 Server crash in SHOW OPEN TABLES and
pre-locking.

The crash was caused by an implicit assumption in check_table_access() that
table_list parameter is always a part of lex->query_tables.

When iterating over the passed list of tables, check_table_access() used
to stop only when lex->query_tables_last_not_own was reached. 
In case of pre-locking, lex->query_tables_last_own is not NULL and points
to some element of lex->query_tables. When the parameter
of check_table_access() was not part of lex->query_tables, loop invariant
could never be violated and a crash would happen when the current table
pointer would point beyond the end of the provided list.

The fix is to change the signature of check_table_access() to also accept
a numeric limit of loop iterations, similarly to check_grant(), and 
supply this limit in all places when we want to check access of tables
that are outside lex->query_tables, or just want to check access to one table.
2008-01-30 18:27:41 +03:00
mkindahl@dl145h.mysql.com
2a864d1fd7 Merge dl145h.mysql.com:/data0/mkindahl/mysql-5.1-rpl
into  dl145h.mysql.com:/data0/mkindahl/mysql-5.1-rpl-merge
2008-01-30 16:14:14 +01:00
tomas@whalegate.ndb.mysql.com
07fafa2b61 Merge whalegate.ndb.mysql.com:/home/tomas/mysql-5.1
into  whalegate.ndb.mysql.com:/home/tomas/mysql-5.1-new-ndb-merge
2008-01-30 16:08:25 +01:00
mkindahl@dl145h.mysql.com
219a75056a Post-merge changes. 2008-01-30 16:03:00 +01:00
tomas@whalegate.ndb.mysql.com
4c77586d5c Merge whalegate.ndb.mysql.com:/home/tomas/mysql-5.0
into  whalegate.ndb.mysql.com:/home/tomas/mysql-5.0-ndb-merge
2008-01-30 15:36:46 +01:00
sven@riska.(none)
30cd549e3b BUG#34141: mysqlbinlog cannot read 4.1 binlogs containing load data infile
Main problem: mysql 5.1 cannot read binlogs from 4.1.
Subproblem 1: There is a mistake in sql_ex_info::init. The read_str()
function updates its first argument to point to the next character to
read. However, it is applied only to a copy of the buffer pointer, so the
real buffer pointer is not updated.
Fix 1: do not take a copy of the buffer pointer. The copy was needed
because sql_ex_info::init does not use the const attribute on some of its
arguments. So we add the const attribute, too.
Subproblem 2: The first BINLOG statement is asserted to be a
FORMAT_DESCRIPTION_LOG_EVENT, but 4.1 binlogs begin with START_EVENT_V3.
Fix 2: allow START_EVENT_V3 too.
2008-01-30 14:12:40 +01:00
mkindahl@dl145h.mysql.com
018cb16b3a Merge dl145h.mysql.com:/data0/mkindahl/mysql-5.1-rpl
into  dl145h.mysql.com:/data0/mkindahl/mysql-5.1-rpl-merge
2008-01-30 12:53:33 +01:00
gkodinov/kgeorge@macbook.gmz
2eeebda7a4 Merge bk-internal:/home/bk/mysql-5.1-opt
into  macbook.gmz:/Users/kgeorge/mysql/work/B31326-merge-5.1-opt
2008-01-30 13:37:57 +02:00
mkindahl@dl145h.mysql.com
3bcab5899d Merge dl145h.mysql.com:/data0/mkindahl/mysql-5.0-rpl
into  dl145h.mysql.com:/data0/mkindahl/mysql-5.1-rpl
2008-01-30 12:14:14 +01:00
mkindahl@dl145h.mysql.com
716c63ebaa Merge dl145h.mysql.com:/data0/mkindahl/mysql-5.0-rpl
into  dl145h.mysql.com:/data0/mkindahl/mysql-5.0-rpl-merge
2008-01-30 11:25:54 +01:00
hezx@mail.hezx.com
afe8ac3128 Merge zhe@bk-internal.mysql.com:/home/bk/mysql-5.0-rpl
into  mail.hezx.com:/media/sda3/work/mysql/bkwork/bug26489_corruption_in_relay_log/5.0
2008-01-30 16:40:36 +08:00
iggy@alf.(none)
18aba8a82c Bug#31929 Windows build fails with >=4 Parallel build threads.
- Add GenError Dependency to storage engines that include 
mysqld_error.h
2008-01-29 21:58:57 -05:00
sven@riska.(none)
dd913eaaf6 BUG#32434: Replication doesn't work between 5.2.1-a_drop6p9-log and 5.1.22-ndb-6.3.6-telco
Problem: When slave reads format_description_log_event, it checks if the
master is a version that uses an old binlog format. See also BUG#27779.
Not all possible server_versions were listed.
Fix: Check for all server_versions which use the old binlog_format.
2008-01-29 14:47:26 +01:00
kostja@dipika.(none)
928390bf24 Fix Bug#27812 "an ampersand is missed in sql/sql_bitmap.h, line 68" 2008-01-29 14:14:34 +03:00
istruewing@stella.local
4b2312d293 Merge stella.local:/home2/mydev/mysql-5.1-amain
into  stella.local:/home2/mydev/mysql-5.1-axmrg
2008-01-29 10:59:32 +01:00
hezx@mail.hezx.com
e4f37eab56 BUG#26489 Corruption in relay logs
Here is the scenario that causes the failure.(by Mats)

1. The to-be corrupt log event (let's call it X), is split into two
   packets B and C on the network level (net_write_buff()). The parts
   are X = (x',x''). The part x' ends up in packet B and part x''
   ends up in packet C. Prior to the corrupt event X, the event Y has
   been written successfully, but has been split into two packets as
   well, which we call (y',y'').
2. The master sends packet A = (y'',x') to the slave, increases the
   packet sequence number, the slave receives the packet, but fails
   to reply before the master gets a timeout.
3. Since the master got a timeout, it reports failure, and aborts
   sending the binary log by exiting mysql_binlog_send(). However, it
   leaves the buffer intact, still holding y'' (but not x', since the
   write_pos is not increased).
4. After exiting mysql_binlog_send(), the master does a
   disconnection of the client thread, which involves sending an
   error message e to the client (i.e., the slave).
5. In this case, net_write_buff() is used again, but this time the
   old contents of the packet is used so that the new packet is
   D = (y'',e). Note that this will use a new packet sequence number,
   since the packet number was increased in step 2.
6. The slave receives the tail y'' of the Y log event, concatenates
   this with x' (which it already received), and writes the event
   (x',y'') it to the relay log since it hasn't noticed anything is
   amiss.
7. It then tries to read more bytes, which is either e (if the length
   given for X just happened to match the length given for Y, or just
   plain garbage because the slave is out of sync with what is
   actually sent.
8. After a while, the SQL thread tries to execute the event (x',y''),
   which is very likely to be just nonsense.

The problem can be fixed by not resetting net->error after the call of 
mysql_binlog_send, so the error message will not be sent and the connection
will be closed.
2008-01-29 11:56:48 +08:00
mikael@dator6.(none)
8de834fc6a BUG#33182: Disallow division due to div_precision_increment problems 2008-01-28 22:05:25 +01:00
mikael@dator6.(none)
159b509cab BUG#33429: No check for maxvalue before adding partition 2008-01-28 16:11:43 +01:00
mikael@dator6.(none)
53546f51f5 BUG#32943: Fixed buggy lock handling of ALTER TABLE for partitioning 2008-01-28 15:20:55 +01:00
joerg@trift2.
a6f257361e Merge trift2.:/MySQL/M50/mysql-5.0
into  trift2.:/MySQL/M50/push-5.0
2008-01-28 15:05:33 +01:00
igor@olga.mysql.com
5e14047e23 Fixed bug #33833.
Two disjuncts containing equalities of the form key=const1 and key=const2 can
be merged into one if const1 is equal to const2. To check it the common 
collation of the constants were used rather than the collation of the field key.
For example when the default collation of the constants was cases insensitive
while the collation of the field was case sensitive, then two or-ed equality 
predicates key='b' and key='B' incorrectly were merged into one f='b'. As a 
result ref access was used instead of range access and wrong result sets were 
returned in many cases. 
Fixed the problem by comparing constant in the or-ed predicate with collation of
the key field.
2008-01-26 21:45:35 -08:00
acurtis/antony@ltamd64.xiphis.org
e70f8dc417 Merge xiphis.org:/anubis/antony/work/bug33358.2
into  xiphis.org:/anubis/antony/work/bug33358.2-merge-5.1
2008-01-26 02:16:29 -08:00
acurtis/antony@xiphis.org/ltamd64.xiphis.org
82839a0bbb fixes to make pushbuild tests green 2008-01-26 02:13:35 -08:00
acurtis/antony@ltamd64.xiphis.org
8629f2e313 Merge xiphis.org:/anubis/antony/work/bug33358.2
into  xiphis.org:/anubis/antony/work/bug33358.2-merge-5.1
2008-01-25 17:38:24 -08:00
acurtis/antony@xiphis.org/ltamd64.xiphis.org
98515df213 Bug#33358
"Plugin enum variables can't be set from command line"
  fix crash of LOCK_plugins mutex when loading plug-ins from command line.
  fix off-by-one bug when loading multiple plug-ins from the command line.
  initialize command line handling for ENUM and SET plugin variable types.
2008-01-25 16:05:15 -08:00
tsmith@ramayana.hindu.god
3906cc27d7 Merge ramayana.hindu.god:/home/tsmith/m/bk/51
into  ramayana.hindu.god:/home/tsmith/m/bk/maint/51
2008-01-25 10:37:29 -07:00
tsmith@ramayana.hindu.god
f522912d20 Merge ramayana.hindu.god:/home/tsmith/m/bk/50
into  ramayana.hindu.god:/home/tsmith/m/bk/maint/50
2008-01-25 10:03:15 -07:00
mskold/marty@quadfish.(none)
1715bb188d Merge mskold@bk-internal.mysql.com:/home/bk/mysql-5.1-new-ndb
into  mysql.com:/home/marty/MySQL/mysql-5.1-new-ndb
2008-01-25 14:34:15 +01:00
hezx@mail.hezx.com
750c4022f2 BUG#33862 completely failed DROP USER statement gets replicated
The problem is when create/rename/drop users, the statement was logged regardless of error, even if no data has been changed, the statement was logged.

After this patch, create/rename/drop users don't write the binlog if the statement makes no changes, if the statement does make any changes, log the statement with possible error code.

This patch is based on the patch for BUG#29749, which is not pushed
2008-01-25 15:02:26 +08:00
istruewing@stella.local
a07d4d72f5 Merge stella.local:/home2/mydev/mysql-5.1-amain
into  stella.local:/home2/mydev/mysql-5.1-axmrg
2008-01-24 20:06:03 +01:00
anozdrin/alik@quad.
5ff7860f69 Merge quad.:/mnt/raid/alik/MySQL/devel/5.1
into  quad.:/mnt/raid/alik/MySQL/devel/5.1-rt-merged-5.0-rt
2008-01-24 17:40:16 +03:00
anozdrin/alik@quad.
1c1401bbb2 Merge quad.:/mnt/raid/alik/MySQL/devel/5.0
into  quad.:/mnt/raid/alik/MySQL/devel/5.0-rt-merged-5.0
2008-01-24 17:37:16 +03:00
tsmith@ramayana.hindu.god
fa257c031c Applied innodb-5.0-ss2223 snapshot
Fixes:

Bug #32083: server crashes on show status when InnoDB is not initialized
  innodb_export_status(): Check that InnoDB has been initialized
  before invoking srv_export_innodb_status().  (Bug #32083)
  This bug does not exist in MySQL/InnoDB 5.1.
2008-01-23 18:20:04 -07:00
malff@lambda.hsd1.co.comcast.net.
e685e7e354 Manual merge 2008-01-23 16:21:09 -07:00
malff@lambda.hsd1.co.comcast.net.
ec6c4fad89 Merge lambda.hsd1.co.comcast.net.:/home/malff/TREE/mysql-5.0-33618
into  lambda.hsd1.co.comcast.net.:/home/malff/TREE/mysql-5.1-33618
2008-01-23 15:36:57 -07:00
malff@lambda.hsd1.co.comcast.net.
1eecc24a21 Merge malff@bk-internal.mysql.com:/home/bk/mysql-5.0-runtime
into  lambda.hsd1.co.comcast.net.:/home/malff/TREE/mysql-5.0-33618
2008-01-23 14:04:46 -07:00
malff@lambda.hsd1.co.comcast.net.
c3ad0cac75 Bug#33618 (Crash in sp_rcontext)
Bug 33983 (Stored Procedures: wrong end <label> syntax is accepted)

The server used to crash when REPEAT or another control instruction
was used in conjunction with labels and a LEAVE instruction.

The crash was caused by a missing "pop" of handlers or cursors in the
code representing the stored program. When executing the code in a loop,
this missing "pop" would result in a stack overflow, corrupting memory.

Code generation has been fixed to produce the missing h_pop/c_pop
instructions.

Also, the logic checking that labels at the beginning and the end of a
statement are matched was incorrect, causing Bug 33983.
End labels, when used, must match the label used at the beginning of a block.
2008-01-23 13:26:41 -07:00
tomas@whalegate.ndb.mysql.com
b422aed975 Merge whalegate.ndb.mysql.com:/home/tomas/mysql-5.0-ndb
into  whalegate.ndb.mysql.com:/home/tomas/mysql-5.0-ndb-merge
2008-01-23 15:07:18 +01:00
tomas@whalegate.ndb.mysql.com
f7da069744 Merge whalegate.ndb.mysql.com:/home/tomas/mysql-5.1
into  whalegate.ndb.mysql.com:/home/tomas/mysql-5.1-new-ndb-merge
2008-01-23 14:58:42 +01:00
mskold/marty@mysql.com/quadfish.(none)
35d3bef712 Ndb.hpp, Ndb.cpp, ha_ndbcluster.cc:
Add a check if setting an auto_increment field will change it's next value before retrieving tuple_id_range lock. This avoids hitting locks when updating auto_increment values to a lower value than the current maximum. This is useful in loading a table with auto_increment where one loads the highest numbered pk's first and then proceeds backwards to the first. This can then be achieved with the same performance as a normal insert without auto_increment.
ndb_restore.result:
  Updated result file
2008-01-23 11:40:06 +01:00
tsmith@ramayana.hindu.god
6668554a8d Merge ramayana.hindu.god:/home/tsmith/m/bk/51
into  ramayana.hindu.god:/home/tsmith/m/bk/maint/51
2008-01-22 15:56:15 -07:00
tsmith@ramayana.hindu.god
8287a4f27b Merge ramayana.hindu.god:/home/tsmith/m/bk/50
into  ramayana.hindu.god:/home/tsmith/m/bk/maint/50
2008-01-22 15:44:18 -07:00
anozdrin/alik@ibm.
baf5f73853 Merge ibm.:/home/alik/Documents/MySQL/devel/5.1
into  ibm.:/home/alik/Documents/MySQL/devel/5.1-rt-merged-5.1
2008-01-19 22:32:48 +03:00
kaa@kaamos.(none)
e91bf15d5c Merge kaamos.(none):/data/src/opt/mysql-5.0-opt
into  kaamos.(none):/data/src/opt/mysql-5.1-opt
2008-01-19 21:09:22 +03:00
mhansson@lamia.dupka
e3e370dd9d Merge mhansson@bk-internal.mysql.com:/home/bk/mysql-5.0-opt
into  lamia.dupka:/home/mhansson/my50-bug33143-again-pushee
2008-01-18 22:45:14 +02:00
sergefp@mysql.com
d56ac2f37b BUG#33794 "MySQL crashes executing specific query":
The problem occurred when one had a subquery that had an equality X=Y where 
Y referred to a named select list expression from the parent select. MySQL 
crashed when trying to use the X=Y equality for ref-based access. 

Fixed by allowing non-Item_field items in the described case.
2008-01-18 22:50:36 +03:00
mhansson/martin@linux-st28.site
f8fb6e930a Merge mhansson@bk-internal:/home/bk/mysql-5.1-opt
into  linux-st28.site:/home/martin/mysql/src/bug33143/my51-bug33143-pushee
2008-01-17 18:36:04 +01:00
mhansson/martin@linux-st28.site
2067dfe474 Merge linux-st28.site:/home/martin/mysql/src/bug33143/my50-bug33143-again
into  linux-st28.site:/home/martin/mysql/src/bug33143/my51-bug33143
2008-01-17 18:22:55 +01:00
mhansson/martin@linux-st28.site
7207d3ce21 Merge mhansson@bk-internal:/home/bk/mysql-5.0-opt
into  linux-st28.site:/home/martin/mysql/src/bug33143/my50-bug33143-again-pushee
2008-01-17 18:15:53 +01:00
kostja@dipika.(none)
8aa978352e A minor cleanup. 2008-01-16 16:44:07 +03:00
msvensson@pilot.mysql.com
ea0cecc5f0 Bug#33375 all_set corrupted on table object
- make sure to reset the read and write sets


handler.cc, log_event.cc:
  - make sure to reset the read and write sets
2008-01-15 17:01:58 +01:00
istruewing@stella.local
4c22def786 Merge stella.local:/home2/mydev/mysql-5.1-amain
into  stella.local:/home2/mydev/mysql-5.1-axmrg
2008-01-15 10:23:17 +01:00
sven@riska.(none)
2cd6432da3 Merge riska.(none):/home/sven/bkgca/5.1-new-rpl
into  riska.(none):/home/sven/bk/b27779-old_row_events/5.1-new-rpl
2008-01-14 16:48:04 +01:00
mhansson/martin@linux-st28.site
effe27e350 Bug#33143: Incorrect ORDER BY for ROUND()/TRUNCATE() result
The ROUND(X, D) function would change the Item::decimals field during
execution to achieve the effect of a dynamic number of decimal digits.
This caused a series of bugs:
Bug #30617:Round() function not working under some circumstances in InnoDB
Bug #33402:ROUND with decimal and non-constant cannot round to 0 decimal places
Bug #30889:filesort and order by with float/numeric crashes server
Fixed by never changing the number of shown digits for DECIMAL when
used with a nonconstant number of decimal digits.
2008-01-14 16:16:36 +01:00
mhansson@lamia.dupka
8eb74b1f5f Merge mhansson@bk-internal.mysql.com:/home/bk/mysql-5.0-opt
into  lamia.dupka:/home/mhansson/my50-bug31797-pushee
2008-01-12 18:59:05 +02:00
mhansson@lamia.dupka
deacf8b37f Merge mhansson@bk-internal.mysql.com:/home/bk/mysql-5.1-opt
into  lamia.dupka:/home/mhansson/my51-bug31797-pushee
2008-01-11 23:09:34 +02:00
mhansson/martin@linux-st28.site
481a96930c Merge mhansson@bk-internal:/home/bk/mysql-5.1-opt
into  linux-st28.site:/home/martin/mysql/src/bug31797/my51-bug31797-pushee
2008-01-11 19:39:28 +01:00
mhansson/martin@linux-st28.site
afc6a369f3 Merge linux-st28.site:/home/martin/mysql/src/bug31797/my50-bug31797
into  linux-st28.site:/home/martin/mysql/src/bug31797/my51-bug31797
2008-01-11 19:13:07 +01:00
igor@olga.mysql.com
947715c228 Merge olga.mysql.com:/home/igor/mysql-5.1-opt
into  olga.mysql.com:/home/igor/dev-opt/mysql-5.1-opt-bug33697
2008-01-11 10:12:29 -08:00
igor@olga.mysql.com
b85ffdb5d5 Fixed bug #33697.
When the function test_if_skip_sort_order prefers index backward scan 
to ref access the corresponding access functions must be set accordingly.
2008-01-11 10:05:34 -08:00
mhansson/martin@linux-st28.site
e24109c6d1 Merge mhansson@bk-internal:/home/bk/mysql-5.0-opt
into  linux-st28.site:/home/martin/mysql/src/bug31797/my50-bug31797-pushee
2008-01-11 19:00:26 +01:00
mhansson/martin@linux-st28.site
199a167246 Bug#31797: error while parsing subqueries -- WHERE is parsed as HAVING
The name resolution for correlated subqueries and HAVING clauses
failed to distinguish which of two was being performed when there 
was a reference to an outer aliased field.
Fixed by adding the condition that HAVING clause name resulotion
is being performed.
2008-01-11 18:50:54 +01:00
gshchepa/uchum@host.loc
17c5117872 Merge host.loc:/home/uchum/work/5.1-opt-33699
into  host.loc:/home/uchum/work/5.1-opt
2008-01-11 21:39:45 +04:00
evgen@moonbone.local
baaf300d4c Bug#29477: Not all fields of the target table were checked to have a default
value when inserting into a view.

The mysql_prepare_insert function checks all fields of the target table that
directly or indirectly (through a view) are specified in the INSERT
statement to have a default value. This check can be skipped if the INSERT
statement doesn't mention any insert fields. In case of a view this allows
fields that aren't mentioned in the view to bypass the check.

Now fields of the target table are always checked to have a default value
when insert goes into a view.
2008-01-11 20:10:54 +03:00
mkindahl@dl145h.mysql.com
940ecc23c6 Merge dl145h.mysql.com:/data0/mkindahl/mysql-5.1-rpl
into  dl145h.mysql.com:/data0/mkindahl/mysql-5.1-rpl-merge
2008-01-11 14:20:06 +01:00
gshchepa/uchum@host.loc
32d13ab23d Bug#33699: The UPDATE statement allows NULL as new value on a NOT NULL
columns (default datatype value is assigned).

The mysql_update function has been modified to generate
an error when trying to set a NOT NULL field to NULL rather than a warning
in the set_field_to_null_with_conversions function.
2008-01-11 05:06:08 +04:00
kaa@kaamos.(none)
0cec5f8e4b Merge kaamos.(none):/data/src/mysql-5.1
into  kaamos.(none):/data/src/opt/mysql-5.1-opt
2008-01-10 20:44:23 +03:00
kaa@kaamos.(none)
f8ade5e91b Merge kaamos.(none):/data/src/mysql-5.0
into  kaamos.(none):/data/src/opt/mysql-5.0-opt
2008-01-10 20:43:05 +03:00
epotemkin@bk-internal.mysql.com
a714053711 Merge bk-internal.mysql.com:/data0/bk/mysql-5.0-opt
into  bk-internal.mysql.com:/data0/bk/mysql-5.1-opt
2008-01-10 18:03:26 +01:00
evgen@moonbone.local
830b8f0e30 filesort.cc:
Bug#33675: Usage of an uninitialized memory by filesort in a subquery caused
  server crash.
  Free smaller buffer before allocating bigger one.
2008-01-10 18:54:34 +03:00
sven@riska.(none)
617ea4d631 BUG#27779: Slave cannot read old rows log events.
Problem: Replication fails when master is mysql-5.1-wl2325-5.0-drop6 and
slave is mysql-5.1-new-rpl. The reason is that, in
mysql-5.1-wl2325-5.0-drop6, the event type id's were different than in
mysql-5.1-new-rpl.
Fix (in mysql-5.1-new-rpl):
 (1) detect that the server that generated the events uses the old
format, by checking the server version of the format_description_log_event
This patch recognizes mysql-5.1-wl2325-5.0-drop6p13-alpha,
mysql-5.1-wl2325-5.0-drop6, mysql-5.1-wl2325-5.0, mysql-5.1-wl2325-no-dd.
 (2) if the generating server is old, map old event types to new event
types using a permutation array.

I've also added a test case which reads binlogs for four different
versions.
2008-01-10 16:39:44 +01:00
kaa@kaamos.(none)
e11a62776d Post-merge fix after merging 5.0 -> 5.1. Replaced 'byte' with 'uchar'. 2008-01-10 15:07:55 +03:00
gni@dev3-221.dev.cn.tlan
0b1d727be7 Merge dev3-221.dev.cn.tlan:/home/ngb/mysql/mysql-5.0/mysql-5.0-ndb
into  dev3-221.dev.cn.tlan:/home/ngb/mysql/mysql-5.0/mysql-5.0-ndb-bj
2008-01-10 20:04:21 +08:00
kaa@kaamos.(none)
36773c170d Merge kaamos.(none):/data/src/opt/mysql-5.0-opt
into  kaamos.(none):/data/src/opt/mysql-5.1-opt
2008-01-10 14:35:11 +03:00
evgen@moonbone.local
165dfa3eba Merge epotemkin@bk-internal.mysql.com:/home/bk/mysql-5.0-opt
into  moonbone.local:/work/33675-bug-5.0-opt-mysql
2008-01-09 23:19:46 +03:00
gkodinov/kgeorge@macbook.gmz
83012461f0 Merge macbook.gmz:/Users/kgeorge/mysql/work/B33133-5.0-opt
into  macbook.gmz:/Users/kgeorge/mysql/work/B33133-5.1-opt
2008-01-09 17:10:09 +02:00
gkodinov/kgeorge@magare.gmz
5a01be841a Merge gkodinov@bk-internal.mysql.com:/home/bk/mysql-5.0-opt
into  magare.gmz:/home/kgeorge/mysql/autopush/B33133-5.0-opt
2008-01-09 16:52:11 +02:00
gkodinov/kgeorge@macbook.gmz
2fc45f017d Bug #33133: Views are not transparent
When resolving references we need to take into consideration
the view "fields" and allow qualified access to them.
Fixed by extending the reference resolution to process view
fields correctly.
2008-01-09 16:49:13 +02:00
mattiasj@client-10-129-10-137.upp.off.mysql.com
a6a9774849 Bug#31931 Partitions: unjustified 'mix of handlers' error message
Problem was that the mix of handlers was not consistent between
CREATE and ALTER

changed so that it works like:
    - All partitions must use the same engine
      AND it must be the same as the table.
    - if one does NOT specify an engine on the table level
      then one must either NOT specify any engine on any
      partition/subpartition OR for ALL partitions/subpartitions

Note: that after a table have been created, the storage engine
is specified for all parts of the table (table/partition/subpartition)
and so when using alter, one does not need to specify it (unless one
wants to change the storage engine, then one have to specify it on the
table level)
2008-01-09 13:15:50 +01:00
mats@capulet.kindahl.net
6e94fb84ae Post-merge fixes to make tests pass. 2008-01-09 12:55:04 +01:00
gni@dev3-221.dev.cn.tlan
37a64e5cbf Merge gni@bk-internal.mysql.com:/home/bk/mysql-5.0-ndb-bj
into  dev3-221.dev.cn.tlan:/home/ngb/mysql/mysql-5.0/bug29851
2008-01-09 11:17:50 +08:00
evgen@moonbone.local
ce111a0d73 Bug#33675: Usage of an uninitialized memory by filesort in a subquery caused
server crash.

The filesort implementation has an optimization for subquery execution which
consists of reusing previously allocated buffers. In particular the call to
the read_buffpek_from_file function might be skipped when a big enough buffer
for buffer descriptors (buffpeks) is already allocated. Beside allocating
memory for buffpeks this function fills allocated buffer with data read from
disk. Skipping it might led to using an arbitrary memory as fields' data and
finally to a crash.

Now the read_buffpek_from_file function is always called. It allocates
new buffer only when necessary, but always fill it with correct data.
2008-01-09 00:40:41 +03:00
jperkin/jonathan@chorlton.adsl.perkin.org.uk
cb00c20749 Merge chorlton.adsl.perkin.org.uk:/Users/jonathan/work/bk/bug-31736-5.1
into  chorlton.adsl.perkin.org.uk:/Users/jonathan/mysql/bk/bug-31736/5.1
2008-01-08 14:04:03 +00:00
gkodinov/kgeorge@macbook.gmz
5b9e61b282 merge of bug 33256 5.0-opt -> 5.1-opt 2008-01-08 12:27:15 +02:00
gkodinov/kgeorge@macbook.gmz
2710053416 Merge macbook.gmz:/Users/kgeorge/mysql/work/B33256-5.0-opt
into  macbook.gmz:/Users/kgeorge/mysql/work/B33256-5.1-opt
2008-01-08 11:49:40 +02:00
gkodinov/kgeorge@magare.gmz
7fe932ed82 Merge gkodinov@bk-internal.mysql.com:/home/bk/mysql-5.0-opt
into  magare.gmz:/home/kgeorge/mysql/autopush/B33256-5.0-opt
2008-01-07 18:55:05 +02:00
hezx@mail.hezx.com
87abfe06e3 Replace one overlooked return with DBUG_RETURN in function log_loaded_block 2008-01-06 20:16:28 +08:00
tsmith@ramayana.hindu.god
68980477dd Merge ramayana.hindu.god:/home/tsmith/m/bk/51
into  ramayana.hindu.god:/home/tsmith/m/bk/maint/51
2008-01-04 19:59:37 -07:00
tsmith@ramayana.hindu.god
e122756433 Merge ramayana.hindu.god:/home/tsmith/m/bk/50
into  ramayana.hindu.god:/home/tsmith/m/bk/maint/50
2008-01-04 19:59:01 -07:00
tomas@whalegate.ndb.mysql.com
8db7aebcee Merge whalegate.ndb.mysql.com:/home/tomas/cge-5.1
into  whalegate.ndb.mysql.com:/home/tomas/mysql-5.1-new-ndb-merge
2008-01-04 16:01:36 +01:00
mattiasj@witty.
5d6a65bb50 Bug#30459 Partitioning across disks failing on Windows
Problem was that there are no support for symlinked files on Windows for
mysqld. So we fail when trying to create them.

Solution: Ignore the DATA/INDEX DIRECTORY clause for partitions and push
a warning. (Just like a MyISAM table)
2008-01-04 12:06:20 +01:00
thek@adventure.(none)
2a499f757d Merge adventure.(none):/home/thek/Development/cpp/bug30887/my51-bug30887
into  adventure.(none):/home/thek/Development/cpp/mysql-5.1-runtime
2008-01-03 15:37:54 +01:00
thek@adventure.(none)
96146a392f Bug#30887 Server crashes on SET GLOBAL query_cache_size=0
Reseting the query cache by issuing a SET GLOBAL query_cache_size=0 caused the server
to crash if a the server concurrently was saving a new result set to the query cache. The
reason for this was that the invalidation wasn't waiting on the result writers to
release the block level locks on the query cache.
2008-01-03 15:36:48 +01:00
sven@riska.(none)
72676b226b Merge ssandberg@bk-internal.mysql.com:/home/bk/mysql-5.0-rpl
into  riska.(none):/home/sven/bk/b26395-autocommit-xa/5.0-rpl
2008-01-02 14:23:14 +01:00
jperkin/jonathan@chorlton.adsl.perkin.org.uk
e286ac998c Use pkglibdir to simplify pkgplugindir, and fix the path in a
couple of Makefiles.  Continuation of the fix for bug#31736.
2008-01-02 13:00:46 +00:00
istruewing@stella.local
6836db1cee Merge stella.local:/home2/mydev/mysql-5.1-amain
into  stella.local:/home2/mydev/mysql-5.1-axmrg
2007-12-24 13:07:01 +01:00
hezx@mail.hezx.com
6cab71d3fa Merge mail.hezx.com:/media/sda3/work/mysql/bkwork/bug#28908/5.0
into  mail.hezx.com:/media/sda3/work/mysql/bkwork/bug#28908/5.1
2007-12-24 14:55:59 +08:00
hezx@mail.hezx.com
d501c40629 Merge mail.hezx.com:/media/sda3/work/mysql/bkwork/bug#28908/5.0
into  mail.hezx.com:/media/sda3/work/mysql/bkwork/bug#28908/mysql-5.0-rpl
2007-12-24 11:08:39 +08:00
aelkin/elkin@koti.dsl.inet.fi
7801f29041 Merge aelkin@bk-internal.mysql.com:/home/bk/mysql-5.0-rpl
into  koti.dsl.inet.fi:/home/elkin/MySQL/TEAM/FIXES/5.0/bug33435-load_data_read_buffer_size
2007-12-21 22:37:10 +02:00
aelkin/elkin@koti.dsl.inet.fi
0ca3250e59 BUG#30435 loading large LOAD DATA INFILE breaks slave with
read_buffer_size set on master
BUG#33413 show binlog events fails if binlog has event size of close
          to max_allowed_packet


The size of Append_block replication event was determined solely by
read_buffer_size whereas the rest of replication code deals with
max_allowed_packet.
When the former parameter was set to larger than the latter there were
two artifacts: the master could not read events from binlog;
show master events did not show.

Fixed with 
- fragmenting the used io-cached buffer into pieces each size of less
  than max_allowed_packet (bug#30435)
- incrementing show-binlog-events handling thread's max_allowed_packet
  with the max estimated for the replication header size
2007-12-21 22:34:43 +02:00
sven@riska.(none)
25d53f907c BUG#26395: if crash during autocommit update to transactional table on master, slave fails
Now, every transaction (including autocommit transactions) start with
a BEGIN and end with a COMMIT/ROLLBACK in the binlog.
Added a test case, and updated lots of test case result files.
2007-12-21 20:30:23 +01:00
mhansson/martin@linux-st28.site
8b65423d9d Merge mhansson@bk-internal:/home/bk/mysql-5.1-opt
into  linux-st28.site:/home/martin/mysql/src/bug32848/my51-bug32848
2007-12-21 14:52:39 +01:00
aelkin/elkin@koti.dsl.inet.fi
3624851643 Merge aelkin@bk-internal.mysql.com:/home/bk/mysql-5.0-rpl
into  koti.dsl.inet.fi:/home/elkin/MySQL/TEAM/FIXES/5.0/bug31359-future_gpos
2007-12-21 15:44:06 +02:00
joerg@trift2.
a0fbcc0326 Merge trift2.:/MySQL/M50/merge-5.0
into  trift2.:/MySQL/M51/push-5.1
2007-12-21 13:13:22 +01:00
joerg@trift2.
bf1ba3d416 Merge trift2.:/MySQL/M50/clone-5.0
into  trift2.:/MySQL/M50/merge-5.0
2007-12-21 12:48:14 +01:00
serg@janus.mylan
bf95cf1604 Merge janus.mylan:/usr/home/serg/Abk/mysql-5.0
into  janus.mylan:/usr/home/serg/Abk/mysql-5.1
2007-12-21 12:02:49 +01:00
gkodinov/kgeorge@macbook.gmz
e4efb4a521 Bug #33256: CREATE ... SELECT creates obsolete table
w/ Field_date instead of Field_newdate
  
Field_date was still used in temp table creation.
Fixed by using Field_newdate consistently throughout the server
except when reading tables defined with older MySQL version.
No test suite is possible because both Field_date and Field_newdate
return the same values in all the metadata calls.
2007-12-21 12:44:24 +02:00
serg@janus.mylan
baf53c8524 cast corrected 2007-12-21 11:28:34 +01:00
serg@janus.mylan
f8afc538fe Merge janus.mylan:/usr/home/serg/Abk/mysql-5.0
into  janus.mylan:/usr/home/serg/Abk/mysql-5.1
2007-12-21 10:59:14 +01:00
hezx@mail.hezx.com
2b4bc3e93c Merge mail.hezx.com:/media/sda3/work/mysql/bkroot/mysql-5.0-rpl
into  mail.hezx.com:/media/sda3/work/mysql/bkwork/bug#28908/5.0
2007-12-21 17:52:25 +08:00
serg@janus.mylan
97754ffae7 warning on windows 2007-12-21 10:31:47 +01:00
aelkin/elkin@koti.dsl.inet.fi
1032038579 Bug #31359 change_master sets group_master_log_pos twice,
ignores future_group_master_log_p

There was a redundant assignement. However, that's the only artifact.
Wrt to future_group_master_log_position, there is no issue.
The counter is supposed to be set at Log_event::exec_event().
It's used only by Innodb for recovery purposes.
2007-12-21 10:13:54 +02:00
mats@capulet.kindahl.net
1666ecf070 Merge capulet.kindahl.net:/home/mats/devel/b12691-mysql-5.0-rpl
into  capulet.kindahl.net:/home/mats/devel/fix-mysql-5.0-rpl
2007-12-21 07:52:07 +01:00
hezx@mail.hezx.com
329d1a7bf7 BUG#28908 Replication: set global server_id is not setting the session server_id
When set the server-id dynamically, the server_id member of current thread is not updated.

Update the server_id member of current thread after updated the global variable value.
2007-12-21 11:02:48 +08:00
serg@janus.mylan
7b6e89ee39 after merge fix in mysqld.cc:
added missing status variables (assert works! :)
2007-12-21 00:00:28 +01:00
serg@janus.mylan
d9ca7b670e Merge bk-internal.mysql.com:/home/bk/mysql-5.1-maint
into  janus.mylan:/usr/home/serg/Abk/mysql-5.1
2007-12-20 22:11:37 +01:00
dkatz@damien-katzs-computer.local
4b8c6e4913 Bug #29836 enable-pstack option appears even if --with-pstack is disabled
Placed all pstack code inside of #ifdef's, so the options aren't displayed when not available.
2007-12-20 15:32:56 -05:00
kostja@bodhi.(none)
dfe685e6fc A pre-requisite for the fix for Bug#12713 "Error in a stored function
called from a SELECT doesn't cause ROLLBACK of state"
Make private all class handler methods (PSEA API) that may modify
data. Introduce and deploy public ha_* wrappers for these methods in 
all sql/.
This necessary to keep track of all data modifications in sql/,
which is in turn necessary to be able to optimize two-phase
commit of those transactions that do not modify data.
2007-12-20 21:16:55 +03:00
mats@capulet.kindahl.net
f1c32705f1 BUG#12691 (Exec_master_log_pos corrupted with SQL_SLAVE_SKIP_COUNTER):
Complementary patch since LOAD DATA INFILE was not covered in
the previous patch.

This patch adds a check so that the slave skip counter is not
decreased to zero if seeing a BEGIN_LOAD_QUERY_EVENT,
APPEND_BLOCK_EVENT, or CREATE_FILE_EVENT since these cannot
end a group. The group is terminated by an EXECUTE_LOAD_QUERY_
EVENT or DELETE_FILE_EVENT.
2007-12-20 16:07:54 +01:00
mhansson/martin@linux-st28.site
fe93176c30 Merge linux-st28.site:/home/martin/mysql/src/bug32848/my50-bug32848-gca
into  linux-st28.site:/home/martin/mysql/src/bug32848/my51-bug32848-gca
2007-12-20 14:19:52 +01:00
tnurnberg@white.intern.koehntopp.de
22d1a50d5c Merge tnurnberg@bk-internal.mysql.com:/home/bk/mysql-5.0-opt
into  mysql.com:/misc/mysql/31990/50-31990
2007-12-20 13:42:50 +01:00
mhansson/martin@linux-st28.site
284d8c71ee Merge mhansson@bk-internal:/home/bk/mysql-5.0-opt
into  linux-st28.site:/home/martin/mysql/src/bug32848/my50-bug32848
2007-12-20 11:24:42 +01:00
mhansson/martin@linux-st28.site
6f6e18809a Bug#32848: Data type conversion bug in union subselects in MySQL 5.0.38
Warnings elimination
2007-12-20 10:58:21 +01:00
tnurnberg@white.intern.koehntopp.de
d1637b2ec4 Merge tnurnberg@bk-internal.mysql.com:/home/bk/mysql-5.0-opt
into  mysql.com:/misc/mysql/31990/50-31990
2007-12-20 08:35:52 +01:00
tnurnberg@white.intern.koehntopp.de
1f5b0b3954 Merge tnurnberg@bk-internal.mysql.com:/home/bk/mysql-5.1-opt
into  mysql.com:/misc/mysql/31990/51-31990
2007-12-20 08:32:51 +01:00
tnurnberg@white.intern.koehntopp.de
38b888dd65 Merge mysql.com:/misc/mysql/31990/50-31990
into  mysql.com:/misc/mysql/31990/51-31990
2007-12-20 07:45:16 +01:00
davi@endora.local
ab6ef39cd1 Merge mysql.com:/Users/davi/mysql/bugs/28317-5.1
into  mysql.com:/Users/davi/mysql/mysql-5.1-runtime
2007-12-19 21:01:48 -02:00
davi@mysql.com/endora.local
cab36bdf57 Bug#28317 Left Outer Join with {oj outer-join}
Parser rejects ODBC's escape sequences for outer joins other
than left outer join, yet the escape sequence BNF specifies
that this syntax can be used for left, right, and full outer
join syntax.

The problem is that although the MySQL Connector/ODBC advertises
"Outer Join Escape Sequence" capabilities, the parsing is done
in the server and historically it only supported this syntax
for left outer joins and applications such as Crystal Reports
11 tries to use this syntax for inner joins.

The chosen solution is to reorganize a couple of parser rules
to ignore any kind of SQL escape sequence. Ignoring the escape
sequences is harmless because the various SQL join clauses
are supported by the server.
2007-12-19 20:59:57 -02:00
serg@janus.mylan
b07aaec21c Merge janus.mylan:/usr/home/serg/Abk/mysql-5.0
into  janus.mylan:/usr/home/serg/Abk/mysql-5.1
2007-12-19 22:35:46 +01:00
serg@janus.mylan
4a5eb6bd17 correct invalid values in SET GLOBAL var=DEFAULT
bug#33382
2007-12-19 21:31:04 +01:00
kostja@bodhi.(none)
b9a41928e6 Merge bk-internal.mysql.com:/home/bk/mysql-5.1-runtime
into  bodhi.(none):/opt/local/work/mysql-5.1-runtime
2007-12-19 22:52:31 +03:00
kostja@bodhi.(none)
15c04b2db8 Make handler::{write,delete,update}_row private. It's critical
that the entire server uses their public ha_* counterparts instead,
since only then we can ensure proper tracing of these calls that
is necessary for Bug#12713.
A pre-requisite for Bug#12713 "Error in a stored function called from 
a SELECT doesn't cause ROLLBACK of statem"
2007-12-19 22:15:02 +03:00
mkindahl@dl145h.mysql.com
bdea24f483 Merge dl145h.mysql.com:/data0/mkindahl/mysql-5.1-rpl
into  dl145h.mysql.com:/data0/mkindahl/mysql-5.1-rpl-merge
2007-12-19 18:51:46 +01:00
tomas@whalegate.ndb.mysql.com
c9ecf31242 Bug #33375 all_set corrupted on table object
- make sure to reset the read and write sets
2007-12-19 18:42:49 +01:00
mhansson/martin@linux-st28.site
0004b99b58 Merge mhansson@bk-internal:/home/bk/mysql-5.0-opt
into  linux-st28.site:/home/martin/mysql/src/bug32848/my50-bug32848
2007-12-19 15:59:05 +01:00
mkindahl@dl145h.mysql.com
a9daa2cd86 Merge dl145h.mysql.com:/data0/mkindahl/mysql-5.0-rpl
into  dl145h.mysql.com:/data0/mkindahl/mysql-5.0-rpl-merge
2007-12-19 14:49:04 +01:00
jperkin/jonathan@chorlton.adsl.perkin.org.uk
f988a7e600 Add new pkgplugindir handling to seperate plugins from libraries,
and allow override for binary distributions.  Extend mysql_config
to print compiled-in plugin location for third-party plugins to
use.  Resolves bug#31736.
2007-12-19 13:24:43 +00:00
serg@janus.mylan
1a5b69ec58 SHOW_VAR arrays are null-terminated :-[] 2007-12-19 14:16:10 +01:00
serg@janus.mylan
3bd3bd1e30 Followup for bug#30252.
Ensure that all SQLCOM_ constants have corresponding Com_ variables.
2007-12-19 01:27:15 +01:00
kostja@bodhi.(none)
9d48e76b20 Sort class handler public declarations. 2007-12-19 00:36:20 +03:00
dkatz@damien-katzs-computer.local
6b2815bedc Merge damien-katzs-computer.local:/Users/dkatz/mysql-5.1-runtime
into  damien-katzs-computer.local:/Users/dkatz/Com_create_function
2007-12-18 13:52:26 -05:00
kostja@vajra.(none)
ef4295af44 Consistently use doxygen comments in class handler. 2007-12-18 15:47:22 +03:00
gkodinov/kgeorge@magare.gmz
af1231fa80 Merge magare.gmz:/home/kgeorge/mysql/autopush/B19390-5.0-opt
into  magare.gmz:/home/kgeorge/mysql/work/B19390-5.1-opt
2007-12-18 11:07:08 +02:00
tnurnberg@sin.intern.azundris.com
c25619f25f Merge tnurnberg@bk-internal.mysql.com:/home/bk/mysql-5.1-opt
into  sin.intern.azundris.com:/misc/mysql/32770/51-32770
2007-12-17 16:22:00 +01:00
hezx@hezx.(none)
f8fb5adc2f Merge hezx.(none):/media/sda3/work/mysql/bkwork/bug#32205/5.1
into  hezx.(none):/media/sda3/work/mysql/bkwork/bug#32205/mysql-5.1-new-rpl
2007-12-17 21:21:23 +08:00
hezx@hezx.(none)
3255237fc2 BUG#32205 Replaying statements from mysqlbinlog fails with a syntax error, replicates
fine

The reason of this bug is that when mysqlbinlog dumps a query, the query is written to
output with a delimeter appended right after it, if the query string ends with a '--'
comment, then the delimeter would be considered as part of the comment, if there are any
statements after this query, then it will cause a syntax error.

Start a newline before appending delimiter after a query string
2007-12-17 21:13:25 +08:00
joerg@trift2.
af73c6c867 Merge trift2.:/MySQL/M51/mysql-5.1
into  trift2.:/MySQL/M51/push-5.1
2007-12-17 13:40:06 +01:00
tnurnberg@white.intern.koehntopp.de
1d84609890 Merge tnurnberg@bk-internal.mysql.com:/home/bk/mysql-5.0-opt
into  mysql.com:/misc/mysql/32770/50-32770
2007-12-17 09:56:40 +01:00
tnurnberg@mysql.com/white.intern.koehntopp.de
94d7b8273f Merge tnurnberg@bk-internal.mysql.com:/home/bk/mysql-5.1-opt
into  mysql.com:/misc/mysql/31752_/51-31752_
2007-12-17 09:48:30 +01:00