Commit graph

20920 commits

Author SHA1 Message Date
ramil/ram@mysql.com/myoffice.izhnet.ru
b57efe738a --{skip-}merge option added which allows the user to disable merge engine and
to avoid the potential security problem.
(see bug #15195: Security Breach with MERGE table)
2006-07-14 16:26:58 +05:00
gkodinov/kgeorge@rakia.(none)
f04ea13511 Merge gkodinov@bk-internal.mysql.com:/home/bk/mysql-4.1-opt
into  rakia.(none):/home/kgeorge/mysql/autopush/B17212-4.1-opt
2006-07-14 12:49:14 +03:00
holyfoot/hf@mysql.com/deer.(none)
9b687356ae Merge abotchkov@bk-internal.mysql.com:/home/bk/mysql-4.1
into  mysql.com:/home/hf/work/mysql-4.1.16017
2006-07-14 00:21:13 +05:00
holyfoot/hf@mysql.com/deer.(none)
eddaafb12b Merge bk@192.168.21.1:mysql-4.1
into  mysql.com:/home/hf/work/mysql-4.1.16017
2006-07-13 22:32:18 +05:00
cmiller@zippy.(none)
b4c8f53661 Merge bk-internal.mysql.com:/home/bk/mysql-4.1
into  zippy.(none):/home/cmiller/work/mysql/m41-maint--07AB5
2006-07-13 13:10:59 -04:00
cmiller@zippy.(none)
fafc11205c Merge bk-internal.mysql.com:/home/bk/mysql-4.1-maint
into  zippy.(none):/home/cmiller/work/mysql/m41-maint--07AB5
2006-07-13 13:03:36 -04:00
igreenhoe/greenman@anubis.greendragongames.com
8e3d69d986 Merge igreenhoe@bk-internal.mysql.com:/home/bk/mysql-4.1-maint
into  anubis.greendragongames.com:/home/greenman/workspace-mysql/mysql/pending/bug-4.1-15977
2006-07-13 00:33:49 -07:00
igreenhoe/greenman@anubis.greendragongames.com
a5b8596c37 Fix for Bug #19364 "mysql --help gives old informations".
Old option ordering in the help was confusing to some users.  Changed
ordering of deprecated options to be consistent, and added mention to
entry for options with a "--no-option" variant mentioning the
"--disable-option" variant.
2006-07-13 00:31:47 -07:00
tnurnberg@mysql.com/salvation.intern.azundris.com
4be51e1644 Bug#20432: mysql client interprets commands in comments
do not look for client-specific commands while inside a multi-line comment.
we will allow multi-comments pretty much anywhere within SQL-statements,
but client-specific commands (help, use, print, ...) must be the first token
in the input.
2006-07-13 09:04:06 +02:00
mkindahl@dl145k.mysql.com
0f070b0b32 Merge dl145k.mysql.com:/data0/mkindahl/bkroot/mysql-4.1
into  dl145k.mysql.com:/data0/mkindahl/bk/mysql-4.1-rpl
2006-07-12 10:04:40 +02:00
gkodinov/kgeorge@macbook.gmz
5079d5cf6a Bug #17212 results not sorted correctly by ORDER BY when using index
* don't use join cache when the incoming data set is already ordered
    for ORDER BY
    This choice must be made because join cache will effectively
    reverse the join order and the results will be sorted by the index
    of the table that uses join cache.
2006-07-12 10:57:38 +03:00
cmiller@maint1.mysql.com
f83ad34329 Merge cmiller@bk-internal.mysql.com:/home/bk/mysql-4.1
into  maint1.mysql.com:/data/localhome/cmiller/mysql-4.1
2006-07-12 05:34:56 +02:00
evgen@moonbone.local
363d14569e Merge epotemkin@bk-internal.mysql.com:/home/bk/mysql-4.1-opt
into  moonbone.local:/work/16302-bug-4.1-opt-mysql
2006-07-12 06:12:59 +04:00
evgen@moonbone.local
5d4881b864 Merge epotemkin@bk-internal.mysql.com:/home/bk/mysql-4.1-opt
into  moonbone.local:/work/18503-bug-4.1-mysql
2006-07-12 02:52:29 +04:00
evgen@moonbone.local
8ffda481c9 Fixed bug#18503: Queries with a quantified subquery returning empty set
may return a wrong result.

An Item_sum_hybrid object has the was_values flag which indicates whether any
values were added to the sum function. By default it is set to true and reset
to false on any no_rows_in_result() call. This method is called only in
return_zero_rows() function. An ALL/ANY subquery can be optimized by MIN/MAX
optimization. The was_values flag is used to indicate whether the subquery
has returned at least one row. This bug occurs because return_zero_rows() is
called only when we know that the select will return zero rows before
starting any scans but often such information is not known.
In the reported case the return_zero_rows() function is not called and
the was_values flag is not reset to false and yet the subquery return no rows
Item_func_not_all and Item_func_nop_all functions return a wrong
comparison result.

The end_send_group() function now calls no_rows_in_result() for each item
in the fields_list if there is no rows were found for the (sub)query.
2006-07-12 01:52:18 +04:00
cmiller@zippy.(none)
f12bc24ac6 Merge bk-internal.mysql.com:/home/bk/mysql-4.1
into  zippy.(none):/home/cmiller/work/mysql/m41-maint--07AB5
2006-07-11 14:25:42 -04:00
cmiller@zippy.(none)
22485908ce Bug#20729: Bad date_format() call makes mysql server crash
The problem is that the author used the wrong function to send a warning to the 
user about truncation of data.  push_warning() takes a constant string and 
push_warning_printf() takes a format and variable arguments to fill it.

Since the string we were complaining about contains percent characters, the 
printf() code interprets the "%Y" et c. that the user sends.  That's wrong, and
often causes a crash, especially if the date mentions seconds, "%s".

A alternate fix would be to use  push_warning_printf(..., "%s", warn_buff) .
2006-07-11 13:06:29 -04:00
pekka@orca.ndb.mysql.com
6af016ba8a ndb - (4.1) trivial fix to error.log (wday=0 was printed as "x") 2006-07-11 17:07:23 +02:00
evgen@moonbone.local
ff3ffe5c39 Merge moonbone.local:/work/allany-4.1-mysql
into  moonbone.local:/work/16302-bug-4.1-opt-mysql
2006-07-11 17:48:33 +04:00
evgen@moonbone.local
a65bf3bf90 Merge epotemkin@bk-internal.mysql.com:/home/bk/mysql-4.1-opt
into  moonbone.local:/home/evgen/bk-trees/mysql-4.1-opt
2006-07-11 17:35:36 +04:00
cmiller@zippy.(none)
faa575645f Merge zippy.(none):/home/cmiller/work/mysql/mysql-4.0__bug19006
into  zippy.(none):/home/cmiller/work/mysql/merge/mysql-4.1
2006-07-11 07:24:59 -04:00
evgen@moonbone.local
4235ab7e1c Merge epotemkin@bk-internal.mysql.com:/home/bk/mysql-4.1-opt
into  moonbone.local:/work/allany-4.1-mysql
2006-07-11 00:36:14 +04:00
evgen@moonbone.local
d34189715e Fixed bug#16302: Quantified subquery without any tables gives wrong results
The ALL/ANY subqueries are the subject of MIN/MAX optimization. The matter
of this optimization is to embed MIN() or MAX() function into the subquery
in order to get only one row by which we can tell whether the expression
with ALL/ANY subquery is true or false.
But when it is applied to a subquery like 'select a_constant' the reported bug
occurs. As no tables are specified in the subquery the do_select() function 
isn't called for the optimized subquery and thus no values have been added 
to a MIN()/MAX() function and it returns NULL instead of a_constant.
This leads to a wrong query result.

For the subquery like 'select a_constant' there is no reason to apply
MIN/MAX optimization because the subquery anyway will return at most one row.
Thus the Item_maxmin_subselect class is more appropriate for handling such
subqueries.

The Item_in_subselect::single_value_transformer() function now checks
whether tables are specified for the subquery. If no then this subselect is
handled like a UNION using an Item_maxmin_subselect object.
2006-07-11 00:34:37 +04:00
gkodinov/kgeorge@macbook.gmz
893e92761f Merge rakia:mysql/4.1/B14553
into  macbook.gmz:/Users/kgeorge/mysql/work/B14553-4.1-opt
2006-07-10 16:27:04 +03:00
gkodinov/kgeorge@mysql.com/rakia.(none)
2c9f5cc706 BUG#14553: NULL in WHERE resets LAST_INSERT_ID
To make MySQL compatible with some ODBC applications, you can find
the AUTO_INCREMENT value for the last inserted row with the following query:
 SELECT * FROM tbl_name WHERE auto_col IS NULL.
This is done with a special code that replaces 'auto_col IS NULL' with
'auto_col = LAST_INSERT_ID'.
However this also resets the LAST_INSERT_ID to 0 as it uses it for a flag
so as to ensure that only the first SELECT ... WHERE auto_col IS NULL
after an INSERT has this special behaviour.
In order to avoid resetting the LAST_INSERT_ID a special flag is introduced
in the THD class. This flag is used to restrict the second and subsequent
SELECTs instead of LAST_INSERT_ID.
2006-07-10 16:27:03 +03:00
pekka@orca.ndb.mysql.com
4893022ea6 ndb - bug#20847: non-debug compile fix 2006-07-10 12:05:51 +02:00
pekka@orca.ndb.mysql.com
6191c7db85 Merge orca.ndb.mysql.com:/space/pekka/ndb/version/my41
into  orca.ndb.mysql.com:/space_old/pekka/ndb/version/my41-bug20847
2006-07-10 11:06:21 +02:00
pekka@orca.ndb.mysql.com
c9db5f8063 Merge pnousiainen@bk-internal.mysql.com:/home/bk/mysql-4.1
into  orca.ndb.mysql.com:/space_old/pekka/ndb/version/my41
2006-07-10 08:04:40 +02:00
aelkin/elkin@dsl-hkigw8-feb1fb00-100.dhcp.inet.fi
fadbdf27c3 BUG#20919 temp tables closing fails when binlog is off
closing temp tables through end_thread
had a flaw in binlog-off branch of close_temporary_tables where
next table to close was reset via table->next
 for (table= thd->temporary_tables; table; table= table->next)
which was wrong since the current table instance got destoyed at
	close_temporary(table, 1);

The fix adapts binlog-on branch method to engage the loop's internal 'next' variable which holds table->next prior table's destoying.
2006-07-10 00:26:26 +03:00
ingo/mydev@chilla.local
23c2570a5e Merge chilla.local:/home/mydev/mysql-4.0
into  chilla.local:/home/mydev/mysql-4.0-bug14400
2006-07-08 21:16:13 +02:00
ingo/mydev@chilla.local
987abbc253 Merge chilla.local:/home/mydev/mysql-4.1-bug19835
into  chilla.local:/home/mydev/mysql-4.1-amerge
2006-07-08 19:27:16 +02:00
ingo/mydev@chilla.local
d341ca941f Merge chilla.local:/home/mydev/mysql-4.1-bug17877
into  chilla.local:/home/mydev/mysql-4.1-amerge
2006-07-08 19:26:18 +02:00
ingo/mydev@chilla.local
065cdb030a Merge chilla.local:/home/mydev/mysql-4.1-bug14400
into  chilla.local:/home/mydev/mysql-4.1-amerge
2006-07-08 19:25:01 +02:00
ingo/mydev@chilla.local
eaa9350c90 Merge chilla.local:/home/mydev/mysql-4.1-bug11824
into  chilla.local:/home/mydev/mysql-4.1-amerge
2006-07-08 19:23:55 +02:00
cmiller@maint1.mysql.com
8a7ae86ef2 Merge cmiller@bk-internal.mysql.com:/home/bk/mysql-4.0
into  maint1.mysql.com:/data/localhome/cmiller/mysql-4.0__bug19006
2006-07-07 23:00:33 +02:00
cmiller@zippy.(none)
8ea01fbca8 Add a more reliable "getconf" test for Linuxthreads. The later trees should already
have a better test (and so this should be null-merged there).

ALSO!  Make it so that it accepts NPTL as a valid _equivalent_ implementation.
2006-07-07 16:47:57 -04:00
pekka@mysql.com
7ed021f926 ndb - bug#20847 : DbtupTabDesMan: add merge with left buddies 2006-07-07 10:57:22 +02:00
bar@mysql.com
2303077238 Merge abarkov@bk-internal.mysql.com:/home/bk/mysql-4.1
into  mysql.com:/usr/home/bar/mysql-4.1.b17647
2006-07-07 12:17:00 +05:00
konstantin@bodhi.netgear
0db71aaf98 Merge bk-internal.mysql.com:/home/bk/mysql-4.1
into  bodhi.netgear:/opt/local/work/mysql-4.1-19399
2006-07-07 00:01:05 +04:00
konstantin@bodhi.netgear
8e735d2c11 A fix and a test case for Bug#19399 "res 'Lost Connection' when
dropping/creating tables".

The bug could lead to a crash when multi-delete statements were
prepared and used with temporary tables.

The bug was caused by lack of clean-up of multi-delete tables before
re-execution of a prepared statement. In a statement like
DELETE t1 FROM t1, t2 WHERE ... the first table list (t1) is
moved to lex->auxilliary_table_list and excluded from lex->query_tables
or select_lex->tables. Thus it was unaccessible to reinit_stmt_before_use
and not cleaned up before re-execution of a prepared statement.
2006-07-06 23:59:04 +04:00
iggy@rolltop.ignatz42.dyndns.org
1fe4159026 Merge rolltop.ignatz42.dyndns.org:/mnt/storeage/mysql-4.1-maint
into  rolltop.ignatz42.dyndns.org:/mnt/storeage/mysql-4.1_bug20328
2006-07-06 15:13:25 -04:00
iggy@rolltop.ignatz42.dyndns.org
646dd6e65c Merge rolltop.ignatz42.dyndns.org:/mnt/storeage/mysql-4.1-maint
into  rolltop.ignatz42.dyndns.org:/mnt/storeage/mysql-4.1_bug16180
2006-07-06 15:00:31 -04:00
igor@olga.mysql.com
6e1c8ad830 Merge ibabaev@bk-internal.mysql.com:/home/bk/mysql-4.1-opt
into  olga.mysql.com:/home/igor/mysql-4.1-opt
2006-07-06 11:38:48 -07:00
igor@olga.mysql.com
0e3d2dafd6 Fixed bug #18243.
The implementation of the method Item_func_reverse::val_str
for the REVERSE function modified the argument of the function.
This led to wrong results for expressions that contained
REVERSE(ref) if ref occurred somewhere else in the expressions.
2006-07-06 11:11:49 -07:00
tomas@poseidon.ndb.mysql.com
cf71457319 Merge jonas@perch:src/mysql-4.1
into  poseidon.ndb.mysql.com:/home/tomas/mysql-4.1-main
2006-07-06 16:06:19 +02:00
tomas@poseidon.ndb.mysql.com
aea2a9c788 Merge tulin@bk-internal.mysql.com:/home/bk/mysql-4.1
into  poseidon.ndb.mysql.com:/home/tomas/mysql-4.1-main
2006-07-06 16:03:22 +02:00
tomas@poseidon.ndb.mysql.com
b2ed2fd045 Merge poseidon.ndb.mysql.com:/home/tomas/mysql-4.1
into  poseidon.ndb.mysql.com:/home/tomas/mysql-4.1-main
2006-07-06 15:22:25 +02:00
tomas@poseidon.ndb.mysql.com
ec8771af69 backport of ndb DictCache fix
- don't invalidate tables that are in state RETRIEVING
2006-07-06 15:18:00 +02:00
jonas@perch.ndb.mysql.com
71d5a20d37 Merge joreland@bk-internal.mysql.com:/home/bk/mysql-4.1
into  perch.ndb.mysql.com:/home/jonas/src/mysql-4.1
2006-07-06 13:23:19 +02:00
pekka@mysql.com
949d69f9ba Merge pnousiainen@bk-internal.mysql.com:/home/bk/mysql-4.1
into  mysql.com:/space_old/pekka/ndb/version/my41
2006-07-06 05:01:09 +02:00