Commit graph

49923 commits

Author SHA1 Message Date
mhansson@dl145s.mysql.com
eb8d5c36c9 Merge mhansson@bk-internal:/home/bk/mysql-5.1-opt
into  dl145s.mysql.com:/data0/mhansson/bug30942/my51-bug30942
2007-10-04 13:58:34 +02:00
mhansson/martin@linux-st28.site
ec959efa71 Merge linux-st28.site:/home/martin/mysql/src/bug30942/my50-bug30942
into  linux-st28.site:/home/martin/mysql/src/bug30942/my51-bug30942
2007-10-04 10:06:33 +02:00
mhansson/martin@linux-st28.site
028992ac69 Bug #30942: select str_to_date from derived table returns varying results
The function str_to_date has a field to say whether it's invoked constant 
arguments. But this member was not initialized, causing the function to
think that it could use a cache of the format type when said cache was in 
fact not initialized.
Fixed by initializing the field to false.
2007-10-04 09:15:26 +02:00
gshchepa/uchum@gleb.loc
009d8b609e mysqldump.c:
Post-merge fix.
2007-10-03 15:49:51 +05:00
gshchepa/uchum@gleb.loc
5184ff828c Merge gleb.loc:/home/uchum/work/bk/5.0-opt-31077
into  gleb.loc:/home/uchum/work/bk/5.1-opt
2007-10-03 15:05:11 +05:00
gshchepa/uchum@gleb.loc
a6b5121b40 mysqldump.test, mysqldump.result:
Bug #31077: post-commit fix.
2007-10-03 11:36:42 +05:00
gshchepa/uchum@gleb.loc
c81751adba mysqldump.c, mysqldump.test, mysqldump.result:
Bug #31077: post-commit fix.
2007-10-03 02:50:38 +05:00
mhansson@dl145s.mysql.com
96e68cfbb5 Merge mhansson@bk-internal:/home/bk/mysql-5.1-opt
into  dl145s.mysql.com:/data0/mhansson/bug30832/my51-bug30832
2007-10-01 19:05:23 +02:00
gshchepa/uchum@gleb.loc
5fc81ee88e Fixed bug #31077.
mysqldump adds the "-- Dump completed on YYYY-MM-DD hh:mm:ss" string
to the end of output if the --comments switch is on.
The only way to suppress this line is to use --skip-comments/--compact
switch.

New switch has been added to the mysqldump client command line:
--dump-date.

For the compatibility with previous releases, by default the --dump-date
is on.
The --dump-date switch forces mysqldump to add date to the
"-- Dump completed on ..." string at the end of output.
The --skip-dump-date switch supresses the output of date string
and uses short form of that commentary: "-- Dump completed".
--skip-comments or --compact switches disable the whole commentary
as usual.
2007-10-01 20:35:51 +05:00
gkodinov/kgeorge@magare.gmz
0ba77db972 merge 5.0-opt -> 5.1-opt 2007-10-01 17:37:48 +03:00
gkodinov/kgeorge@magare.gmz
61085ae612 merge 5.0-opt -> 5.1-opt 2007-10-01 12:56:25 +03:00
gkodinov/kgeorge@magare.gmz
93d44a183d removed undeterministic test result from the fux for bug 30587 2007-10-01 12:51:59 +03:00
gkodinov/kgeorge@magare.gmz
72a0ad7982 fixed pb problem with the fix for bug 30587 2007-10-01 11:32:29 +03:00
mhansson/martin@linux-st28.site
967c782fa7 Merge linux-st28.site:/home/martin/mysql/src/bug30832/my50-bug30832
into  linux-st28.site:/home/martin/mysql/src/bug30832/my51-bug30832
2007-10-01 09:11:45 +02:00
evgen@moonbone.local
59b311baee view_grant.result, view_grant.test:
Corrected test case for the bug#29908.
2007-09-29 01:07:29 +00:00
evgen@moonbone.local
77dabba63f Merge epotemkin@bk-internal.mysql.com:/home/bk/mysql-5.0-opt
into  moonbone.local:/work/27990-bug-5.0-opt-mysql
2007-09-28 23:27:23 +00:00
evgen@moonbone.local
b9e81c2ae3 Bug#27990: Wrong info in MYSQL_FIELD struct members when a tmp table was used.
The change_to_use_tmp_fields function leaves the orig_table member of an
expression's tmp table field filled for the new Item_field being created.
Later orig_table is used by the Field::make_field function to provide some
info about original table and field name to a user. This is ok for a field
but for an expression it should be empty.

