Commit graph

108 commits

Author SHA1 Message Date
Sergei Golubchik
213f1c76a0 5.3->5.5 merge 2013-02-28 22:47:29 +01:00
Sergei Golubchik
5dec570d7c 5.1 -> 5.2 merge 2013-02-28 19:00:58 +01:00
Sergei Golubchik
027e34e13b a simpler fix for
MySQL Bug #12408412: GROUP_CONCAT + ORDER BY + INPUT/OUTPUT SAME USER VARIABLE = CRASH
and
MySQL Bug#14664077 SEVERE PERFORMANCE DEGRADATION IN SOME CASES WHEN USER VARIABLES ARE USED


sql/item_func.cc:
  don't use anything from Item_func_set_user_var::fix_fields()
  in Item_func_set_user_var::save_item_result()
sql/sql_class.cc:
  Call suv->save_item_result(item) *before* doing suv->fix_fields(), because
  the former evaluates the item (and caches its value), while the latter marks
  the user variable as non-const. The problem is that the item was fix_field'ed
  when the user variable was const, and it doesn't expect it to change to non-const
  in the middle of the execution.
2013-02-28 11:46:35 +01:00
Sergei Golubchik
a48a91d90f 5.3->5.5 merge 2012-11-22 10:19:31 +01:00
unknown
ee052c3e14 Fix of non-deterministic results. 2012-11-01 00:06:09 +02:00
unknown
4304dbc464 MDEV-616 fix (MySQL fix accepted) 2012-10-09 17:36:02 +03:00
Sergey Petrunya
8c762965d3 Merge 5.3 -> 5.5 2012-06-20 15:01:28 +04:00
unknown
d56f5dae1e Fix bug lp:1001506
This is a backport of the (unchaged) fix for MySQL bug #11764372, 57197.

Analysis:

When the outer query finishes its main execution and computes GROUP BY,
it needs to construct a new temporary table (and a corresponding JOIN) to
execute the last DISTINCT operation. At this point JOIN::exec calls
JOIN::join_free, which calls JOIN::cleanup -> TMP_TABLE_PARAM::cleanup
for both the outer and the inner JOINs. The call to the inner
TMP_TABLE_PARAM::cleanup sets copy_field = NULL, but not copy_field_end.

The final execution phase that computes the DISTINCT invokes:
evaluate_join_record -> end_write -> copy_funcs
The last function copies the results of all functions into the temp table.
copy_funcs walks over all functions in join->tmp_table_param.items_to_copy.
In this case items_to_copy contains both assignments to user variables.
The process of copying user variables invokes Item_func_set_user_var::check
which in turn re-evaluates the arguments of the user variable assignment.
This in turn triggers re-evaluation of the subquery, and ultimately
copy_field.

However, the previous call to TMP_TABLE_PARAM::cleanup for the subquery
already set copy_field to NULL but not its copy_field_end. This results
in a null pointer access, and a crash.

Fix:
Set copy_field_end and save_copy_field_end to null when deleting
copy fields in TMP_TABLE_PARAM::cleanup().
2012-05-23 18:18:08 +03:00
Sergei Golubchik
431e042b5d c 2012-05-21 15:30:25 +02:00
Georgi Kodinov
bc7d8dc623 Bug #12408412: GROUP_CONCAT + ORDER BY + INPUT/OUTPUT SAME
USER VARIABLE = CRASH

Moved the preparation of the variables that receive the output from 
SELECT INTO from execution time (JOIN:execute) to compile time 
(JOIN::prepare). This ensures that if the same variable is used in the
SELECT part of SELECT INTO it will be properly marked as non-const
for this query.
Test case added.
Used proper fast iterator.
2012-03-09 15:04:49 +02:00
Sergei Golubchik
2ccf247e93 after merge changes:
* rename all debugging related command-line options
  and variables to start from "debug-", and made them all
  OFF by default.
* replace "MySQL" with "MariaDB" in error messages
* "Cast ... converted ... integer to it's ... complement"
  is now a note, not a warning
* @@query_cache_strip_comments now has a session scope,
  not global.
2011-12-12 23:58:40 +01:00
Gleb Shchepa
32215ae303 automerge 5.1-security --> 5.5-security (bug 57187) 2010-12-08 17:36:52 +03:00
Gleb Shchepa
e5a88caf08 Bug #57187: more user variable fun with multiple
assignments and comparison in query

A query that compares assignments of the same
user variable caused Valgrind warnings: access
to freed memory region.

In case of a DECIMAL argument the assignment
operator (:=) may return a pointer to a stored
value instead of its copy when evaluated.
The next assignment to the same variable may:
 a) overwrite the stored value with a new one
    and return the same pointer or even
 b) reallocate stored value.

Thus, if we evaluate an assignment and keep
the result pointer and then evaluate another
assignment to the same variable, then the
kept result pointer of the first assignment
will point to unexpectedly changed data or
it may be a dead pointer.

That may cause wrong data or crash.

The user_var_entry::val_decimal method has
been modified to copy user variable data.


mysql-test/r/user_var.result:
  Test case for bug #57187.
mysql-test/t/user_var.test:
  Test case for bug #57187.
sql/item_func.cc:
  Bug #57187: more user variable fun with multiple
              assignments and comparison in query
  
  The user_var_entry::val_decimal method has
  been modified to copy user variable data.
2010-12-06 23:38:31 +03:00
Guilhem Bichot
96b0404940 Fix for Bug#56138 "valgrind errors about overlapping memory when double-assigning same variable",
and related small fixes.

mysql-test/t/user_var.test:
  test for bug
sql/field_conv.cc:
  From the C standard, memcpy() has undefined behaviour if to->ptr==from->ptr
sql/item_func.cc:
  In the case of BUG#56138, entry->value==ptr in which case memcpy()
  has undefined results per the C standard.
sql/sql_select.cc:
  Work around a bug in old gcc
2010-11-22 09:57:59 +01:00
Guilhem Bichot
8f02025b21 merge of 5.1-bugteam 2010-11-22 10:13:46 +01:00
Georgi Kodinov
53e0b31e9c merge 2010-08-13 14:20:49 +03:00
Georgi Kodinov
4bf81165e4 Bug #55615 and bug #55564
An user assignment variable expression that's 
evaluated in a logical expression context 
(Item::val_bool()) can be pre-calculated in a 
temporary table for GROUP BY.
However when the expression value is used after the
temp table creation it was re-evaluated instead of
being read from the temp table due to a missing 
val_bool_result() method.
Fixed by implementing the method.
2010-08-13 14:18:46 +03:00
Alexander Nozdrin
0a032dea1f Patch for Bug#50511 (Sometimes wrong handling of user variables containing NULL).
The bug happened under the following condition:
  - there was a user variable of type REAL, containing NULL value
  - there was a table with a NOT_NULL column of any type but REAL, having
    default value (or auto increment);
  - a row was inserted into the table with the user variable as value.
    A warning was emitted here.

The problem was that handling of NULL values of REAL type was not properly
implemented: it didn't expect that REAL NULL value can be assigned to other
data type.

Basically, the problem was that set_field_to_null() was used instead of
set_field_to_null_with_conversions().

