Commit graph

26343 commits

Author SHA1 Message Date
unknown
557d0ca4a7 Information schema fix for WL#2787
mysql-test/r/information_schema.result:
  new fields in I_S
sql/sql_show.cc:
  added niew firlds to view information schema
2005-09-15 11:56:06 +03:00
unknown
b34d5bd247 Merge bk-internal.mysql.com:/home/bk/mysql-5.0
into  mysql.com:/home/dlenev/src/mysql-5.0-bg12704-2
2005-09-15 05:06:54 +04:00
unknown
dceb8fb271 Merge bk-internal.mysql.com:/home/bk/mysql-5.0
into  mysql.com:/home/dlenev/src/mysql-5.0-bg12704-2


sql/mysql_priv.h:
  Auto merged
sql/sp.cc:
  Auto merged
sql/sp_head.cc:
  Auto merged
sql/sql_base.cc:
  Auto merged
sql/sql_lex.h:
  Auto merged
sql/sql_prepare.cc:
  Auto merged
sql/sql_table.cc:
  Auto merged
sql/sql_update.cc:
  Auto merged
2005-09-15 03:57:59 +04:00
unknown
d5303b8ab8 Fix for bug #12704 "Server crashes during trigger execution".
This bug occurs when some trigger for table used by DML statement is created
or changed while statement was waiting in lock_tables(). In this situation
prelocking set which we have calculated becames invalid which can easily lead
to errors and even in some cases to crashes.

With proposed patch we no longer silently reopen tables in lock_tables(),
instead caller of lock_tables() becomes responsible for reopening tables and
recalculation of prelocking set.


mysql-test/t/trigger.test:
  Added tests for bug #12704 "Server crashes during trigger execution".
  Unfortunately these tests rely on the order in which tables are locked
  by statement so they are non-determenistic and therefore should be disabled.
sql/lock.cc:
  mysql_lock_tables():
    Now instead of always reopening altered or dropped tables by itself
    mysql_lock_tables() can notify upper level and rely on caller doing this.
sql/mysql_priv.h:
  Now mysql_lock_tables() can either reopen deleted or altered tables by itself
  or notify caller about such situation through 'need_reopen' argument and rely
  on it in this.
  Also lock_tables() has new 'need_reopen' out parameter through which it
  notifies caller that some tables were altered or dropped so he needs to reopen
  them (and rebuild prelocking set some triggers may change or simply appear).
sql/sp.cc:
  sp_add_used_routine():
    To be able to restore LEX::sroutines_list to its state right after parsing
    we now adjust  LEX::sroutines_list_own_last/sroutines_list_own_elements when
    we add directly used routine.
  sp_remove_not_own_routines():
    Added procedure for restoring LEX::sroutines/sroutines_list to their state
    right after parsing (by throwing out non-directly used routines).
  sp_cache_routines_and_add_tables_for_view()/sp_update_stmt_used_routines():
    We should use LEX::sroutines_list instead of LEX::sroutines as source of
    routines used by view, since LEX::sroutines is not availiable for view
    on second attempt to open it (see comment in open_tables() about it).
sql/sp.h:
  sp_remove_not_own_routines():
    Added procedure for restoring LEX::sroutines/sroutines_list to their state
    right after parsing (by throwing out non-directly used routines).
sql/sp_head.cc:
  Removed assert which is no longer always true.
sql/sql_base.cc:
  reopen_table():
    When we re-open table and do shallow copy of TABLE object we should adjust
    pointers to it in associated Table_triggers_list object. Removed nil
    operation.
  open_tables():
    Now this function is able to rebuild prelocking set for statement if it is
    needed. It also correctly handles FLUSH TABLES which may occur during its
    execution.
  lock_tables():
    Instead of allowing mysql_lock_tables() to silently reopen altered or dropped
    tables let us notify caller and rely on that it will do reopen itself.
    This solves the problem when trigger suddenly appears or changed during
    mysq_lock_tables().
  close_tables_for_reopen():
    Added routine for properly preparing for reopening of tables and recalculation
    of set of prelocked tables.
sql/sql_handler.cc:
  Here we let mysql_lock_tables() to reopen dropped or altered tables by itself.