The change_to_use_tmp_fields function now resets orig_table member of
an expression's tmp table field to prevent providing a wrong info to a user.
The Field::make_field function now resets the table_name and the org_col_name
variables when the orig_table is set to 0.
2007-09-28 23:24:40 +00:00
mhansson/martin@linux-st28.site
397da9d9b7 Bug #30832: Assertion + crash with select name_const('test', now());
The NAME_CONST function is required to work correctly with constants only.
When executed with functions that return types other than those returned by
Item::field_type (string, int, decimal, or real), the result gets cast to
one of those types. This cannot happen for constants.
Fixed by only allowing constants as arguments to NAME_CONST.
2007-09-28 18:05:23 +02:00
gkodinov/kgeorge@magare.gmz
5ac2fd0b1b Merge macbook:mysql/work/B30587-5.0-opt
into  magare.gmz:/home/kgeorge/mysql/work/B30587-5.1-opt
2007-09-28 17:03:14 +03:00
gkodinov/kgeorge@magare.gmz
fbdf00f085 Merge gkodinov@bk-internal.mysql.com:/home/bk/mysql-5.0-opt
into  magare.gmz:/home/kgeorge/mysql/autopush/B30587-5.0-opt
2007-09-28 16:57:36 +03:00
gkodinov/kgeorge@macbook.gmz
aa2d545de2 Bug #30587: mysql crashes when trying to group by TIME div NUMBER
When calculating the result length of an integer DIV function 
the number of decimals was used without checking the result type
first. Thus an uninitialized number of decimals was used for some 
types. This caused an excessive amount of memory to be allocated 
for the field's buffer and crashed the server.

 
Fixed by using the number of decimals only for data types that 
can have decimals and thus have valid decimals number.
2007-09-28 16:46:05 +03:00
gluh@eagle.(none)
09cfa4f9dc Merge sgluhov@bk-internal.mysql.com:/home/bk/mysql-5.1-opt
into  mysql.com:/home/gluh/MySQL/Merge/5.1-opt
2007-09-28 17:34:05 +05:00
gluh@mysql.com/eagle.(none)
1494eabc85 Bug#30795 Query on INFORMATION_SCHEMA.SCHEMATA, wrong result
skip the check of directory presence for 'information_schema' name
2007-09-28 17:33:30 +05:00
gluh@mysql.com/eagle.(none)
ccccad7058 Bug#30689 Wrong content in I_S.VIEWS.VIEW_DEFINITION if VIEW is based on I_S
view_body_utf8 attribute type is changed to 'escaped string'
2007-09-28 16:02:43 +05:00
mhansson@dl145s.mysql.com
44178403c1 Bug#30665: Post-merge fix 2007-09-28 12:30:55 +02:00
mhansson@dl145s.mysql.com
d18df32bc7 Merge mhansson@bk-internal:/home/bk/mysql-5.1-opt
into  dl145s.mysql.com:/data0/mhansson/my51-bug30665
2007-09-28 10:33:06 +02:00
mhansson/martin@linux-st28.site
ab73b25d5b Bug#30665: Inconsistent optimization of IGNORE INDEX FOR {ORDER BY|GROUP BY}
The optimizer takes different execution paths during EXPLAIN than SELECT,
this fix relates only to EXPLAIN, hence no behavior changes.
The test of sort keys for ORDER BY was prohibited from considering keys
that were mentioned in IGNORE KEYS FOR ORDER BY. This led to two 
inconsistencies: One was that IGNORE INDEX FOR GROUP BY and 
IGNORE INDEX FOR ORDER BY gave apparently different EXPLAINs; the latter 
erroneously claimed to do filesort. The second inconsistency 
is that the test of sort keys is called twice, finding a sort key the first
time but not the second time, leading to the mentioned filesort.