The fix is to use the right function, or more generally, to allow conversion of
REAL NULL values to other data types.
2010-05-05 15:00:59 +04:00
Alexander Nozdrin
a6667f8577 Manual merge from mysql-trunk-merge.
Conflicts:
  - configure.in
  - include/m_string.h
  - mysql-test/extra/rpl_tests/rpl_row_func003.test
  - mysql-test/r/mysqlbinlog.result
  - mysql-test/r/union.result
  - mysql-test/suite/binlog/r/binlog_killed_simulate.result
  - mysql-test/suite/binlog/r/binlog_row_mix_innodb_myisam.result
  - mysql-test/suite/binlog/r/binlog_unsafe.result
  - mysql-test/suite/binlog/t/binlog_unsafe.test
  - mysql-test/suite/rpl/r/rpl_loaddata_fatal.result
  - mysql-test/suite/rpl/r/rpl_loaddata_map.result
  - mysql-test/suite/rpl/r/rpl_stm_loaddata_concurrent.result
  - mysql-test/suite/rpl/r/rpl_stm_log.result
  - mysql-test/suite/rpl/t/rpl_optimize.test
  - mysql-test/t/mysqlbinlog.test
  - mysql-test/t/union.test
  - sql/rpl_utility.h
  - sql/sql_union.cc
  - strings/Makefile.am
2010-01-19 19:36:14 +03:00
Sergei Golubchik
1ad5bb1a69 WL#4738 streamline/simplify @@variable creation process
Bug#16565 mysqld --help --verbose does not order variablesBug#20413 sql_slave_skip_counter is not shown in show variables
Bug#20415 Output of mysqld --help --verbose is incomplete
Bug#25430 variable not found in SELECT @@global.ft_max_word_len;
Bug#32902 plugin variables don't know their names
Bug#34599 MySQLD Option and Variable Reference need to be consistent in formatting!
Bug#34829 No default value for variable and setting default does not raise error
Bug#34834 ? Is accepted as a valid sql mode
Bug#34878 Few variables have default value according to documentation but error occurs  
Bug#34883 ft_boolean_syntax cant be assigned from user variable to global var.
Bug#37187 `INFORMATION_SCHEMA`.`GLOBAL_VARIABLES`: inconsistent status
Bug#40988 log_output_basic.test succeeded though syntactically false.
Bug#41010 enum-style command-line options are not honoured (maria.maria-recover fails)
Bug#42103 Setting key_buffer_size to a negative value may lead to very large allocations 
Bug#44691 Some plugins configured as MYSQL_PLUGIN_MANDATORY in can be disabled
Bug#44797 plugins w/o command-line options have no disabling option in --help
Bug#46314 string system variables don't support expressions
Bug#46470 sys_vars.max_binlog_cache_size_basic_32 is broken
Bug#46586 When using the plugin interface the type "set" for options caused a crash.
Bug#47212 Crash in DBUG_PRINT in mysqltest.cc when trying to print octal number
Bug#48758 mysqltest crashes on sys_vars.collation_server_basic in gcov builds
Bug#49417 some complaints about mysqld --help --verbose output
Bug#49540 DEFAULT value of binlog_format isn't the default value
Bug#49640 ambiguous option '--skip-skip-myisam' (double skip prefix)
Bug#49644 init_connect and \0
Bug#49645 init_slave and multi-byte characters
Bug#49646 mysql --show-warnings crashes when server dies


CMakeLists.txt:
  Bug#44691 Some plugins configured as MYSQL_PLUGIN_MANDATORY in can be disabled
client/mysql.cc:
  don't crash with --show-warnings when mysqld dies
config/ac-macros/plugins.m4:
  Bug#44691 Some plugins configured as MYSQL_PLUGIN_MANDATORY in can be disabled
include/my_getopt.h:
  comments
include/my_pthread.h:
  fix double #define
mysql-test/mysql-test-run.pl:
  run sys_vars suite by default
  properly recognize envirinment variables (e.g. MTR_MAX_SAVE_CORE) set to 0
  escape gdb command line arguments
mysql-test/suite/sys_vars/r/rpl_init_slave_func.result:
  init_slave+utf8 bug
mysql-test/suite/sys_vars/t/rpl_init_slave_func.test:
  init_slave+utf8 bug
mysys/my_getopt.c:
  Bug#34599 MySQLD Option and Variable Reference need to be consistent in formatting!
  Bug#46586 When using the plugin interface the type "set" for options caused a crash.
  Bug#49640 ambiguous option '--skip-skip-myisam' (double skip prefix)
mysys/typelib.c:
  support for flagset
sql/ha_ndbcluster.cc:
  backport from telco tree
sql/item_func.cc:
  Bug#49644 init_connect and \0
  Bug#49645 init_slave and multi-byte characters
sql/sql_builtin.cc.in:
  Bug#44691 Some plugins configured as MYSQL_PLUGIN_MANDATORY in can be disabled
sql/sql_plugin.cc:
  Bug#44691 Some plugins configured as MYSQL_PLUGIN_MANDATORY in can be disabled
  Bug#32902 plugin variables don't know their names
  Bug#44797 plugins w/o command-line options have no disabling option in --help
sql/sys_vars.cc:
  all server variables are defined here
storage/myisam/ft_parser.c:
  remove unnecessary updates of param->quot
storage/myisam/ha_myisam.cc:
  myisam_* variables belong here
strings/my_vsnprintf.c:
  %o and %llx
unittest/mysys/my_vsnprintf-t.c:
  %o and %llx tests
vio/viosocket.c:
  bugfix: fix @@wait_timeout to work with socket timeouts (vs. alarm thread)
2009-12-22 10:35:56 +01:00
Sergey Glukhov
c0bd23ddbf 5.0-bugteam->5.1-bugteam merge 2009-12-22 14:38:33 +04:00
Sergey Glukhov
081bcb3b8b Bug#47371 reference by same column name
At the end of execution top level join execution
we cleanup this join with true argument.
It leads to underlying join cleanup(subquery) with true argument too
and to tmp_table_param->field array cleanup which is required later.
The problem is that Item_func_set_user_var does not set
result_filed which leads to unnecessary repeated excution of subquery
on final stage.
The fix is to set result_field for Item_func_set_user_var.


mysql-test/r/count_distinct.result:
  test result
mysql-test/r/user_var.result:
  test result
mysql-test/t/count_distinct.test:
  test case
mysql-test/t/user_var.test:
  test case
sql/item_func.cc:
  At the end of execution top level join execution
  we cleanup this join with true argument.
  It leads to underlying join cleanup(subquery) with true argument too
  and to tmp_table_param->field array cleanup which is required later.
  The problem is that Item_func_set_user_var does not set
  result_filed which leads to unnecessary repeated excution of subquery
  on final stage.
  The fix is to set result_field for Item_func_set_user_var.
2009-12-22 13:52:23 +04:00
Ramil Kalimullin
3c08b9b1ab Manual merge. 2009-05-10 21:20:35 +05:00
Ramil Kalimullin
bd414485de Fix for bug#42009: SELECT into variable gives different results to direct SELECT
Problem: storing "SELECT ... INTO @var ..." results in variables we used val_xxx()
methods which returned results of the current row. 
So, in some cases (e.g. SELECT DISTINCT, GROUP BY or HAVING) we got data
from the first row of a new group (where we evaluate a clause) instead of
data from the last row of the previous group.

Fix: use val_xxx_result() counterparts to get proper results.


mysql-test/r/distinct.result:
  Fix for bug#42009: SELECT into variable gives different results to direct SELECT
    - results adjusted.
mysql-test/r/user_var.result:
  Fix for bug#42009: SELECT into variable gives different results to direct SELECT
    - test result.
mysql-test/t/user_var.test:
  Fix for bug#42009: SELECT into variable gives different results to direct SELECT
    - test case.