sql/sql_insert.cc:
  Here we let mysql_lock_tables() to reopen dropped or altered tables by itself.
sql/sql_lex.cc:
  LEX:
    Added 'sroutines_list_own_last' and 'sroutines_list_own_elements' members
    which are used for keeping state in which 'sroutines_list' was right after
    statement parsing (and for restoring of this list to this state).
sql/sql_lex.h:
  LEX:
    Added 'sroutines_list_own_last' and 'sroutines_list_own_elements' members
    which are used for keeping state in which 'sroutines_list' was right after
    statement parsing (and for restoring of this list to this state).
    Added chop_off_not_own_tables() method to simplify throwing away list
    of implicitly used (prelocked) tables.
sql/sql_prepare.cc:
  Now instead of silently reopening altered or dropped tables in
  lock_tables() we notify caller and rely on that the caller will
  reopen tables.
sql/sql_table.cc:
  Here we let mysql_lock_tables() to reopen dropped or altered tables by itself.
sql/sql_trigger.cc:
  Added Table_triggers_list::set_table() method to adjust Table_triggers_list
  to new pointer to TABLE instance.
sql/sql_trigger.h:
  Added Table_triggers_list::set_table() method to adjust Table_triggers_list
  to new pointer to TABLE instance.
sql/sql_update.cc:
  Now instead of silently reopening altered or dropped tables in
  lock_tables() we notify caller and rely on that the caller will
  reopen tables.
2005-09-15 03:56:09 +04:00
unknown
4e17e059f8 Merge eherman@bk-internal.mysql.com:/home/bk/mysql-5.0
into  mysql.com:/home/eric/mysql-5.0-fed-err
2005-09-14 14:46:07 -07:00
unknown
8ac6ab4aa6 Merge eherman@bk-internal.mysql.com:/home/bk/mysql-5.0
into  mysql.com:/home/eric/mysql-5.0-fed-err
2005-09-14 13:52:43 -07:00
unknown
11e0bdd70b Updated test results for view test.
mysql-test/r/view.result:
  Updated test results
2005-09-14 16:27:55 -04:00
unknown
92e4aa67f5 Merge bk-internal.mysql.com:/home/bk/mysql-5.0
into  mysql.com:/home/emurphy/src/bk-clean/mysql-5.0
2005-09-14 16:16:04 -04:00
unknown
78cf7b1960 fixed portability 2005-09-14 23:12:01 +03:00
unknown
949cc285d0 Merge mysql.com:/home/emurphy/src/work/mysql-5.0-bug-12870
into  mysql.com:/home/emurphy/src/bk-clean/mysql-5.0


sql/sql_parse.cc:
  Auto merged
2005-09-14 14:44:48 -04:00
unknown
bdae7b9b79 BUG#12870 (CREATE PROCEDURE followed by ROLLBACK is not replicated)
Fixed by making CREATE/ALTER/DROP PROCEDURE cause implicit commit.


mysql-test/r/rpl_ddl.result:
  Updated results to include testing of implicit commit for
  create/alter/drop procedure
mysql-test/t/rpl_ddl.test:
  BUG#12870 test implicit commit for create/alter/drop procedure.
sql/sql_parse.cc:
  CREATE/ALTER/DROP PROCEDURE/SPFUNCTION now causes implicit commit.
2005-09-14 14:42:39 -04:00
unknown
7dc083d516 Per LenZ, changed calculated buffer size to constant and removed some unused variables.
sql/ha_federated.cc:
  converted calculated buffer size to static interger.
  removed unused variables.
2005-09-14 11:02:33 -07:00
unknown
97bea9092e Merge mysql.com:/home/alexi/mysql-5.0
into  mysql.com:/home/alexi/dev/mysql-5.0-13000


mysql-test/r/view.result:
  Auto merged
mysql-test/t/view.test:
  Auto merged
2005-09-14 20:32:59 +04:00
unknown
b214671e09 Fixed BUG#12963, BUG#13000: wrong VIEW creation with DAYNAME(),
DAYOFWEEK(), and WEEKDAY().


mysql-test/r/func_time.result:
  Fixed new results for testcases containing EXPLAIN EXTENDED SELECT ...
   WEEKDAY ... DAYNAME. The new results are correct and correspond to
   the changes in create_func_weekday() and create_func_dayname().
