Commit graph

22433 commits

Author SHA1 Message Date
unknown
af12ff6568 Approximative fixes for BUG#2610,2611,9100 i.e. WL#2146 binlogging/replication of routines (stored procs and functions).
Approximative, because it's using our binlogging way (what we call "query"-level) and this is not as good as record-level binlog (5.1) would be. It imposes several
  limitations to routines, and has caveats (which I'll document, and for which the server will try to issue errors but that is not always possible).
  Reason I don't propagate caller info to the binlog as planned is that on master and slave
  users may be different; even with that some caveats would remain.


mysql-test/mysql-test-run.sh:
  In the testsuite we know what we do, we are not creating nasty routines, and breaking binlog is ok except in rpl_sp.
mysql-test/r/blackhole.result:
  Updating results now that 4.1 has been merged
mysql-test/valgrind.supp:
      Some suppressions for Valgrind (useful on my machine Suse 9.1);
      this is just adding to the already existing suppressions of pthread and dl.
sql/item_func.cc:
      Don't binlog the substatements when executing a function. If the function
      is declared to modify data and does not complete, warning "broken binlog".
      Note that SELECT myfunc() will not be binlogged even if myfunc() updates data (will be documented);
      but INSERT INTO t VALUES(myfunc()) will be binlogged (what decides is if the caller
      gets binlogged; the function changes nothing to binlogging).
sql/log_event.cc:
      Just making functions which can be re-used when we binlog more strings
      in status_vars in Query_log_event (e.g. one day "user", "host").
sql/log_event.h:
  comment
sql/mysql_priv.h:
      --log-bin-trust-routine-creators
sql/mysqld.cc:
      --log-bin-trust-routine-creators
sql/set_var.cc:
      --log-bin-trust-routine-creators
sql/share/errmsg.txt:
  error messages to warn about problems with routines and binlog
sql/slave.cc:
      If in a routine, replication table inclusion/exclusion rules always answer "replicate!" (see comment in code).
sql/sp.cc:
      If binlog is on: errors if one wants to create a non-deterministic update routine
      (repeatability problem - note that the test is not perfect for functions) or does not have SUPER (because routines can easily
      be made to destroy slave's data with just CREATE ROUTINE and EXECUTE priv on master).
      --log-bin-trust-routine-creators removes these errors.
      Binlogging of CREATE PROCEDURE|FUNCTION.
sql/sql_acl.cc:
      No thd==0 in tables_ok().
sql/sql_parse.cc:
      Binlogging of CALL (and not of the substatements of the SP).
      If SP returns error, we don't binlog it (see comment); we push warning in this case.
      Binlogging of ALTER|DROP PROCEDURE|FUNCTION with safety messages.
2005-05-05 14:20:53 +02:00
unknown
2275c0486c Merge bk-internal.mysql.com:/home/bk/mysql-5.0
into mysql.com:/opt/local/work/mysql-5.0-root
2005-05-04 17:21:49 +04:00
unknown
137c78d808 Merge lgrimmer@bk-internal.mysql.com:/home/bk/mysql-5.0
into mysql.com:/space/my/mysql-5.0
2005-05-04 15:06:53 +02:00
unknown
e6a66a6afd Merge mysql.com:/space/my/mysql-4.1-bug9444
into mysql.com:/space/my/mysql-5.0


support-files/mysql.server.sh:
  Auto merged
2005-05-04 15:00:18 +02:00
unknown
40042ccc6b - adjusted the start and stop priority level in the mysql.server init script for chkconfig on
Red Hat Linux (BUG#9444) - we now match the levels used by the MySQL as shipped with Red Hat Linux
  (e.g. RHEL3/RHEL4)


support-files/mysql.server.sh:
  - adjusted the start and stop priority level for chkconfig on Red Hat Linux (BUG#9444) - we now match
    the levels used by the MySQL as shipped with Red Hat Linux (RHEL3/RHEL4)
2005-05-04 14:58:43 +02:00
unknown
3c223a34cf Merge bk-internal.mysql.com:/home/bk/mysql-5.0
into mysql.com:/opt/local/work/mysql-5.0-root


sql/item.cc:
  Auto merged
sql/item.h:
  Auto merged
2005-05-04 16:54:36 +04:00
unknown
a82865375e Post-merge fixes for Bug#9096 "select doesn't return all matched
records if prepared statements is used" (see comments to 
the changed files).


mysql-test/r/ps.result:
  Post-merge fix for Bug#9096: test results fixed.
mysql-test/r/type_datetime.result:
  Post-merge fix for Bug#9096: now we do better constants comparison,
  so the optimizer is able to guess from the index that we don't
  need to evaluate WHERE clause.
sql/item.cc:
  Post-merge fixes for Bug#9096: implement by-value comparison for
  new 5.0 DECIMAL type.
  Item_real is renamed to Item_float in 5.0
  Item_varbinary is renamed to Item_hex_string in 5.0
sql/item.h:
  Post-merge fixes for Bug#9096: declaration for Item_decimal::eq
2005-05-04 16:53:10 +04:00
unknown
39f8776f89 Merge joreland@bk-internal.mysql.com:/home/bk/mysql-5.0
into mysql.com:/home/jonas/src/mysql-5.0
2005-05-04 13:30:37 +02:00
unknown
78fb71b0a5 bug#10330 - linking with ndb fails
changes to handling of new/delete cxa_pure_virtual has changed in mysys
  remove "ndb"'s own impl. as they are no longer needed as we link mysys at all places


ndb/src/common/portlib/gcc.cpp:
  remove ndb __cxa_pure_virtual
ndb/src/common/util/new.cpp:
  remove "ndb" new/delete
2005-05-04 13:29:15 +02:00
unknown
c0f3557625 Merge lgrimmer@bk-internal.mysql.com:/home/bk/mysql-5.0
into mysql.com:/space/my/mysql-5.0
2005-05-04 11:26:15 +02:00
unknown
abd3b28456 Merge mysql.com:/space/my/mysql-4.1-build
into mysql.com:/space/my/mysql-5.0-build
2005-05-04 10:55:12 +02:00
unknown
8a5a1841ef - added missing el_term.h to the source distribution (BUG#10352) 2005-05-04 10:49:42 +02:00
unknown
7b4374f6f7 Merge book.sanja.is.com.ua:/Users/bell/mysql/bk/mysql-5.0
into book.sanja.is.com.ua:/Users/bell/mysql/bk/work-test-5.0


BitKeeper/etc/logging_ok:
  Logging to logging@openlogging.org accepted
2005-05-03 18:47:53 +03:00
unknown
3aa89efcdd Manual merge of Bug#9096 2005-05-03 19:32:29 +04:00
unknown
b883aebae0 Merge mysql.com:/opt/local/work/mysql-4.1-root
into mysql.com:/opt/local/work/mysql-4.1-9096-fresh


sql/item.h:
  Auto merged
sql/item_func.cc:
  Auto merged
2005-05-03 12:49:22 +04:00
unknown
9fcda7fcc5 A fix and test case for Bug#9096 "select doesn't return all matched
records if prepared statements is used".
This fix changes equality evaluation method of basic constants from
by-name to by-value, thus effectively enabling use of parameter markers
in some optimizations (constants propagation, evaluation of possible
keys for query).


mysql-test/r/ps.result:
  Test results for the test case for Bug#9096
mysql-test/t/ps.test:
  A short test case for Bug#9096 "select doesn't return all matched records if
   prepared statements is used". The is enough to reproduce the
  glitch in update_ref_and_keys causing the bug to occur.
sql/item.cc:
  Implement by-value equality evaluation of basic constants.
  This is needed to work with Item_param values. Until now
  Item_param was compared with other items by its name, which is always "?".
  The bug at hand showed up when an integer
  constant was created from one parameter marker (with value 200887 and
   name "?") and then compared by-name with another parameter marker
  (with value 860 and name "?"). True returned by this comparison resulted
  in a wrong table access method used to evaluate the query.
  Implement Item_param methods needed to emulate "basic constant" mode at 
  full.
sql/item.h:
  Change declaration of basic_const_item(): now it also widens its 
  argument from const Item * to Item * if the argument is a basic constant.
  Declare eq() for all basic constatns, as long as now they 
  are compared by value, not by name. Each constant needs its own
  comparison method.
  Declarations of Item_param methods needed to fully emulate 
  a basic constant when parameter value is set.
sql/item_func.cc:
  Fix wrong casts.
2005-05-03 12:47:27 +04:00
unknown
9724795fd6 Merge spetrunia@bk-internal.mysql.com:/home/bk/mysql-5.0
into mysql.com:/home/psergey/mysql-5.0-test-valgrind
2005-05-03 07:42:36 +00:00
unknown
21d3d43cf2 Merge spetrunia@bk-internal.mysql.com:/home/bk/mysql-5.0
into mysql.com:/home/psergey/mysql-5.0-test-valgrind


sql/sql_select.cc:
  Auto merged
2005-05-03 10:23:10 +04:00
unknown
40d0c3e6db ha_innodb.cc:
Return a value from innobase_repl_report_sent_binlog()


sql/ha_innodb.cc:
  Return a value from innobase_repl_report_sent_binlog()
2005-05-03 08:40:35 +03:00
unknown
d00d1dd1fa Update test results
mysql-test/r/query_cache.result:
  Update results
mysql-test/r/user_limits.result:
  Update results
2005-05-02 11:45:06 -07:00
unknown
d4b39a511c Resolve merge of fix for #8166.
mysql-test/r/system_mysql_db.result:
  Update results
scripts/mysql_create_system_tables.sh:
  Resolve merge of bug fix
scripts/mysql_fix_privilege_tables.sql:
  Resolve merge of bug fix
2005-05-02 10:25:47 -07:00
unknown
2d998575d3 Merge mysql.com:/home/jimw/my/mysql-5.0-7293
into mysql.com:/home/jimw/my/mysql-5.0-clean
2005-05-02 10:20:54 -07:00
unknown
bd24e892dc Merge mysql.com:/home/jimw/my/mysql-5.0-5354
into mysql.com:/home/jimw/my/mysql-5.0-clean


extra/my_print_defaults.c:
  Auto merged
include/my_sys.h:
  Auto merged
mysys/default.c:
  Auto merged
2005-05-02 10:20:22 -07:00
unknown
41e7a9709d Clean up merge from 4.1
configure.in:
  Auto merged
extra/my_print_defaults.c:
  Auto merged
mysql-test/mysql-test-run.sh:
  Auto merged
mysql-test/r/lowercase_table.result:
  Auto merged
mysql-test/r/query_cache.result:
  Mege results
mysql-test/t/lowercase_table.test:
  Merge tests
mysql-test/t/query_cache.test:
  Merge tests
mysys/default.c:
  Merge from 4.1
sql/sql_cache.cc:
  Merge
sql/sql_parse.cc:
  Merge from 4.1
sql/sql_table.cc:
  Merge
tests/mysql_client_test.c:
  Merge
2005-05-02 10:19:37 -07:00
unknown
d41aa2976e Merge bk-internal:/home/bk/mysql-5.0
into serg.mylan:/usr/home/serg/Abk/mysql-5.0


sql/ha_blackhole.cc:
  Auto merged
2005-05-02 17:17:43 +02:00
unknown
9f5a4955d0 Merge mysql.com:/home/jimw/my/mysql-4.1-9947
into mysql.com:/home/jimw/my/mysql-4.1-clean
2005-05-02 08:12:27 -07:00
unknown
5df9135be7 Merge mysql.com:/home/jimw/my/mysql-4.1-9761
into mysql.com:/home/jimw/my/mysql-4.1-clean
2005-05-02 08:12:03 -07:00
unknown
875ed1e455 Merge mysql.com:/home/jimw/my/mysql-4.1-9136
into mysql.com:/home/jimw/my/mysql-4.1-clean


mysys/default.c:
  Auto merged
2005-05-02 08:11:32 -07:00
unknown
465ba81afa Merge bk-internal:/home/bk/mysql-4.1
into mysql.com:/home/jimw/my/mysql-4.1-clean


configure.in:
  Auto merged
2005-05-02 08:05:58 -07:00
unknown
a406c034b9 Fix typo in ha_backhole.cc
sql/ha_blackhole.cc:
  Fix typo
2005-05-02 11:25:01 +02:00
unknown
9b512475fc Merge bk-internal:/home/bk/mysql-5.0
into serg.mylan:/usr/home/serg/Abk/mysql-5.0


Makefile.am:
  Auto merged
client/mysqladmin.cc:
  Auto merged
configure.in:
  Auto merged
include/my_global.h:
  Auto merged
sql/item_func.cc:
  Auto merged
sql/mysqld.cc:
  Auto merged
sql/sql_select.cc:
  Auto merged
2005-05-01 23:10:55 +02:00
unknown
21eed96b02 Merge mysql.com:/home/psergey/mysql-4.1-bug9228
into mysql.com:/home/psergey/mysql-5.0-bug10274-merge


sql/protocol.cc:
  Auto merged
2005-05-01 19:07:01 +04:00
unknown
7ecca388af Merge spetrunia@bk-internal.mysql.com:/home/bk/mysql-4.1
into mysql.com:/home/psergey/mysql-4.1-bug9228
2005-05-01 19:03:49 +04:00
unknown
d3d5660952 yassl changeset 2:
remove FIX_GCC_LINKING_PROBLEM and -DDEFINE_CXA_PURE_VIRTUAL
  replace echo in configure.in with AC_MSG_WARN/AC_MSG_ERROR
  don't set -DUSE_MYSYS_NEW for gcc 2.95
  set $USE_MYSYS_NEW even if CXX is g++
  yassl bugfixes
  instantiate all yassl templates explicitly


client/Makefile.am:
  mysqlbinlog as a c++ program may need my_new.cc (if CXX=gcc)
  no FIX_GCC_LINKING_PROBLEM anymore - it's in my_new.cc
client/mysqladmin.cc:
  no FIX_GCC_LINKING_PROBLEM anymore - it's in my_new.cc
client/mysqlbinlog.cc:
  no FIX_GCC_LINKING_PROBLEM anymore - it's in my_new.cc
configure.in:
  echo should be AC_MSG_WARN or AC_MSG_ERROR
  don't set -DUSE_MYSYS_NEW for gcc 2.95 (to restore old behaviour)
  set $USE_MYSYS_NEW even if CXX is g++ (for yassl, as it can be linked with C programs)
  remove -DDEFINE_CXA_PURE_VIRTUAL - -DUSE_MYSYS_NEW is enough
extra/yassl/mySTL/list.hpp:
  bugfixes
extra/yassl/src/Makefile.am:
  no need to mess with CXXFLAGS anymore. Instantiate all templates explicitly
extra/yassl/src/crypto_wrapper.cpp:
  instantiate templates explicitly
extra/yassl/src/yassl_imp.cpp:
  instantiate templates explicitly
extra/yassl/src/yassl_int.cpp:
  instantiate templates explicitly
extra/yassl/taocrypt/include/runtime.hpp:
  use -DUSE_MYSYS_NEW not -DDEFINE_CXA_PURE_VIRTUAL
  assert in __cxa_pure_virtual
  remove dummy (and thus dangerous) __cxa_guard_acquire/__cxa_guard_release
extra/yassl/taocrypt/src/Makefile.am:
  no need to mess with CXXFLAGS anymore. Instantiate all templates explicitly
extra/yassl/taocrypt/src/integer.cpp:
  instantiate templates explicitly
extra/yassl/taocrypt/src/rsa.cpp:
  instantiate templates explicitly
include/my_global.h:
  no FIX_GCC_LINKING_PROBLEM anymore - it's in my_new.cc
mysys/my_new.cc:
  no FIX_GCC_LINKING_PROBLEM anymore - it's in my_new.cc
server-tools/instance-manager/command.cc:
  no FIX_GCC_LINKING_PROBLEM anymore - it's in my_new.cc
sql/ha_blackhole.cc:
  typo fixed
sql/ha_innodb.cc:
  warning fixed
sql/item_func.cc:
  use LL()
sql/mysqld.cc:
  no FIX_GCC_LINKING_PROBLEM anymore - it's in my_new.cc
2005-04-30 19:48:45 +02:00
unknown
371b26e11c Merge sanja.is.com.ua:/home/bell/mysql/bk/mysql-5.0
into sanja.is.com.ua:/home/bell/mysql/bk/work-test-5.0


sql/item.h:
  Auto merged
2005-04-30 19:32:45 +03:00
unknown
d45f95f04a postreview changes
sql/item.cc:
  changed parameters order
sql/item.h:
  changed parameters order
sql/sql_base.cc:
  fixed comment
  changed parameters order
2005-04-30 19:27:22 +03:00
unknown
d1d474c812 After merge fixes
Makefile.am:
  Added target test-force
mysql-test/r/cast.result:
  Updated results after merge
2005-04-30 18:40:08 +03:00
unknown
b3b97e0589 Merge sanja.is.com.ua:/home/bell/mysql/bk/mysql-5.0
into sanja.is.com.ua:/home/bell/mysql/bk/work-test-5.0
2005-04-30 17:50:57 +03:00
unknown
a6acc4462c Merge with 4.1
BitKeeper/etc/logging_ok:
  auto-union
configure.in:
  Auto merged
include/config-win.h:
  Auto merged
include/my_global.h:
  Auto merged
mysql-test/r/drop.result:
  Auto merged
mysys/default.c:
  Auto merged
mysys/mf_keycache.c:
  Auto merged
sql/field.h:
  Auto merged
sql/item.h:
  Auto merged
sql/item_func.cc:
  Auto merged
sql/item_func.h:
  Auto merged
sql/mysqld.cc:
  Auto merged
BitKeeper/deleted/.del-errmsg.txt~f96b7055cac394e:
  Auto merged
mysql-test/r/cast.result:
  Merge
mysql-test/t/cast.test:
  Merge
sql/sql_insert.cc:
  Merge
sql/sql_select.cc:
  Merge
2005-04-30 09:46:08 +03:00
unknown
e64d221e69 Merge bk-internal.mysql.com:/home/bk/mysql-5.0
into mysql.com:/home/my/mysql-5.0


tests/mysql_client_test.c:
  Auto merged
2005-04-30 09:37:07 +03:00
unknown
963e94ce49 A fix and a test case for Bug#9520 "SELECT DISTINCT crashes server
with cursor". The patch refactors do_select/sub_select
functions, which implement the nested loop algorithm, and reuses them to
fetch rows for cursors as well.
Pushing with view.test failing (--ps-protocol).


sql/sql_prepare.cc:
   Cursor::fetch() now returns void
sql/sql_select.cc:
  A fix for Bug#9520 "SELECT DISTINCT crashes server with cursor":
  * rename sub_select returns codes to be able to track down what's going
    on in which case.
  * move record processing and outer join record processing to a separate
    function, out of sub_select read-record loop.
  * use generalized sub_select() nested loop function for
  cursors instead of own loop implementation used in Cursor::fetch() before
sql/sql_select.h:
  Replace all return values of sub_select family with enum.
  Add JOIN::resume_nested_loop flag to indicate we are restarting the nested loop
  for execution of next chunk of cursor's rows.
tests/mysql_client_test.c:
  A test case for Bug#9520 "SELECT DISTINCT crashes server with cursor"
2005-04-30 09:54:35 +04:00
unknown
66bea0de15 Merge bk-internal.mysql.com:/home/bk/mysql-5.0
into mysql.com:/home/my/mysql-5.0


sql/handler.cc:
  Auto merged
sql/item_func.cc:
  Auto merged
sql/item_func.h:
  Auto merged
2005-04-30 03:46:38 +03:00
unknown
3b6043870d Merge bk-internal.mysql.com:/home/bk/mysql-4.1
into mysql.com:/home/my/mysql-4.1


sql/sql_select.cc:
  Auto merged
2005-04-30 03:45:12 +03:00
unknown
ac82a2d5eb Setting a variable to CAST(NULL as X) set the result type of the variable to X. (Bug #6598)
mysql-test/r/bigint.result:
  Test to show show that the parser threats big longlong values as unsigned
mysql-test/r/user_var.result:
  Test of CAST(NULL as SIGNED/UNSIGNED)
mysql-test/t/bigint.test:
  Test to show show that the parser threats big longlong values as unsigned
mysql-test/t/user_var.test:
  Test of CAST(NULL as SIGNED/UNSIGNED)
sql/item_func.cc:
  Setting a variable to CAST(NULL as X) set the result type of the variable to X. (Bug #6598)
  Setting a variable to NULL doesn't change the old result type.
sql/item_func.h:
  Detect setting a variable to NULL
sql/unireg.cc:
  Safety fix
2005-04-30 03:14:42 +03:00
unknown
79f5ad3d78 Merge sanja.is.com.ua:/home/bell/mysql/bk/mysql-5.0
into sanja.is.com.ua:/home/bell/mysql/bk/work-test-5.0


sql/item.cc:
  Auto merged
sql/sql_base.cc:
  Auto merged
2005-04-30 01:43:35 +03:00
unknown
9319613191 Fix for BUG#10274: In Protocol_simple::store_long don't make any assumptions about
relative sizes of int/long/longlong.
2005-04-30 01:05:15 +04:00
unknown
e9cc39c43f Merge mysql.com:/home/jimw/my/mysql-5.0-build
into mysql.com:/home/jimw/my/mysql-5.0-clean
2005-04-29 11:47:30 -07:00
unknown
f8e45de365 Merge epotemkin@bk-internal.mysql.com:/home/bk/mysql-4.1
into moonbone.local:/usr/src/mysql-4.1
2005-04-29 22:20:16 +04:00
unknown
927d747a21 Merge bk-internal:/home/bk/mysql-5.0
into serg.mylan:/usr/home/serg/Abk/mysql-5.0


configure.in:
  Auto merged
2005-04-29 19:31:56 +02:00
unknown
27fa1254dc Fix bug #9703 "Error 1032 with GROUP BY query and large tables"
Reset old error if tmp table was successfully created.

Test data is large and can be found in bug report along with test query.


sql/sql_select.cc:
  Fix bug #9703
BitKeeper/etc/logging_ok:
  Logging to logging@openlogging.org accepted
2005-04-29 21:19:39 +04:00