Fixed by making the test of sort keys consider all enabled 
keys on the table. This test rejects keys that are not covering, and for 
covering keys the hint should be ignored anyway.
2007-09-28 09:36:05 +02:00
evgen@sunlight.local
2a26db1ffd Merge epotemkin@bk-internal.mysql.com:/home/bk/mysql-5.0-opt
into  sunlight.local:/local_work/29908-bug-5.0-opt-mysql
2007-09-27 23:45:39 +04:00
gkodinov/kgeorge@magare.gmz
ca2c93fc33 Merge magare.gmz:/home/kgeorge/mysql/autopush/B30468-5.0-opt
into  magare.gmz:/home/kgeorge/mysql/autopush/B30468-5.1-opt
2007-09-27 18:02:21 +03:00
gkodinov/kgeorge@magare.gmz
c41cb79463 Fixed a warning cased by the fix for bug 30468 2007-09-27 17:56:50 +03:00
gkodinov/kgeorge@magare.gmz
d292bc9225 Merge magare.gmz:/home/kgeorge/mysql/autopush/B30468-5.0-opt
into  magare.gmz:/home/kgeorge/mysql/autopush/B30468-5.1-opt
2007-09-27 14:33:55 +03:00
gkodinov/kgeorge@magare.gmz
bebbe4542f separated an assertion from the assignment (bug 30468) 2007-09-27 14:29:46 +03:00
gkodinov/kgeorge@magare.gmz
3b1d0fbe1a Merge gkodinov@bk-internal.mysql.com:/home/bk/mysql-5.1-opt
into  magare.gmz:/home/kgeorge/mysql/autopush/B30468-5.1-opt
2007-09-27 13:02:04 +03:00
gkodinov/kgeorge@magare.gmz
f42a392b2a merged the fix for bug 30468 to 5.1-opt 2007-09-27 12:32:59 +03:00
gkodinov/kgeorge@magare.gmz
bbe1d37089 Merge gkodinov@bk-internal.mysql.com:/home/bk/mysql-5.0-opt
into  magare.gmz:/home/kgeorge/mysql/autopush/B30468-5.0-opt
2007-09-27 12:17:16 +03:00
gkodinov/kgeorge@magare.gmz
fb3b12176d Bug #30468: column level privileges not respected when joining tables
When expanding a * in a USING/NATURAL join the check for table access
for both tables in the join was done using the grant information of the
first one.
Fixed by getting the grant information for the current table while 
iterating through the columns of the join.
2007-09-27 12:15:19 +03:00
gshchepa/uchum@gleb.loc
1d12cdfcc4 mysqlslap.result, mysqlslap.test:
Post-commit fix.
2007-09-27 13:15:15 +05:00
gshchepa/uchum@gleb.loc
590d289591 Merge gshchepa@bk-internal.mysql.com:/users/gshchepa/5.1-opt-31075
into  gleb.loc:/home/uchum/work/bk/5.1-opt
2007-09-27 01:38:41 +05:00
gshchepa/uchum@gleb.loc
533a815244 Merge gleb.loc:/home/uchum/work/bk/5.1-opt-29985
into  gleb.loc:/home/uchum/work/bk/5.1-opt
2007-09-27 01:03:35 +05:00
gkodinov/kgeorge@magare.gmz
d0b796bf14 merge of the fix for bug 27802 & 27216 to 5.1-opt 2007-09-26 19:06:54 +03:00
gkodinov/kgeorge@magare.gmz
133175fb9f merged bug 28702 5.0-opt->5.1-opt 2007-09-26 14:22:48 +03:00
gshchepa@devsrv-b.mysql.com
7f0e9065f8 Fixed bug #31075.
The `SELECT col FROM t WHERE col NOT IN (col, ...) GROUP BY col'
crashed in the range optimizer.

The get_func_mm_tree function has been modified to check the
Item_func_in::array field for the NULL value before using of that
value.
2007-09-26 12:45:08 +02:00
evgen@sunlight.local
4fd6de8b1a Merge sunlight.local:/local_work/27216-bug-5.0-opt-mysql
into  sunlight.local:/local_work/merge-5.1-opt-mysql
2007-09-24 17:23:40 +04:00
gkodinov/kgeorge@magare.gmz
4cd18bde81 Bug #28702: VIEWs defined with USE/FORCE KEY ignore that request
When storing the VIEW the CREATE VIEW command is reconstructed 
from the parse tree. While constructing the command string
the index hints specified should also be printed.
Fixed by adding code to print the index hints when printing a 
table in the FROM clause.
2007-09-24 15:34:10 +03:00
gkodinov/kgeorge@macbook.local
fae74579e4 merging bug 28701 to 5.1-opt 2007-09-24 13:02:59 +02:00
gkodinov/kgeorge@macbook.local
eb00940207 merge of bug 28701 5.0-opt -> 5.1-opt 2007-09-24 10:30:50 +02:00
gkodinov/kgeorge@macbook.local
44292dcb3b Merge gkodinov@bk-internal.mysql.com:/home/bk/mysql-5.0-opt
into  macbook.local:/Users/kgeorge/mysql/autopush/B28701-merged-5.0-opt
2007-09-22 14:48:14 +02:00
gkodinov/kgeorge@macbook.local
ae9d734f40 Merge macbook.local:/Users/kgeorge/mysql/work/B28701-5.0-opt
into  macbook.local:/Users/kgeorge/mysql/work/B28701-merged-5.0-opt
2007-09-22 11:42:01 +02:00
evgen@sunlight.local
7ed30b971c Merge epotemkin@bk-internal.mysql.com:/home/bk/mysql-5.0-opt
into  sunlight.local:/local_work/27216-bug-5.0-opt-mysql
2007-09-22 13:10:44 +04:00
evgen@sunlight.local
36bf417b40 Bug#27216: functions with parameters of different date types may return wrong
type of the result.

There are several functions that accept parameters of different types.
The result field type of such functions was determined based on
the aggregated result type of its arguments. As the DATE and the DATETIME
types are represented by the STRING type, the result field type
of the affected functions was always STRING for DATE/DATETIME arguments.
The affected functions are COALESCE, IF, IFNULL, CASE, LEAST/GREATEST, CASE.

Now the affected functions aggregate the field types of their arguments rather
than their result types and return the result of aggregation as their result
field type.
The cached_field_type member variable is added to the number of classes to
hold the aggregated result field type.
The str_to_date() function's result field type now defaults to the
MYSQL_TYPE_DATETIME.
The agg_field_type() function is added. It aggregates field types with help
of the Field::field_type_merge() function.
The create_table_from_items() function now uses the 
item->tmp_table_field_from_field_type() function to get the proper field
when the item is a function with a STRING result type.
2007-09-22 11:49:27 +04:00