sql/item_func.cc:
  Fix for bug#42009: SELECT into variable gives different results to direct SELECT
    - Item_func_set_user_var::save_item_result() added to evaluate and store 
      an item's result into a user variable.
sql/item_func.h:
  Fix for bug#42009: SELECT into variable gives different results to direct SELECT
    - Item_func_set_user_var::save_item_result() added to evaluate and store 
      an item's result into a user variable.
sql/sql_class.cc:
  Fix for bug#42009: SELECT into variable gives different results to direct SELECT
    - use Item_func_set_user_var::save_item_result() to store results into user 
      variables.
2009-02-24 18:47:12 +04:00
Gleb Shchepa
93991b6be9 Bug#42188: crash and/or memory corruption with user variables
in trigger

Interchangeable calls to the mysql_change_user client function
and invocations of a trigger changing some user variable caused
a memory corruption and a crash.

The mysql_change_user API call forces TDH::cleanup() on a server
that frees user variable entries.
However it didn't reset Item_func_set_user_var::entry to NULL
because Item_func_set_user_var::cleanup() was not overloaded.
So, Item_func_set_user_var::entry held a pointer to freed memory,
that caused a crash.

The Item_func_set_user_var::cleanup method has been overloaded
to cleanup the Item_func_set_user_var::entry field.


mysql-test/r/user_var.result:
  Added test case for bug #42188.
mysql-test/t/user_var.test:
  Added test case for bug #42188.
sql/item_func.cc:
  Bug#42188: crash and/or memory corruption with user variables
             in trigger
  
  The Item_func_set_user_var::cleanup method has been overloaded
  to cleanup the Item_func_set_user_var::entry field.
sql/item_func.h:
  Bug#42188: crash and/or memory corruption with user variables
             in trigger
  
  The Item_func_set_user_var::cleanup method has been overloaded
  to cleanup the Item_func_set_user_var::entry field.
2009-01-23 22:18:02 +04:00
Gleb Shchepa
e9cb71fc3a Bug#26020: User-Defined Variables are not consistent with
columns data types

The "SELECT @lastId, @lastId := Id FROM t" query returns
different result sets depending on the type of the Id column
(INT or BIGINT).

Note: this fix doesn't cover the case when a select query
references an user variable and stored function that
updates a value of that variable, in this case a result
is indeterminate.


The server uses incorrect assumption about a constantness of
an user variable value as a select list item: 

The server caches a last query number where that variable
was changed and compares this number with a current query
number. If these numbers are different, the server guesses,
that the variable is not updating in the current query, so
a respective select list item is a constant. However, in some
common cases the server updates cached query number too late.


The server has been modified to memorize user variable
assignments during the parse phase to take them into account
on the next (query preparation) phase independently of the
order of user variable references/assignments in a select
item list.


mysql-test/r/user_var.result:
  Added test case for bug #26020.
mysql-test/t/user_var.test:
  Added test case for bug #26020.
sql/item_func.cc:
  An update of entry and update_query_id variables has been
  moved from Item_func_set_user_var::fix_fields() to a separate
  method, Item_func_set_user_var::set_entry().
sql/item_func.h:
  1. The Item_func_set_user_var::set_entry() method has been
  added to update Item_func_set_user_var::entry.
  
  2. The Item_func_set_user_var::entry_thd field has beend
  added to update Item_func_set_user_var::entry only when
  needed.
sql/sql_base.cc:
  Fix: setup_fiedls() calls Item_func_set_user_var::set_entry()
  for all items from the thd->lex->set_var_list before the first
  call of ::fix_fields().
sql/sql_lex.cc:
  The lex_start function has been modified to reset
  the st_lex::set_var_list list.
sql/sql_lex.h:
  New st_lex::set_var_list field has been added to
  memorize all user variable assignments in the current
  select query.
sql/sql_yacc.yy:
  The variable_aux rule has been modified to memorize
  in-query user variable assignments in the
  st_lex::set_var_list list.
2008-09-18 13:38:44 +05:00
unknown
9a10c20ba9 Merge mysql.com:/home/gluh/MySQL/Merge/5.1
into  mysql.com:/home/gluh/MySQL/Merge/5.1-opt


BitKeeper/etc/ignore:
  auto-union
client/mysql.cc:
  Auto merged
client/mysqltest.c:
  Auto merged
include/mysql_com.h:
  Auto merged
libmysql/CMakeLists.txt:
  Auto merged
libmysqld/lib_sql.cc:
  Auto merged
mysql-test/r/archive.result:
  Auto merged
mysql-test/r/create.result:
  Auto merged
mysql-test/r/delayed.result:
  Auto merged
mysql-test/r/func_misc.result:
  Auto merged
mysql-test/r/innodb.result:
  Auto merged
mysql-test/r/innodb_mysql.result:
  Auto merged
mysql-test/r/merge.result:
  Auto merged
mysql-test/r/ps.result:
  Auto merged
mysql-test/r/type_date.result:
  Auto merged
mysql-test/suite/rpl/r/rpl_innodb_bug28430.result:
  Auto merged
mysql-test/t/create.test:
  Auto merged
mysql-test/t/func_misc.test:
  Auto merged
mysql-test/t/information_schema.test:
  Auto merged
mysql-test/t/merge.test:
  Auto merged
mysql-test/t/subselect.test:
  Auto merged
mysql-test/t/type_date.test:
  Auto merged
mysql-test/t/type_datetime.test:
  Auto merged
mysql-test/t/variables.test:
  Auto merged
mysys/queues.c:
  Auto merged
sql/events.cc:
  Auto merged
sql/field.cc:
  Auto merged
sql/field.h:
  Auto merged
sql/ha_partition.cc:
  Auto merged
sql/handler.cc:
  Auto merged
sql/item.cc:
  Auto merged
sql/item_cmpfunc.cc:
  Auto merged
sql/item_func.h:
  Auto merged
sql/mysql_priv.h:
  Auto merged
sql/mysqld.cc:
  Auto merged
sql/opt_range.cc:
  Auto merged
sql/protocol.cc:
  Auto merged
sql/set_var.cc:
  Auto merged
sql/set_var.h:
  Auto merged
sql/slave.cc:
  Auto merged
sql/sql_class.cc:
  Auto merged
sql/sql_class.h:
  Auto merged
sql/sql_db.cc:
  Auto merged
sql/sql_insert.cc:
  Auto merged
sql/sql_parse.cc:
  Auto merged
sql/sql_partition.cc:
  Auto merged
sql/sql_plugin.cc:
  Auto merged
sql/sql_select.cc:
  Auto merged
sql/sql_string.cc:
  Auto merged
sql/sql_table.cc:
  Auto merged
sql/sql_yacc.yy:
  Auto merged
sql/table.cc:
  Auto merged
sql/table.h:
  Auto merged
storage/myisam/ha_myisam.cc:
  Auto merged
storage/myisam/mi_check.c:
  Auto merged
storage/myisam/mi_open.c:
  Auto merged
tests/mysql_client_test.c:
  Auto merged
mysql-test/lib/mtr_report.pl:
  manual merge
mysql-test/r/myisam.result:
  manual merge
mysql-test/r/partition.result:
  manual merge
mysql-test/r/user_var.result:
  manual merge
mysql-test/t/myisam.test:
  manual merge
mysql-test/t/partition.test:
  manual merge
mysql-test/t/user_var.test:
  manual merge
sql/item.h:
  manual merge
sql/item_func.cc:
  manual merge
storage/myisammrg/ha_myisammrg.cc:
  manual merge