mysql-test/r/view.result:
  Fixed some testcases results (bugs #12963, #13000).
mysql-test/t/view.test:
  Added testcases for for bugs #12963, #13000.
sql/item_create.cc:
  Fixed bugs #12963, #13000: wrong VIEW creation with DAYNAME(),
   DAYOFWEEK(), and WEEKDAY().
   Modified create_func_dayname(), create_func_dayofweek(), and
   create_func_weekday(). They don´t insert Item_func_to_days
   object now.
sql/item_timefunc.cc:
  Fixed bugs #12963, #13000: wrong VIEW creation with DAYNAME(),
   DAYOFWEEK(), and WEEKDAY().
   Modified Item_func_weekday::val_int(). The argument of weekday should
   not be considered now to be Item_func_to_days object.
sql/item_timefunc.h:
  Fixed bugs #12963, 13000: wrong VIEW creation with DAYNAME(),
   DAYOFWEEK(), and WEEKDAY.
   Modified Item_func_weekday::func_name(). It returns now different
   names depending on the odbc_type attribute value.
2005-09-14 20:25:00 +04:00
unknown
528c3a71f8 Merge tulin@bk-internal.mysql.com:/home/bk/mysql-5.0
into dl145c.mysql.com:/home/ndbdev/tomas/mysql-5.0
2005-09-14 17:27:01 +02:00
unknown
21b8177ebc Merge abelkin@bk-internal.mysql.com:/home/bk/mysql-5.0
into  sanja.is.com.ua:/home/bell/mysql/bk/work-owner2-5.0
2005-09-14 17:36:09 +03:00
unknown
ead2b33476 Merge tulin@bk-internal.mysql.com:/home/bk/mysql-5.0
into dl145c.mysql.com:/home/ndbdev/tomas/mysql-5.0
2005-09-14 16:32:44 +02:00
unknown
06fc0e8b8a Merge mysql.com:/home/stewart/Documents/MySQL/5.0/main
into  mysql.com:/home/stewart/Documents/MySQL/5.0/bug13136
2005-09-15 00:31:13 +10:00
unknown
e33c22a1a3 Merge abelkin@bk-internal.mysql.com:/home/bk/mysql-5.0
into  sanja.is.com.ua:/home/bell/mysql/bk/work-owner2-5.0
2005-09-14 17:28:28 +03:00
unknown
eae520f383 postmerge fix 2005-09-14 17:27:33 +03:00
unknown
c6ff73b91f BUG#13136 NdbTCP.cpp compile failure on OSX 10.2
use select if poll is unavailable.


ndb/src/common/portlib/NdbTCP.cpp:
  Implement Ndb_check_socket_hup for systems without poll(2)
ndb/src/common/portlib/win32/NdbTCP.c:
  fix typo (found while fixing this bug)
2005-09-15 00:21:25 +10:00
unknown
70f1645617 Merge tulin@bk-internal.mysql.com:/home/bk/mysql-5.0
into dl145c.mysql.com:/home/ndbdev/tomas/mysql-5.0
2005-09-14 15:47:15 +02:00
unknown
840ab3dd1e enabled mysqldump hex-blob option for bit fields 2005-09-14 15:46:31 +02:00
unknown
d51c50b875 Merge jbruehe@bk-internal.mysql.com:/home/bk/mysql-5.0
into mysql.com:/M50/mysql-5.0
2005-09-14 15:28:23 +02:00
unknown
b0aa4c95b6 Merge jbruehe@bk-internal.mysql.com:/home/bk/mysql-5.0
into mysql.com:/M50/mysql-5.0
2005-09-14 15:24:52 +02:00
unknown
423bbd6594 Fix for Metrowerks compiler. 2005-09-14 16:10:56 +03:00
unknown
6a683cb765 Merge mysql.com:/M41/upward-4.1 into mysql.com:/M50/merge-5.0
mysql-test/lib/mtr_process.pl:
  Auto merged
mysql-test/lib/mtr_report.pl:
  Auto merged
2005-09-14 14:34:45 +02:00
unknown
abd4974fd5 Improve error / process handling in the Perl script to run the test suite (patch supplied by Kent).
mysql-test/lib/mtr_process.pl:
  Handle errors in child processes separate from the parent process (patch supplied by Kent).
mysql-test/lib/mtr_report.pl:
  New function to handle errors in child processes separate from the parent process (patch supplied by Kent).
  Expected to avoid HUP signals.
2005-09-14 13:55:53 +02:00
unknown
afbfd12ed2 indentation correction 2005-09-14 13:44:44 +02:00
unknown
258c9e9dc7 Merge tulin@bk-internal.mysql.com:/home/bk/mysql-5.0
into dl145c.mysql.com:/home/ndbdev/tomas/mysql-5.0
2005-09-14 13:27:57 +02:00
unknown
e2b72d815f (corrected typo in prev patch) Bug #13152 bit fields and fileds that follow become corrupted when dumped from NDB 2005-09-14 13:24:41 +02:00
unknown
a5903ed9f3 Minor output format change of the Perl test suite script (align with the shell script).
mysql-test/lib/mtr_report.pl:
  Make the Perl test script output identical to that of the (old) shell script,
  so that reported differences compare as equal strings (for automatic analysis).
2005-09-14 13:12:30 +02:00
unknown
0b318fd64f Merge pchardin@bk-internal.mysql.com:/home/bk/mysql-5.0
into  mysql.com:/home/cps/mysql/trees/mysql-5.0-virgin


mysql-test/r/sp.result:
  Auto merged
mysql-test/t/sp.test:
  Auto merged
2005-09-14 14:54:48 +04:00
unknown
33b1d6f63d Merge sanja.is.com.ua:/home/bell/mysql/bk/mysql-5.0
into  sanja.is.com.ua:/home/bell/mysql/bk/work-owner2-5.0


sql/sql_yacc.yy:
  Auto merged
sql/share/errmsg.txt:
  merge
2005-09-14 13:37:40 +03:00
unknown
e7d7e0e92f Bug #13152 bit fields and fileds that follow become corrupted when dumped from NDB tables 2005-09-14 11:41:36 +02:00
unknown
2fcdbb8d7e Merge sanja.is.com.ua:/home/bell/mysql/bk/mysql-5.0
into  sanja.is.com.ua:/home/bell/mysql/bk/work-owner2-5.0


sql/mysql_priv.h:
  Auto merged
sql/sql_acl.cc:
  Auto merged
sql/sql_parse.cc:
  Auto merged
sql/sql_show.cc:
  Auto merged
sql/sql_view.cc:
  Auto merged
2005-09-14 12:26:09 +03:00
unknown
98b6fd8797 postmerge fix 2005-09-14 12:24:14 +03:00
unknown
89e0804df0 Merge mysql.com:/usr/local/bk/mysql-5.0
into  mysql.com:/usr/home/pem/mysql-5.0
2005-09-14 10:54:52 +02:00
unknown
8c86f8e4bf Post-review fix for BUG#12712: SET AUTOCOMMIT should fail within SP/functions/triggers
mysql-test/r/sp.result:
  Added missing drop table.
mysql-test/t/sp.test:
  Added missing drop table.
sql/sp_head.h:
  Post-review fix for autocommit check in SPs and triggers.
sql/sql_yacc.yy:
  Post-review fix for autocommit check in SPs and triggers.
2005-09-14 10:54:02 +02:00
unknown
a55963f0ad Merge pchardin@bk-internal.mysql.com:/home/bk/mysql-5.0
into  mysql.com:/home/cps/mysql/trees/mysql-5.0-virgin
2005-09-14 12:42:23 +04:00
unknown
12dfd287c4 Merge sgluhov@bk-internal.mysql.com:/home/bk/mysql-5.0
into mysql.com:/home/gluh/MySQL/Bugs/5.0.cml
2005-09-14 13:20:21 +05:00
unknown
d0a78e6fa6 Merge sanja.is.com.ua:/home/bell/mysql/bk/mysql-5.0
into  sanja.is.com.ua:/home/bell/mysql/bk/work-owner2-5.0


sql/sql_acl.cc:
  Auto merged
sql/sql_parse.cc:
  Auto merged
sql/sql_show.cc:
  Auto merged
sql/sql_yacc.yy:
  Auto merged
sql/table.h:
  Auto merged
mysql-test/r/func_in.result:
  merge
mysql-test/r/lowercase_view.result:
  merge
mysql-test/r/mysqldump.result:
  merge
mysql-test/r/sql_mode.result:
  merge
mysql-test/r/temp_table.result:
  merge
mysql-test/r/view.result:
  merge
mysql-test/t/view.test:
  merge
2005-09-14 11:07:04 +03:00
unknown
f7aeb6f9fd part 1 (ver 2, postreview fix) of WL#2787
view definer information syntax/storage/replication
fixed SOURCE field of .frm


mysql-test/r/func_in.result:
  definer information added to CREATE VIEW
mysql-test/r/lowercase_view.result:
  definer information added to CREATE VIEW
mysql-test/r/mysqldump.result:
  definer information added to CREATE VIEW
mysql-test/r/rpl_view.result:
  check log of queries
mysql-test/r/skip_grants.result:
  --skip-grants do not allow use user information
mysql-test/r/sql_mode.result:
  definer information added to CREATE VIEW
mysql-test/r/temp_table.result:
  definer information added to CREATE VIEW
mysql-test/r/view.result:
  definer information added to CREATE VIEW
  test of storing/restoring definer information
mysql-test/r/view_grant.result:
  test of grant check of definer information
  definer information added to CREATE VIEW
mysql-test/t/rpl_view.test:
  check log of queries
mysql-test/t/skip_grants.test:
  --skip-grants do not allow use user information
mysql-test/t/view.test:
  test of storing/restoring definer information
mysql-test/t/view_grant.test:
  test of grant check of definer information
sql/mysql_priv.h:
  CREATE/ALTER VIEW print support
  set current user as definer procedure
sql/share/errmsg.txt:
  new errors/warnings
sql/sql_acl.cc:
  make find_acl_user public to allow to check user
sql/sql_acl.h:
  make find_acl_user public to allow to check user
sql/sql_lex.h:
  storing definer information
sql/sql_parse.cc:
  send CREATE/ALTER VIEW for replication with full list of options
  set current user as definer procedure
sql/sql_show.cc:
  new CREATE VIEW options printed
sql/sql_view.cc:
  check of definer clause
  changes in .frm file
  definer information storage support
  now we store only original SELECT in SOURCE field of .frm
sql/sql_yacc.yy:
  definer information sintax support
  getting SOURCE field information for .frm
sql/table.h:
  definer information storage
2005-09-14 10:53:09 +03:00
unknown
f42792275f Merge sgluhov@bk-internal.mysql.com:/home/bk/mysql-5.0
into mysql.com:/home/gluh/MySQL/Bugs/5.0.cml


sql/sql_show.cc:
  Auto merged
2005-09-14 12:46:03 +05:00
unknown
38c43ecdd3 Merge mysql.com:/usr/local/bk/mysql-5.0
into  mysql.com:/usr/home/pem/mysql-5.0


sql/sql_yacc.yy:
  Auto merged
2005-09-14 09:43:02 +02:00
unknown
a8d4bfd168 Merge bk-internal.mysql.com:/home/bk/mysql-5.0
into  neptunus.(none):/home/msvensson/mysql/mysql-5.0
2005-09-14 09:40:20 +02:00
unknown
392dd4d0f3 Merge bk-internal.mysql.com:/home/bk/mysql-5.0
into  neptunus.(none):/home/msvensson/mysql/bug10713_new/my50-bug10713_new
2005-09-14 09:35:56 +02:00
unknown
2828c5f594 Merge sgluhov@bk-internal.mysql.com:/home/bk/mysql-5.0
into mysql.com:/home/gluh/MySQL/Bugs/5.0.cml


sql/sql_acl.cc:
  Auto merged
sql/sql_parse.cc:
  Auto merged
sql/sql_prepare.cc:
  Auto merged
sql/sql_show.cc:
  Auto merged
2005-09-14 12:11:19 +05:00
unknown
77a7ba13db formatting typo fix 2005-09-14 12:10:07 +05:00
unknown
a8c1ea9731 Fix QNX warning
include/my_global.h:
  Avoid warnings on QNX, only define HAVE_RINT if not found by configure
2005-09-14 08:33:00 +02:00