2007-12-13 15:56:04 +04:00
unknown
0ad7fc58c7 Bug#32482: Crash for a query with ORDER BY a user variable.
The Item_func_set_user_var::register_field_in_read_map() did not check 
that the result_field was null.This caused server crashes for queries that
required order by such a field and were executed without using a temporary
table.

The Item_func_set_user_var::register_field_in_read_map() now checks the
result_field to be not null.


mysql-test/t/user_var.test:
  Added a test case for the bug#32482: Crash for a query with ORDER BY a user variable.
mysql-test/r/user_var.result:
  Added a test case for the bug#32482: Crash for a query with ORDER BY a user variable.
sql/item_func.cc:
  Bug#32482: Crash for a query with ORDER BY a user variable.
  The Item_func_set_user_var::register_field_in_read_map() now checks the
  result_field to be not null.
2007-12-07 22:54:47 +03:00
unknown
011eb3dffe Fix for bug #32260: User variables in query cause server crash
Problem: there's no guarantee that the user variable item's result_field
is assigned when we're adjusting its table read map.
  
Fix: check the result_field before using it.


mysql-test/r/user_var.result:
  Fix for bug #32260: User variables in query cause server crash
    - test result.
mysql-test/t/user_var.test:
  Fix for bug #32260: User variables in query cause server crash
    - test case.
sql/item_func.cc:
  Fix for bug #32260: User variables in query cause server crash
    - using the result_field ensure it is set.
2007-11-17 11:20:50 +04:00
unknown
f4caa3025a Merge olga.mysql.com:/home/igor/mysql-5.1
into  olga.mysql.com:/home/igor/mysql-5.1-opt-merge


mysql-test/r/alter_table.result:
  Auto merged
mysql-test/r/create.result:
  Auto merged
mysql-test/r/innodb_mysql.result:
  Auto merged
mysql-test/r/sp.result:
  Auto merged
mysql-test/r/user_var.result:
  Auto merged
mysql-test/t/alter_table.test:
  Auto merged
mysql-test/t/sp.test:
  Auto merged
mysql-test/t/strict.test:
  Auto merged
mysql-test/t/subselect3.test:
  Auto merged
sql/field.h:
  Auto merged
sql/handler.h:
  Auto merged
sql/item_func.cc:
  Auto merged
sql/item_func.h:
  Auto merged
sql/mysqld.cc:
  Auto merged
sql/sp_head.cc:
  Auto merged
sql/sql_base.cc:
  Auto merged
sql/sql_class.h:
  Auto merged
sql/sql_select.cc:
  Auto merged
sql/sql_update.cc:
  Auto merged
mysql-test/r/ps_2myisam.result:
  Manual merge.
mysql-test/r/ps_3innodb.result:
  Manual merge.
mysql-test/r/ps_4heap.result:
  Manual merge.
mysql-test/r/ps_5merge.result:
  Manual merge.
mysql-test/r/ps_7ndb.result:
  Manual merge.
sql/sql_table.cc:
  Manual merge.
sql/sql_view.cc:
  Manual merge.
2007-06-03 22:52:02 -07:00
unknown
687191a078 Merge moonbone.local:/mnt/gentoo64/work/test-5.0-opt-mysql
into  moonbone.local:/mnt/gentoo64/work/test-5.1-opt-mysql


mysql-test/r/user_var.result:
  Auto merged
mysql-test/t/user_var.test:
  Auto merged
sql/item_func.cc:
  Auto merged
sql/item_func.h:
  Auto merged
2007-06-03 16:06:55 +04:00
unknown
e19dcfa91f user_var.result:
Corrected test case result for the bug#28494.
item_func.h, item_func.cc:
  Corrected function names after fix for the bug#28494.


mysql-test/r/user_var.result:
  Corrected test case result for the bug#28494.
sql/item_func.h:
  Corrected function names after fix for the bug#28494.
sql/item_func.cc:
  Corrected function names after fix for the bug#28494.
2007-06-03 15:56:48 +04:00
unknown
4ef028600a user_var.result, user_var.test:
Extended test case for the bug#28494.


mysql-test/t/user_var.test:
  Extended test case for the bug#28494.
mysql-test/r/user_var.result:
  Extended test case for the bug#28494.
2007-06-03 14:46:09 +04:00
unknown
45714d35ad Merge moonbone.local:/mnt/gentoo64/work/test-5.0-opt-mysql
into  moonbone.local:/mnt/gentoo64/work/test-5.1-opt-mysql


sql/item_func.cc:
  Auto merged
sql/item_func.h:
  Auto merged
mysql-test/r/user_var.result:
  Manual merge
mysql-test/t/user_var.test:
  Manual merge
2007-06-02 23:49:52 +04:00
unknown
8ab1830f9a Bug#28494: Grouping by Item_func_set_user_var produces incorrect result.
This is an additional fix.
Item::val_xxx methods are supposed to use original data source and
Item::val_xxx_result methods to use the item's result field. But for the
Item_func_set_user_var class val_xxx_result methods were mapped to val_xxx
methods. This leads, in particular, to producing bad sort keys and thus
wrong order of the result set of queries with group by/order by clauses.

The set of val_xxx_result methods is added to the Item_func_set_user_var
class. It's the same as the val_xxx set of method but uses the result_field
to return a value.


mysql-test/t/user_var.test:
  Corrected test case for hte bug#28494.
mysql-test/r/user_var.result:
  Corrected test case for hte bug#28494.
sql/item_func.cc:
  Bug#28494: Grouping by Item_func_set_user_var produces incorrect result.
  The set of val_xxx_result methods is added to the Item_func_set_user_var
  class. It's the same as the val_xxx set of method but uses the result_field
  to return a value.
sql/item_func.h:
  Bug#28494: Grouping by Item_func_set_user_var produces incorrect result.
  The set of val_xxx_result methods is added to the Item_func_set_user_var
  class.
2007-06-02 23:17:46 +04:00
unknown
77ea801dec Post-merge fix. 2007-05-31 23:31:59 -07:00
unknown
5d5c66fb66 Merge gleb.loc:/home/uchum/work/bk/mysql-5.0-opt
into  gleb.loc:/home/uchum/work/bk/mysql-5.1-opt


mysql-test/r/user_var.result:
  Auto merged
mysql-test/r/view.result:
  Auto merged
mysql-test/t/user_var.test:
  Auto merged
sql/item_func.cc:
  Auto merged
sql/item_func.h:
  Auto merged
sql/sql_view.cc:
  Auto merged
sql/table.cc:
  Auto merged
sql/table.h:
  Auto merged
mysql-test/t/view.test:
  Merge with 5.0-opt.
2007-06-01 03:05:25 +05:00
unknown
b4a35cd76e Bug#28494: Grouping by Item_func_set_user_var produces incorrect result.
The end_update() function uses the Item::save_org_in_field() function to
save original values of items into the group buffer. But for the 
Item_func_set_user_var this method was mapped to the save_in_field method.
The latter function wrongly decides to use the result_field. This leads to
saving incorrect value in the grouping buffer and wrong result of the whole
query.

The can_use_result_field argument of the bool type is added to the
Item_func_set_user_var::save_in_field() function. If it is set to FALSE
then the item's result field won't be used. Otherwise it will be detected
whether the result field will be used (old behaviour).
Two wrapping functions for the function above are added to the 
Item_func_set_user_var class:
the save_in_field(Field *field, bool no_conversions) - it calls the above
function with the can_use_result_field set to TRUE.
the save_org_in_field(Field *field) - same, but the can_use_result_field
is set to FALSE.


mysql-test/t/user_var.test:
  Added a test case for the bug#28494: Grouping by Item_func_set_user_var
  produces incorrect result.
mysql-test/r/user_var.result:
  Added a test case for the bug#28494: Grouping by Item_func_set_user_var
  produces incorrect result.
sql/item_func.cc:
  Bug#28494: Grouping by Item_func_set_user_var produces incorrect result.
  The can_use_result_field argument of the bool type is added to the
  Item_func_set_user_var::save_in_field() function. If it is set to FALSE
  then the item's result field won't be used. Otherwise it will be detected
  whether the result field will be used (old behaviour).
sql/item_func.h:
  Bug#28494: Grouping by Item_func_set_user_var produces incorrect result.
  The can_use_result_field argument of the bool type is added to the
  Item_func_set_user_var::save_in_field() function.
  Two wrapping functions for the function above are added to the 
  Item_func_set_user_var class:
  the save_in_field(Field *field, bool no_conversions) - it calls the above
  function with the can_use_result_field set to TRUE.
  the save_org_in_field(Field *field) - same, but the can_use_result_field
  is set to FALSE.
2007-06-01 01:17:14 +04:00
unknown
755ae21b82 Bug#26277 User variable returns one type in SELECT @v and other for CREATE as SELECT @v
- Adding variable m_cached_result_type to keep the variable type consistent
  during the execution of a statement.
- Before each result set is returned to the client the description of each
  column is sent as meta data.
  Previously the result type for a column could change if the hash variable
  entry changed between statements. This caused the result set of the query
  to alternate column types in certain cases which is not supported by MySQL
  client-server protocol. Example:
  Previously this sequence:
    SET @a:=1;
    SELECT @a:="text", @a;
  would return "text", "text";
 
  After the change the SELECT returns "text", 0
  The reson for this is that previously the result set from 'SELECT @a;'
  would always be of the type STRING, whereas now the type of the variable
  is taken from the last SET statement. However, 'SELECT @a:="text"' will
  return type of STRING since the right side of the assignment is used.


mysql-test/r/ps_2myisam.result:
  Changed test result because SQL type of a user variable now
  more accurately represents its Item type: since Item type of a variable
  can be either STRING, INT, DECIMAL or DOUBLE, SQL type of the
  result set metadata now can be either MYSQL_TYPE_VARCHAR,
  MYSQL_TYPE_LONGLONG, MYSQL_TYPE_NEWDECIMAL or MYSQL_TYPE_DOUBLE.
  
  Previously it was always MYSQL_TYPE_VARCHAR.
  
  In particular, integer variables now have changed from
  MYSQL_TYPE_VARCHAR to MYSQL_TYPE_LONGLONG.
mysql-test/r/ps_3innodb.result:
  Changed test result because SQL type of a user variable now
  more accurately represents its Item type: since Item type of a variable
  can be either STRING, INT, DECIMAL or DOUBLE, SQL type of the
  result set metadata now can be either MYSQL_TYPE_VARCHAR,
  MYSQL_TYPE_LONGLONG, MYSQL_TYPE_NEWDECIMAL or MYSQL_TYPE_DOUBLE.
  
  Previously it was always MYSQL_TYPE_VARCHAR.
  
  In particular, integer variables now have changed from
  MYSQL_TYPE_VARCHAR to MYSQL_TYPE_LONGLONG.
mysql-test/r/ps_4heap.result:
  Changed test result because SQL type of a user variable now
  more accurately represents its Item type: since Item type of a variable
  can be either STRING, INT, DECIMAL or DOUBLE, SQL type of the
  result set metadata now can be either MYSQL_TYPE_VARCHAR,
  MYSQL_TYPE_LONGLONG, MYSQL_TYPE_NEWDECIMAL or MYSQL_TYPE_DOUBLE.
  
  Previously it was always MYSQL_TYPE_VARCHAR.
  
  In particular, integer variables now have changed from
  MYSQL_TYPE_VARCHAR to MYSQL_TYPE_LONGLONG.
mysql-test/r/ps_5merge.result:
  Changed test result because SQL type of a user variable now
  more accurately represents its Item type: since Item type of a variable
  can be either STRING, INT, DECIMAL or DOUBLE, SQL type of the
  result set metadata now can be either MYSQL_TYPE_VARCHAR,
  MYSQL_TYPE_LONGLONG, MYSQL_TYPE_NEWDECIMAL or MYSQL_TYPE_DOUBLE.
  
  Previously it was always MYSQL_TYPE_VARCHAR.
  
  In particular, integer variables now have changed from
  MYSQL_TYPE_VARCHAR to MYSQL_TYPE_LONGLONG.
mysql-test/r/ps_7ndb.result:
  Changed test result because SQL type of a user variable now
  more accurately represents its Item type: since Item type of a variable
  can be either STRING, INT, DECIMAL or DOUBLE, SQL type of the
  result set metadata now can be either MYSQL_TYPE_VARCHAR,
  MYSQL_TYPE_LONGLONG, MYSQL_TYPE_NEWDECIMAL or MYSQL_TYPE_DOUBLE.
  
  Previously it was always MYSQL_TYPE_VARCHAR.
  
  In particular, integer variables now have changed from
  MYSQL_TYPE_VARCHAR to MYSQL_TYPE_LONGLONG.
mysql-test/r/sp-vars.result:
  Added test case. Previously variables could change their variable type during 
  the execution of a statement.
  Which variable type to use in the statement is specified in
  any previous statement.
mysql-test/r/type_date.result:
  This test case result is changed because it is no longer allowed for user
  variables to change their variable type during the execution of a statement.
  The determination of which variable type to use in the statement is specified in
  any previous statement.
mysql-test/r/user_var.result:
  This test case result is changed because it is no longer allowed for user
  variables to change their variable type during the execution of a statement.
  The determination of which variable type to use in the statement is specified in
  any previous statement.
mysql-test/t/sp-vars.test:
  Added test case. Previously variables could change their variable type during 
  the execution of a statement.
  Which variable type to use in the statement is specified in
  any previous statement.
mysql-test/t/type_date.test:
  This test case result is changed because it is no longer allowed for user
  variables to change their variable type during the execution of a statement.
  The determination of which variable type to use in the statement is specified in
  any previous statement.
sql/item_func.cc:
  Adding variable m_cached_result_type to keep the variable type consistent
  during the execution of a statement.
  Previously the result type could change if the hash variable entry changed
  between statements. This caused the result set of the query to alternate
  column types in certain cases.
sql/item_func.h:
  Adding variable m_cached_result_type to keep the variable type consistent
  during the execution of a statement.
  Previously the result type could change if the hash variable entry changed
  between statements. This caused the result set of the query to alternate
  column types in certain cases.
2007-05-18 12:44:03 +02:00
unknown
93c01eb13e Merge mysql.com:/home/gluh/MySQL/Merge/5.0-opt
into  mysql.com:/home/gluh/MySQL/Merge/5.1-opt


libmysql/libmysql.c:
  Auto merged
mysql-test/r/join_nested.result:
  Auto merged
mysql-test/r/ps.result:
  Auto merged
mysql-test/r/type_binary.result:
  Auto merged
mysql-test/r/user_var.result:
  Auto merged
mysql-test/t/ps.test:
  Auto merged
mysql-test/t/subselect.test:
  Auto merged
mysql-test/t/type_newdecimal.test:
  Auto merged
mysql-test/t/user_var.test:
  Auto merged
sql/field.h:
  Auto merged
sql/filesort.cc:
  Auto merged
sql/handler.cc:
  Auto merged
sql/item_cmpfunc.cc:
  Auto merged
sql/item_cmpfunc.h:
  Auto merged
sql/item_func.cc:
  Auto merged
sql/item_func.h:
  Auto merged
sql/item_subselect.cc:
  Auto merged
sql/item_timefunc.cc:
  Auto merged
sql/mysql_priv.h:
  Auto merged
sql/sql_class.h:
  Auto merged
sql/sql_lex.cc:
  Auto merged
sql/sql_parse.cc:
  Auto merged
sql-common/client.c:
  Auto merged
sql-common/my_time.c:
  Auto merged
sql/sql_select.cc:
  Auto merged
sql/table.cc:
  Auto merged
strings/decimal.c:
  Auto merged
sql/mysqld.cc:
  manual merge
sql/sql_base.cc:
  manual merge
2007-01-10 14:14:22 +04:00
unknown
f094fe551a Fixed bug#16861: User defined variable can have a wrong value if a tmp table was
used.

The Item::save_in_field() function is called from fill_record() to fill the 
new row with data while execution of the CREATE TABLE ... SELECT statement.
Item::save_in_field() calls val_xxx() methods in order to get values.
val_xxx() methods do not take into account the result field. Due to this
Item_func_set_user_var::val_xxx() methods returns values from the original
table, not from the temporary one.

The save_in_field() member function is added to the Item_func_set_user_var
class. It detects whether the result field should be used and properly updates
the value of the user variable.


sql/item_func.cc:
  Bug#16861: User defined variable can have a wrong value if a tmp table was used.
  Added the save_in_field() member function to the Item_func_set_user_var class.
sql/item_func.h:
  Bug#16861: User defined variable can have a wrong value if a tmp table was used.
  Added the save_in_field() member function to the Item_func_set_user_var class.
mysql-test/r/user_var.result:
  Extended the test case for bug#18681: User defined variable can have a wrong value if
  a tmp table was used.
mysql-test/t/user_var.test:
  Extended the test case for bug#18681: User defined variable can have a wrong value if
  a tmp table was used.
2007-01-09 23:24:56 +03:00
unknown
7daf06b055 Merge rolltop.ignatz42.dyndns.org:/mnt/storeage/bug19024/my50-bug19024
into  rolltop.ignatz42.dyndns.org:/mnt/storeage/bug19024/my51-bug19024


mysql-test/r/user_var.result:
  Auto merged
mysql-test/t/user_var.test:
  Auto merged
sql/set_var.cc:
  Auto merged
2006-10-04 10:56:04 -04:00
unknown
aaef575f9f Bug #19024- SHOW COUNT(*) WARNINGS not return Errors
The server variable warning_count should include the number of warnings, errors and notes according to the manual


mysql-test/r/user_var.result:
  Added warning_count results.
mysql-test/t/user_var.test:
  Added test case for warning_count.
sql/set_var.cc:
  Added number errors to warning_count.
2006-10-04 10:49:39 -04:00
unknown
f57382196b Merge moonbone.local:/work/tmp_merge-5.0-mysql
into  moonbone.local:/work/tmp_merge-5.1-opt-mysql


BUILD/check-cpu:
  Auto merged
include/config-netware.h:
  Auto merged
mysql-test/r/func_time.result:
  Auto merged
mysql-test/r/group_by.result:
  Auto merged
mysql-test/r/join_outer.result:
  Auto merged
mysql-test/r/ndb_condition_pushdown.result:
  Auto merged
mysql-test/r/range.result:
  Auto merged
mysql-test/r/select.result:
  Auto merged
mysql-test/r/subselect.result:
  Auto merged
mysql-test/r/type_datetime.result:
  Auto merged
mysql-test/r/user_var.result:
  Auto merged
mysql-test/r/view.result:
  Auto merged
mysql-test/t/func_time.test:
  Auto merged
mysql-test/t/range.test:
  Auto merged
mysql-test/t/select.test:
  Auto merged
mysql-test/t/type_datetime.test:
  Auto merged
mysql-test/t/view.test:
  Auto merged
sql/ha_innodb.cc:
  Auto merged
sql/item.cc:
  Auto merged
sql/item.h:
  Auto merged
sql/item_func.cc:
  Auto merged
sql/item_func.h:
  Auto merged
sql/item_subselect.cc:
  Auto merged
sql/item_timefunc.cc:
  Auto merged
sql/opt_range.h:
  Auto merged
sql/set_var.cc:
  Auto merged
sql/sql_acl.cc:
  Auto merged
sql/sql_class.cc:
  Auto merged
sql/sql_delete.cc:
  Auto merged
sql/sql_insert.cc:
  Auto merged
sql/sql_load.cc:
  Auto merged
sql/sql_parse.cc:
  Auto merged
sql/sql_select.cc:
  Auto merged
sql/sql_update.cc:
  Auto merged
storage/innobase/btr/btr0btr.c:
  Auto merged
storage/innobase/buf/buf0buf.c:
  Auto merged
storage/innobase/dict/dict0dict.c:
  Auto merged
storage/innobase/fil/fil0fil.c:
  Auto merged
storage/innobase/fsp/fsp0fsp.c:
  Auto merged
storage/innobase/include/buf0buf.ic:
  Auto merged
storage/innobase/log/log0log.c:
  Auto merged
storage/innobase/log/log0recv.c:
  Auto merged
storage/innobase/os/os0file.c:
  Auto merged
storage/innobase/row/row0sel.c:
  Auto merged
storage/innobase/srv/srv0start.c:
  Auto merged
storage/innobase/ut/ut0dbg.c:
  Auto merged
tests/mysql_client_test.c:
  Auto merged
client/mysqltest.c:
  Manual merge
mysql-test/r/innodb_mysql.result:
  Manual merge
mysql-test/t/innodb_mysql.test:
  Manual merge
mysql-test/t/join_outer.test:
  Manual merge
sql/item_cmpfunc.cc:
  Manual merge
sql/mysql_priv.h:
  Manual merge
sql/opt_range.cc:
  Manual merge
sql/sql_base.cc:
  Manual merge
storage/innobase/include/btr0cur.ic:
  Manual merge
storage/innobase/row/row0mysql.c:
  Manual merge
2006-08-29 18:58:50 +04:00
unknown
c623e54fb8 Fixed bug#16861: User defined variable can have a wrong value if a tmp table was
used.

Sorting by RAND() uses a temporary table in order to get a correct results.
User defined variable was set during filling the temporary table and later
on it is substituted for its value from the temporary table. Due to this
it contains the last value stored in the temporary table.

Now if the result_field is set for the Item_func_set_user_var object it 
updates variable from the result_field value when being sent to a client.

The Item_func_set_user_var::check() now accepts a use_result_field
parameter. Depending on its value the result_field or the args[0] is used
to get current value.


mysql-test/r/user_var.result:
  Added a test case for bug#16861: User defined variable can have a wrong value if a tmp table was used.
mysql-test/t/user_var.test:
  Added a test case for bug#16861: User defined variable can have a wrong value if a tmp table was used.
sql/item_func.cc:
  Fixed bug#16861: User defined variable can have a wrong value if a tmp table was used.
  Now if the result_field is set for the Item_func_set_user_var object it 
  updates variable from the result_field value when being sent to a client.
  
  The Item_func_set_user_var::check() now accepts a use_result_field
  parameter. Depending on its value the result_field or the args[0] is used
  to get current value.
sql/item_func.h:
  Fixed bug#16861: User defined variable can have a wrong value if a tmp table was used.
  Added a new SUSERVAR_FUNC function type.
  Updated the Item_func_set_user_var::check() function declaration.
  Added the Item_func_set_user_var::send() member function.
sql/set_var.cc:
  Fixed bug#16861: User defined variable can have a wrong value if a tmp table was used.
  Modified to use updated Item_func_set_user_var::check() function.
sql/sql_class.cc:
  Fixed bug#16861: User defined variable can have a wrong value if a tmp table was used.
  Modified to use updated Item_func_set_user_var::check() function.
sql/sql_select.cc:
  Fixed bug#16861: User defined variable can have a wrong value if a tmp table was used.
  Now an Item_func_set_user_var object isn't substituted for an Item_field object after filling a temporary table.
2006-08-22 17:37:41 +04:00
unknown
f68085c4e7 Merge bodhi.local:/opt/local/work/tmp_merge
into  bodhi.local:/opt/local/work/mysql-5.1-runtime-merge


BitKeeper/etc/ignore:
  auto-union
BitKeeper/deleted/.del-im_options_set.result~59278f56be61d921:
  Auto merged
BitKeeper/deleted/.del-mysqld.dsp~ffdbf2d234e23e56:
  Auto merged
BitKeeper/deleted/.del-mysys.dsp~32695fee91189326:
  Auto merged
BitKeeper/deleted/.del-im_options_set.imtest~b53d9d60e5684833:
  Auto merged
BitKeeper/deleted/.del-im_options_unset.imtest~768eb186b51d0048:
  Auto merged
BitKeeper/deleted/.del-im_options_unset.result~20a4790cd3c70a4f:
  Auto merged
client/mysql.cc:
  Auto merged
client/mysqlbinlog.cc:
  Auto merged
client/mysqlcheck.c:
  Auto merged
client/mysqldump.c:
  Auto merged
client/mysqltest.c:
  Auto merged
dbug/dbug.c:
  Auto merged
extra/perror.c:
  Auto merged
extra/yassl/src/yassl_imp.cpp:
  Auto merged
extra/yassl/src/yassl_int.cpp:
  Auto merged
include/mysql.h:
  Auto merged
include/mysql_com.h:
  Auto merged
libmysql/libmysql.c:
  Auto merged
mysql-test/r/cast.result:
  Auto merged
mysql-test/r/date_formats.result:
  Auto merged
mysql-test/r/federated.result:
  Auto merged
mysql-test/r/func_compress.result:
  Auto merged
mysql-test/r/func_group.result:
  Auto merged
mysql-test/r/func_time.result:
  Auto merged
mysql-test/r/gis-rtree.result:
  Auto merged
mysql-test/r/gis.result:
  Auto merged
mysql-test/r/im_daemon_life_cycle.result:
  Auto merged
mysql-test/r/im_utils.result:
  Auto merged
mysql-test/r/join_outer.result:
  Auto merged
mysql-test/r/mysqlcheck.result:
  Auto merged
mysql-test/r/rpl_sp.result:
  Auto merged
mysql-test/r/rpl_trigger.result:
  Auto merged
mysql-test/r/sp-code.result:
  Auto merged
mysql-test/r/sp-security.result:
  Auto merged
mysql-test/r/strict.result:
  Auto merged
mysql-test/r/type_blob.result:
  Auto merged
mysql-test/r/type_datetime.result:
  Auto merged
mysql-test/r/type_ranges.result:
  Auto merged
mysql-test/r/udf.result:
  Auto merged
mysql-test/r/user_var.result:
  Auto merged
mysql-test/t/cast.test:
  Auto merged
mysql-test/t/disabled.def:
  Auto merged
mysql-test/t/func_group.test:
  Auto merged
mysql-test/t/func_time.test:
  Auto merged
mysql-test/t/im_daemon_life_cycle.imtest:
  Auto merged
mysql-test/t/im_life_cycle.imtest:
  Auto merged
mysql-test/t/im_utils.imtest:
  Auto merged
mysql-test/t/mysql.test:
  Auto merged
mysql-test/t/mysqlbinlog.test:
  Auto merged
mysql-test/t/mysqlcheck.test:
  Auto merged
mysql-test/t/ps.test:
  Auto merged
mysql-test/t/rpl_trigger.test:
  Auto merged
mysql-test/t/sp-security.test:
  Auto merged
mysql-test/t/strict.test:
  Auto merged
mysql-test/t/udf.test:
  Auto merged
sql/field.cc:
  Auto merged
sql/item.cc:
  Auto merged
sql/item_func.cc:
  Auto merged
sql/item_func.h:
  Auto merged
sql/item_strfunc.cc:
  Auto merged
sql/item_strfunc.h:
  Auto merged
sql/item_subselect.cc:
  Auto merged
sql/item_sum.h:
  Auto merged
sql/item_timefunc.cc:
  Auto merged
sql/mysqld.cc:
  Auto merged
sql/protocol.cc:
  Auto merged
sql/slave.cc:
  Auto merged
sql/sp.cc:
  Auto merged
sql/sp_head.h:
  Auto merged
sql/sql_base.cc:
  Auto merged
sql/sql_class.h:
  Auto merged
sql/sql_lex.cc:
  Auto merged
sql/sql_parse.cc:
  Auto merged
sql/sql_prepare.cc:
  Auto merged
sql/sql_udf.cc:
  Auto merged
sql/sql_view.cc:
  Auto merged
sql/table.cc:
  Auto merged
sql-common/client.c:
  Auto merged
sql-common/my_time.c:
  Auto merged
sql/table.h:
  Auto merged
storage/ndb/src/kernel/error/ndbd_exit_codes.c:
  Auto merged
storage/ndb/src/mgmsrv/ConfigInfo.cpp:
  Auto merged
mysql-test/r/im_life_cycle.result:
  e
  use local
mysql-test/r/ps.result:
  use local
client/Makefile.am:
  Manual merge.
client/mysqlimport.c:
  Manual merge.
configure.in:
  Manual merge.
mysql-test/mysql-test-run.pl:
  Manual merge.
mysql-test/r/mysqldump.result:
  Manual merge.
mysql-test/r/mysqltest.result:
  Manual merge.
mysql-test/r/ndb_basic.result:
  Manual merge.
mysql-test/r/rpl_view.result:
  Manual merge.
mysql-test/r/show_check.result:
  Manual merge.
mysql-test/r/sp-error.result:
  Manual merge.
mysql-test/r/sp.result:
  Manual merge.
mysql-test/r/union.result:
  Manual merge.
mysql-test/t/mysqldump.test:
  Manual merge.
mysql-test/t/mysqltest.test:
  Manual merge.
mysql-test/t/ndb_basic.test:
  Manual merge.
mysql-test/t/rpl_sp.test:
  Manual merge.
mysql-test/t/rpl_view.test:
  Manual merge.
mysql-test/t/show_check.test:
  Manual merge.
mysql-test/t/sp-error.test:
  Manual merge.
mysql-test/t/sp.test:
  Manual merge.
sql/item_sum.cc:
  Manual merge.
sql/mysql_priv.h:
  Manual merge.
sql/sp_head.cc:
  Manual merge.
sql/sql_db.cc:
  Manual merge.
sql/sql_delete.cc:
  Manual merge.
sql/sql_lex.h:
  Manual merge.
sql/sql_show.cc:
  Manual merge.
sql/sql_table.cc:
  Manual merge.
sql/sql_trigger.cc:
  Manual merge.
sql/sql_yacc.yy:
  Manual merge.
tests/mysql_client_test.c:
  Manual merge.
2006-08-12 21:06:51 +04:00
unknown
f067dfe1c6 Bug #7498 User variable SET saves SIGNED BIGINT as UNSIGNED BIGINT
- Add unsigned flag to user_var_entry, used when 'type' is INT_RESULT
- Propagate unsigned flag from the query executed by Item_single_row_subselect


mysql-test/r/user_var.result:
  Update test results
mysql-test/t/user_var.test:
  Add test case
sql/item_func.cc:
  Add unsigned_flag to user_var_entry. Used when 'type' is INT_RESULT
  Pass unsigned_flag to 'update_hash' if type is INT_RESULT
sql/item_func.h:
  Removed unused variable save_buff
  Add parameter unsigned_arg to 'update_hash'
sql/item_subselect.cc:
  Propagate unsigned_flag to Item_singlerow_subselect from the items in the select to the cached items.
sql/sql_class.h:
  Add unsigned_flag to user_var_entry. Used when 'type' is INT_RESULT
2006-06-09 19:35:54 +02:00
unknown
9f7548ae36 Merge mysql.com:/home/jimw/my/tmp_merge
into  mysql.com:/home/jimw/my/mysql-5.1-clean


mysql-test/r/user_var.result:
  Auto merged
mysql-test/r/variables.result:
  Auto merged
mysql-test/t/variables.test:
  Auto merged
sql/item.cc:
  Auto merged
sql/item_func.cc:
  Auto merged
sql/sql_select.cc:
  Auto merged
mysql-test/mysql-test-run.pl:
  Resolve conflict
mysql-test/ndb/ndbcluster.sh:
  Resolve conflict
sql/set_var.cc:
  Resolve conflict
sql/share/errmsg.txt:
  Resolve conflict
2006-04-30 09:43:26 -07:00
unknown
47ce2876b5 Remove obsolete test
mysql-test/r/user_var.result:
  Update results
mysql-test/t/user_var.test:
  Remove unnecessary test
2006-04-26 17:09:41 -07:00
unknown
31a7a0d646 Bug#10460 SHOW CREATE TABLE uses inconsistent upper/lower case
mysql-test/r/alter_table.result:
  Update test result
mysql-test/r/analyse.result:
  Update test result
mysql-test/r/archive.result:
  Update test result
mysql-test/r/archive_bitfield.result:
  Update test result
mysql-test/r/archive_gis.result:
  Update test result
mysql-test/r/bdb.result:
  Update test result
mysql-test/r/bdb_gis.result:
  Update test result
mysql-test/r/bigint.result:
  Update test result
mysql-test/r/binary.result:
  Update test result
mysql-test/r/case.result:
  Update test result
mysql-test/r/cast.result:
  Update test result
mysql-test/r/constraints.result:
  Update test result
mysql-test/r/create.result:
  Update test result
mysql-test/r/ctype_collate.result:
  Update test result
mysql-test/r/ctype_create.result:
  Update test result
mysql-test/r/ctype_latin1_de.result:
  Update test result
mysql-test/r/ctype_many.result:
  Update test result
mysql-test/r/ctype_mb.result:
  Update test result
mysql-test/r/ctype_recoding.result:
  Update test result
mysql-test/r/ctype_sjis.result:
  Update test result
mysql-test/r/ctype_tis620.result:
  Update test result
mysql-test/r/ctype_ucs.result:
  Update test result
mysql-test/r/ctype_ujis.result:
  Update test result
mysql-test/r/ctype_utf8.result:
  Update test result
mysql-test/r/default.result:
  Update test result
mysql-test/r/events.result:
  Update test result
mysql-test/r/federated.result:
  Update test result
mysql-test/r/fulltext.result:
  Update test result
mysql-test/r/func_gconcat.result:
  Update test result
mysql-test/r/func_group.result:
  Update test result
mysql-test/r/func_math.result:
  Update test result
mysql-test/r/func_misc.result:
  Update test result
mysql-test/r/func_str.result:
  Update test result
mysql-test/r/func_system.result:
  Update test result
mysql-test/r/gis-rtree.result:
  Update test result
mysql-test/r/heap.result:
  Update test result
mysql-test/r/index_merge_innodb.result:
  Update test result
mysql-test/r/information_schema.result:
  Update test result
mysql-test/r/innodb.result:
  Update test result
mysql-test/r/innodb_gis.result:
  Update test result
mysql-test/r/key.result:
  Update test result
mysql-test/r/merge.result:
  Update test result
mysql-test/r/myisam.result:
  Update test result
mysql-test/r/mysqldump-max.result:
  Update test result
mysql-test/r/mysqldump.result:
  Update test result
mysql-test/r/ndb_bitfield.result:
  Update test result
mysql-test/r/ndb_gis.result:
  Update test result
mysql-test/r/ndb_partition_key.result:
  Update test result
mysql-test/r/null.result:
  Update test result
mysql-test/r/partition.result:
  Update test result
mysql-test/r/partition_02myisam.result:
  Update test result
mysql-test/r/partition_mgm_err.result:
  Update test result
mysql-test/r/partition_range.result:
  Update test result
mysql-test/r/ps_2myisam.result:
  Update test result
mysql-test/r/ps_3innodb.result:
  Update test result
mysql-test/r/ps_4heap.result:
  Update test result
mysql-test/r/ps_5merge.result:
  Update test result
mysql-test/r/ps_6bdb.result:
  Update test result
mysql-test/r/rpl_mixed_ddl_dml.result:
  Update test result
mysql-test/r/rpl_multi_engine.result:
  Update test result
mysql-test/r/rpl_ndb_UUID.result:
  Update test result
mysql-test/r/show_check.result:
  Update test result
mysql-test/r/sp-vars.result:
  Update test result
mysql-test/r/sp.result:
  Update test result
mysql-test/r/sql_mode.result:
  Update test result
mysql-test/r/strict.result:
  Update test result
mysql-test/r/subselect.result:
  Update test result
mysql-test/r/symlink.result:
  Update test result
mysql-test/r/synchronization.result:
  Update test result
mysql-test/r/system_mysql_db.result:
  Update test result
mysql-test/r/temp_table.result:
  Update test result
mysql-test/r/trigger.result:
  Update test result
mysql-test/r/type_binary.result:
  Update test result
mysql-test/r/type_bit.result:
  Update test result
mysql-test/r/type_bit_innodb.result:
  Update test result
mysql-test/r/type_blob.result:
  Update test result
mysql-test/r/type_decimal.result:
  Update test result
mysql-test/r/type_enum.result:
  Update test result
mysql-test/r/type_float.result:
  Update test result
mysql-test/r/type_nchar.result:
  Update test result
mysql-test/r/type_newdecimal.result:
  Update test result
mysql-test/r/type_set.result:
  Update test result
mysql-test/r/type_timestamp.result:
  Update test result
mysql-test/r/type_varchar.result:
  Update test result
mysql-test/r/union.result:
  Update test result
mysql-test/r/user_var.result:
  Update test result
mysql-test/r/variables.result:
  Update test result
sql/sql_show.cc:
  Make ouput from SHOW CREATE TABLE use uppercase for "CHARACTER SET", "COLLATE", "DEFAULT", "ON UPDATE" and "AUTO_INCREMENT"
2006-02-22 10:09:59 +01:00