Commit graph

123 commits

Author SHA1 Message Date
unknown
380690316f Merge mysql.com:/home/mysql_src/mysql-5.0-van
into  mysql.com:/home/mysql_src/mysql-5.1-merge-of-5.0
(2nd try; Pekka kindly accepted to fix storage/ndb/src/kernel/blocks/dbtup/DbtupRoutines.cpp
and storage/ndb/src/kernel/vm/SimulatedBlock.cpp after I push).


configure.in:
  Auto merged
mysql-test/r/ndb_charset.result:
  Auto merged
mysql-test/t/view.test:
  Auto merged
mysys/base64.c:
  Auto merged
sql/ha_archive.cc:
  Auto merged
sql/ha_innodb.cc:
  Auto merged
sql/ha_innodb.h:
  Auto merged
sql/lock.cc:
  Auto merged
sql/mysql_priv.h:
  Auto merged
sql/mysqld.cc:
  Auto merged
sql/set_var.cc:
  Auto merged
sql/sp_head.cc:
  Auto merged
sql/sql_base.cc:
  Auto merged
sql/sql_class.cc:
  Auto merged
sql/sql_handler.cc:
  Auto merged
sql/sql_parse.cc:
  Auto merged
sql/sql_prepare.cc:
  Auto merged
sql/sql_select.cc:
  Auto merged
sql/sql_show.cc:
  Auto merged
sql/sql_table.cc:
  Auto merged
sql/sql_yacc.yy:
  Auto merged
storage/myisam/ft_parser.c:
  Auto merged
storage/ndb/include/kernel/AttributeDescriptor.hpp:
  Auto merged
storage/ndb/src/kernel/vm/SimulatedBlock.hpp:
  Auto merged
storage/ndb/tools/ndb_size.pl:
  Auto merged
storage/ndb/tools/ndb_size.tmpl:
  Auto merged
mysql-test/t/disabled.def:
  merge
storage/ndb/src/kernel/blocks/dbtup/DbtupRoutines.cpp:
  used "ul", Pekka said he'll fix
storage/ndb/src/kernel/vm/SimulatedBlock.cpp:
  used "ul", Pekka said he'll fix
2005-11-19 10:43:28 +01:00
unknown
6506fb3219 Merge mysql.com:/home/mydev/mysql-4.1-4100
into  mysql.com:/home/mydev/mysql-5.0-5000


mysql-test/r/handler.result:
  Auto merged
mysql-test/r/myisam.result:
  Auto merged
mysql-test/t/handler.test:
  Auto merged
mysql-test/t/myisam.test:
  Auto merged
sql/sql_class.cc:
  Auto merged
sql/sql_select.cc:
  Auto merged
sql/mysql_priv.h:
  Bug#14397 - OPTIMIZE TABLE with an open HANDLER causes a crash
  Manual merge.
sql/sql_base.cc:
  Bug#14397 - OPTIMIZE TABLE with an open HANDLER causes a crash
  Manual merge.
sql/sql_handler.cc:
  Bug#14397 - OPTIMIZE TABLE with an open HANDLER causes a crash
  Manual merge.
sql/sql_table.cc:
  Bug#14397 - OPTIMIZE TABLE with an open HANDLER causes a crash
  Manual merge.
2005-11-16 10:23:42 +01:00
unknown
013b3d8ab3 Bug#14397 - OPTIMIZE TABLE with an open HANDLER causes a crash
Version for 5.0.
It fixes three problems:
1. The cause of the bug was that we did not check the table version for
 the HANDLER ... READ commands. We did not notice when a table was
 replaced by a new one. This can happen during ALTER TABLE, REPAIR
 TABLE, and OPTIMIZE TABLE (there might be more cases). I call the fix
 for this problem "the primary bug fix".
2. mysql_ha_flush() was not always called with a locked LOCK_open.
 Though the function comment clearly said it must.
 I changed the code so that the locking is done when required. I call
 the fix for this problem "the secondary fix".
3. In 5.0 (not in 4.1 or 4.0) DROP TABLE had a possible deadlock flaw in
 concur with FLUSH TABLES WITH READ LOCK. I call the fix for this
 problem "the 5.0 addendum fix".


include/my_pthread.h:
  Bug#14397 - OPTIMIZE TABLE with an open HANDLER causes a crash
  Added a new macro for the 5.0 addendum fix.
mysql-test/r/handler.result:
  Bug#14397 - OPTIMIZE TABLE with an open HANDLER causes a crash
  The test result.
mysql-test/t/handler.test:
  Bug#14397 - OPTIMIZE TABLE with an open HANDLER causes a crash
  The test case.
sql/lock.cc:
  Bug#14397 - OPTIMIZE TABLE with an open HANDLER causes a crash
  Changed a comment which did confuse me and which is not fully
  correct anymore after the 5.0 addendum fix.
  Added an assertion which would fire without the 5.0 addendum fix.
sql/mysql_priv.h:
  Bug#14397 - OPTIMIZE TABLE with an open HANDLER causes a crash
  Changed a definition for the secondary fix.
sql/sql_base.cc:
  Bug#14397 - OPTIMIZE TABLE with an open HANDLER causes a crash
  Changed function calls for the secondary fix.
sql/sql_class.cc:
  Bug#14397 - OPTIMIZE TABLE with an open HANDLER causes a crash
  Changed a function call for the secondary fix.
sql/sql_handler.cc:
  Bug#14397 - OPTIMIZE TABLE with an open HANDLER causes a crash
  The first two diffs make the primary bug fix.
  The rest is for the secondary fix.
sql/sql_table.cc:
  Bug#14397 - OPTIMIZE TABLE with an open HANDLER causes a crash
  The first diff (four changed places) make the 5.0 addendum fix.
  The other three are changed function calls for the secondary fix.
2005-11-15 21:57:02 +01:00
unknown
faaf53d966 Merge mysql.com:/home/mydev/mysql-4.0-4000
into  mysql.com:/home/mydev/mysql-4.1-4100


mysql-test/r/handler.result:
  Auto merged
sql/mysql_priv.h:
  Auto merged
sql/sql_base.cc:
  Auto merged
sql/sql_class.cc:
  Auto merged
mysql-test/t/handler.test:
  Bug#14397 - OPTIMIZE TABLE with an open HANDLER causes a crash
  Manual merge.
sql/sql_handler.cc:
  Bug#14397 - OPTIMIZE TABLE with an open HANDLER causes a crash
  Manual merge.
sql/sql_table.cc:
  Bug#14397 - OPTIMIZE TABLE with an open HANDLER causes a crash
  Manual merge.
2005-11-15 18:09:40 +01:00
unknown
7d183320b0 Bug#14397 - OPTIMIZE TABLE with an open HANDLER causes a crash
Version for 4.0.
It fixes two problems:
1. The cause of the bug was that we did not check the table version for
   the HANDLER ... READ commands. We did not notice when a table was
   replaced by a new one. This can happen during ALTER TABLE, REPAIR
   TABLE, and OPTIMIZE TABLE (there might be more cases). I call the fix
   for this problem "the primary bug fix".
2. mysql_ha_flush() was not always called with a locked LOCK_open.
   Though the function comment clearly said it must.
   I changed the code so that the locking is done when required. I call
   the fix for this problem "the secondary fix".


mysql-test/r/handler.result:
  Bug#14397 - OPTIMIZE TABLE with an open HANDLER causes a crash
  The test result.
mysql-test/t/handler.test:
  Bug#14397 - OPTIMIZE TABLE with an open HANDLER causes a crash
  The test case.
sql/mysql_priv.h:
  Bug#14397 - OPTIMIZE TABLE with an open HANDLER causes a crash
  Changed a definition for the secondary fix.
sql/sql_base.cc:
  Bug#14397 - OPTIMIZE TABLE with an open HANDLER causes a crash
  Changed function calls for the secondary fix.
sql/sql_class.cc:
  Bug#14397 - OPTIMIZE TABLE with an open HANDLER causes a crash
  Changed a function call for the secondary fix.
sql/sql_handler.cc:
  Bug#14397 - OPTIMIZE TABLE with an open HANDLER causes a crash
  The first two diffs make the primary bug fix.
  The rest is for the secondary fix.
sql/sql_table.cc:
  Bug#14397 - OPTIMIZE TABLE with an open HANDLER causes a crash
  Changed function calls for the secondary fix.
2005-11-03 18:24:12 +01:00
unknown
b763c011b0 merge
sql/ha_federated.cc:
  Auto merged
sql/lock.cc:
  Auto merged
sql/mysql_priv.h:
  Auto merged
sql/sp.cc:
  Auto merged
sql/sql_base.cc:
  Auto merged
sql/sql_handler.cc:
  Auto merged
sql/sql_insert.cc:
  Auto merged
sql/sql_lex.cc:
  Auto merged
sql/sql_lex.h:
  Auto merged
sql/sql_parse.cc:
  Auto merged
sql/sql_prepare.cc:
  Auto merged
sql/sql_table.cc:
  Auto merged
2005-09-15 07:36:47 +02: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
5c0dc1ace8 Merge mronstrom@bk-internal.mysql.com:/home/bk/mysql-5.0
into  c-4a09e253.1238-1-64736c10.cust.bredbandsbolaget.se:/home/pappa/mysql-5.1


BitKeeper/deleted/.del-Grep.cpp~ad798e9ae519d667:
  Auto merged
BitKeeper/deleted/.del-Grep.hpp~b05e3af6cfabe387:
  Auto merged
BitKeeper/deleted/.del-GrepInit.cpp~df28ab3a892455fd:
  Auto merged
BitKeeper/deleted/.del-Makefile.am~f73be89578d3b6cc:
  Auto merged
BitKeeper/deleted/.del-Makefile~b293ae88e4394490:
  Auto merged
BitKeeper/deleted/.del-Makefile~e0b7d67078f0fae0:
  Auto merged
BitKeeper/deleted/.del-grep_systab_test.cpp~c7305578bec8cb62:
  Auto merged
BitKeeper/etc/config:
  Auto merged
config/ac-macros/ha_ndbcluster.m4:
  Auto merged
include/my_global.h:
  Auto merged
mysql-test/mysql-test-run.pl:
  Auto merged
BitKeeper/deleted/.del-testGrep.cpp~2106eb0a6bf2a1b5:
  Auto merged
mysql-test/r/alter_table.result:
  Auto merged
mysql-test/r/grant.result:
  Auto merged
mysql-test/r/ps_6bdb.result:
  Auto merged
mysql-test/r/ps_7ndb.result:
  Auto merged
mysys/Makefile.am:
  Auto merged
scripts/make_win_src_distribution.sh:
  Auto merged
sql/field.cc:
  Auto merged
sql/ha_berkeley.cc:
  Auto merged
sql/ha_berkeley.h:
  Auto merged
sql/ha_heap.h:
  Auto merged
sql/ha_innodb.cc:
  Auto merged
sql/ha_innodb.h:
  Auto merged
sql/ha_ndbcluster.cc:
  Auto merged
sql/handler.cc:
  Auto merged
sql/handler.h:
  Auto merged
sql/item.cc:
  Auto merged
sql/item_subselect.cc:
  Auto merged
sql/lex.h:
  Auto merged
sql/lock.cc:
  Auto merged
sql/log_event.cc:
  Auto merged
sql/mysqld.cc:
  Auto merged
sql/set_var.cc:
  Auto merged
sql/slave.cc:
  Auto merged
sql/sp.cc:
  Auto merged
sql/sql_acl.cc:
  Auto merged
sql/sql_cache.cc:
  Auto merged
sql/sql_class.h:
  Auto merged
sql/sql_delete.cc:
  Auto merged
sql/sql_handler.cc:
  Auto merged
sql/sql_help.cc:
  Auto merged
sql/sql_insert.cc:
  Auto merged
sql/sql_lex.cc:
  Auto merged
sql/sql_lex.h:
  Auto merged
sql/sql_load.cc:
  Auto merged
sql/sql_parse.cc:
  Auto merged
sql/sql_select.cc:
  Auto merged
sql/sql_select.h:
  Auto merged
sql/sql_show.cc:
  Auto merged
sql/sql_table.cc:
  Auto merged
sql/sql_update.cc:
  Auto merged
sql/sql_yacc.yy:
  Auto merged
sql/table.cc:
  Auto merged
sql/table.h:
  Auto merged
storage/heap/hp_delete.c:
  Auto merged
storage/innobase/btr/btr0pcur.c:
  Auto merged
storage/innobase/btr/btr0sea.c:
  Auto merged
storage/innobase/include/read0read.h:
  Auto merged
storage/innobase/include/srv0srv.h:
  Auto merged
storage/innobase/include/trx0trx.h:
  Auto merged
storage/innobase/include/univ.i:
  Auto merged
storage/innobase/lock/lock0lock.c:
  Auto merged
storage/innobase/read/read0read.c:
  Auto merged
storage/innobase/row/row0ins.c:
  Auto merged
storage/innobase/row/row0sel.c:
  Auto merged
storage/innobase/row/row0umod.c:
  Auto merged
storage/innobase/row/row0upd.c:
  Auto merged
storage/innobase/srv/srv0srv.c:
  Auto merged
storage/innobase/srv/srv0start.c:
  Auto merged
storage/innobase/trx/trx0trx.c:
  Auto merged
storage/myisam/ft_boolean_search.c:
  Auto merged
storage/myisam/myisampack.c:
  Auto merged
storage/myisammrg/myrg_static.c:
  Auto merged
storage/ndb/include/kernel/AttributeDescriptor.hpp:
  Auto merged
storage/ndb/include/kernel/BlockNumbers.h:
  Auto merged
storage/ndb/include/kernel/GlobalSignalNumbers.h:
  Auto merged
storage/ndb/include/kernel/kernel_types.h:
  Auto merged
storage/ndb/include/kernel/signaldata/AlterTable.hpp:
  Auto merged
storage/ndb/include/ndbapi/NdbDictionary.hpp:
  Auto merged
storage/ndb/include/portlib/NdbTCP.h:
  Auto merged
storage/ndb/src/common/debugger/BlockNames.cpp:
  Auto merged
storage/ndb/src/common/logger/LogHandler.cpp:
  Auto merged
storage/ndb/src/common/portlib/NdbTCP.cpp:
  Auto merged
storage/ndb/src/common/portlib/win32/NdbTCP.c:
  Auto merged
storage/ndb/src/common/transporter/TransporterRegistry.cpp:
  Auto merged
storage/ndb/src/kernel/Makefile.am:
  Auto merged
storage/ndb/src/kernel/SimBlockList.cpp:
  Auto merged
storage/ndb/src/kernel/blocks/Makefile.am:
  Auto merged
storage/ndb/src/kernel/blocks/cmvmi/Cmvmi.cpp:
  Auto merged
storage/ndb/src/kernel/blocks/dbacc/Dbacc.hpp:
  Auto merged
storage/ndb/src/kernel/blocks/dbacc/DbaccInit.cpp:
  Auto merged
storage/ndb/src/kernel/blocks/dbacc/DbaccMain.cpp:
  Auto merged
storage/ndb/src/kernel/blocks/dbdict/Dbdict.cpp:
  Auto merged
storage/ndb/src/kernel/blocks/dbdict/Dbdict.hpp:
  Auto merged
storage/ndb/src/kernel/blocks/dbdict/printSchemaFile.cpp:
  Auto merged
storage/ndb/src/kernel/blocks/dbdih/DbdihMain.cpp:
  Auto merged
storage/ndb/src/kernel/blocks/dblqh/Dblqh.hpp:
  Auto merged
storage/ndb/src/kernel/blocks/dblqh/DblqhMain.cpp:
  Auto merged
storage/ndb/src/kernel/blocks/dblqh/redoLogReader/redoLogFileReader.cpp:
  Auto merged
storage/ndb/src/kernel/blocks/dbtc/Dbtc.hpp:
  Auto merged
storage/ndb/src/kernel/blocks/dbtc/DbtcMain.cpp:
  Auto merged
storage/ndb/src/kernel/blocks/ndbcntr/NdbcntrMain.cpp:
  Auto merged
storage/ndb/src/kernel/blocks/qmgr/Qmgr.hpp:
  Auto merged
storage/ndb/src/kernel/blocks/qmgr/QmgrInit.cpp:
  Auto merged
storage/ndb/src/kernel/blocks/qmgr/QmgrMain.cpp:
  Auto merged
storage/ndb/src/kernel/blocks/suma/Suma.cpp:
  Auto merged
storage/ndb/src/kernel/vm/SimulatedBlock.cpp:
  Auto merged
storage/ndb/src/kernel/vm/SimulatedBlock.hpp:
  Auto merged
storage/ndb/src/mgmapi/mgmapi.cpp:
  Auto merged
storage/ndb/src/mgmsrv/MgmtSrvr.cpp:
  Auto merged
storage/ndb/src/ndbapi/DictCache.cpp:
  Auto merged
storage/ndb/src/ndbapi/DictCache.hpp:
  Auto merged
storage/ndb/src/ndbapi/NdbDictionaryImpl.cpp:
  Auto merged
storage/ndb/src/ndbapi/TransporterFacade.cpp:
  Auto merged
storage/ndb/tools/Makefile.am:
  Auto merged
storage/ndb/tools/ndb_condig.cpp:
  Auto merged
strings/ctype-big5.c:
  Auto merged
strings/ctype-ucs2.c:
  Auto merged
support-files/mysql.spec.sh:
  Auto merged
VC++Files/sql/mysqld.dsp:
  Manual 5.0 - 5.1 merge
configure.in:
  Manual 5.0 - 5.1 merge
sql/mysql_priv.h:
  Manual 5.0 - 5.1 merge
sql/share/errmsg.txt:
  Manual 5.0 - 5.1 merge
sql/sql_base.cc:
  Manual 5.0 - 5.1 merge
sql/sql_prepare.cc:
  Manual 5.0 - 5.1 merge
storage/ndb/src/common/util/version.c:
  Manual 5.0 - 5.1 merge
storage/ndb/src/kernel/blocks/dblqh/Makefile.am:
  Manual 5.0 - 5.1 merge
2005-08-25 13:11:38 -04:00
unknown
39fda60043 Fix for bug #10055 "Using stored function with information_schema causes empty
result set".

To enable full access to contents of I_S tables from stored functions
or statements that use them, we manipulate with thread's open tables
state and ensure that we won't cause deadlock when we open tables by
ignoring flushes and name-locks.
Building of contents of I_S.TABLES no longer requires locking of tables
since we use use handler::info() method with HA_STATUS_AUTO flag instead
of handler::update_auto_increment() for obtaining information about
auto-increment values. But this also means that handlers have to implement
support for HA_STATUS_AUTO flag (particularly InnoDB needs it).


mysql-test/r/alter_table.result:
  Updated test results. This change was caused by the fact that now when
  we build contents of I_S tables (and thus output of SHOW INDEX) we
  don't use instances of tables which may be already opened and locked
  by thread (we always use new instance).
mysql-test/r/information_schema.result:
  Added test which checks how information about current auto-increment value for
  table is reported in INFORMATION_SCHEMA.TABLES view.
mysql-test/r/sp.result:
  Added test for bug #10055 "Using stored function with information_schema causes
  empty result set".
mysql-test/t/information_schema.test:
  Added test which checks how information about current auto-increment value for
  table is reported in INFORMATION_SCHEMA.TABLES view.
mysql-test/t/sp.test:
  Added test for bug #10055 "Using stored function with information_schema causes
  empty result set".
sql/mysql_priv.h:
  close_thread_tables():
    Get rid of 'stopper' argument which is no longer used. Now when we need
    to open and then close some table without touching tables which are already
    opened we use THD::reset_n/restore_backup_open_tables_state() methods.
  open_tables()/open_normal_and_derived_tables():
    Added 'flags' argument to be able open tables even if some has done
    a flush or hold namelock on them.
sql/sp.cc:
  close_proc_table/open_proc_table_for_read/db_find_routine():
    Replaced push_open_tables_state/pop_open_tables_state() methods which
    were saving/restoring current open tables state in/from THD::open_state_list
    with reset_n_backup_open_tables_state/restore_backup_open_tables_state()
    methods which assume that backup storage for this state is allocated on
    stack (or elsewhere) by their caller.
  open_proc_table_for_read():
    Since now we can have several open tables states stacked up we can't rely
    rely on checking whether we have some tables open in previous state.
    Instead we always assume that some tables are open and we need to ignore
    flush while locking mysql.proc. We don't really need 
    MYSQL_LOCK_IGNORE_GLOBAL_READ_LOCK in this case since we open mysql.proc table
    only for reading.
sql/sp.h:
  Added declarations of open_proc_table_for_read()/close_proc_table() to be
  able to use them in sql_show.cc.
sql/sql_base.cc:
  close_thread_tables():
    Get rid of 'stopper' argument which is no longer used. Now when we need
    to open and then close some table without touching tables which are already
    opened we use THD::reset_n/restore_backup_open_tables_state() methods.
  open_tables()/open_normal_and_derived_tables():
    Added 'flags' argument to be able open tables even if some has done
    a flush or hold namelock on them.
sql/sql_class.cc:
  Open_tables_state, THD:
    Replaced push_open_tables_state/pop_open_tables_state() methods which
    were saving/restoring current open tables state in/from THD::open_state_list
    with reset_n_backup_open_tables_state/restore_backup_open_tables_state()
    methods which assume that backup storage for this state is allocated on
    stack (or elsewhere) by their caller.
sql/sql_class.h:
  Open_tables_state, THD:
    Replaced push_open_tables_state/pop_open_tables_state() methods which
    were saving/restoring current open tables state in/from THD::open_state_list
    with reset_n_backup_open_tables_state/restore_backup_open_tables_state()
    methods which assume that backup storage for this state is allocated on
    stack (or elsewhere) by their caller.
sql/sql_handler.cc:
  open_tables()/open_normal_and_derived_tables():
    Added 'flags' argument to be able open tables even if some has done
    a flush or hold namelock on them.
sql/sql_prepare.cc:
  open_tables()/open_normal_and_derived_tables():
    Added 'flags' argument to be able open tables even if some has done
    a flush or hold namelock on them.
sql/sql_show.cc:
  get_all_tables():
    Now we use THD::reset_n_/restore_backup_open_tables_state() for 
    saving/restoring open tables state instead of working with it directly
    (This also allows us to have proper content of I_S system tables in
    statements with stored functions and in stored functions). We also
    ignore possible flushes when opening tables (we may create deadlock
    otherwise). Also we do all needed manipulations with LEX in this function
    and not in get_schema_tables_result() now.
  get_schema_tables_record():
    Let us use handler::info() method with HA_STATUS_AUTO flag for obtaining
    information about table's auto-increment value. This allows to avoid locking
    of tables which is needed when we use handler::update_auto_increment() method.
  fill_schema_proc():
    Now we use open_proc_table_for_read/close_proc_table() for access to
    mysql.proc table (so we won't cause deadlock if we already have some
    tables open and locked, this also allows us to have proper content in
    ROUTINES system table in statements using stored functions/in stored
    functions).
  get_schema_tables_result():
    Moved all manipulations with Open_tables_state and LEX needed for
    safe opening of tables to ST_SCHEMA_TABLE::fill_table functions
    (i.e. get_all_tables() and fill_schema_proc()).
sql/sql_update.cc:
  open_tables()/open_normal_and_derived_tables():
    Added 'flags' argument to be able open tables even if some has done
    a flush or hold namelock on them.
2005-08-08 17:46:06 +04:00
unknown
cd483c5520 Patch for push of wl1354 Partitioning 2005-07-18 13:31:02 +02:00
unknown
b4f595b95f Name resolution context added (BUG#6443)
include/my_bitmap.h:
  new bitmap operation
mysql-test/r/view.result:
  added warnings
  Correct inserting data check (absence of default value) for view underlying tables (BUG#6443)
mysql-test/t/view.test:
  Correct inserting data check (absence of default value) for view underlying tables (BUG#6443)
mysys/my_bitmap.c:
  new bitmap operation
sql/field.h:
  index of field in table added
sql/item.cc:
  Name resolution context added
  table list removed from fix_fields() arguments
sql/item.h:
  Name resolution context added
  table list removed from fix_fields() arguments
sql/item_cmpfunc.cc:
  table list removed from fix_fields() arguments
sql/item_cmpfunc.h:
  table list removed from fix_fields() arguments
sql/item_func.cc:
  table list removed from fix_fields() arguments
sql/item_func.h:
  table list removed from fix_fields() arguments
sql/item_row.cc:
  table list removed from fix_fields() arguments
sql/item_row.h:
  table list removed from fix_fields() arguments
sql/item_strfunc.cc:
  fixed server crash on NULL argument
sql/item_strfunc.h:
  table list removed from fix_fields() arguments
sql/item_subselect.cc:
  table list removed from fix_fields() arguments
sql/item_subselect.h:
  table list removed from fix_fields() arguments
sql/item_sum.cc:
  table list removed from fix_fields() arguments
sql/item_sum.h:
  table list removed from fix_fields() arguments
sql/item_timefunc.cc:
  table list removed from fix_fields() arguments
sql/item_timefunc.h:
  table list removed from fix_fields() arguments
sql/item_uniq.h:
  table list removed from fix_fields() arguments
sql/log_event.cc:
  Name resolution context added
sql/log_event.h:
  Name resolution context added
sql/mysql_priv.h:
  Name resolution context added
sql/set_var.cc:
  table list removed from fix_fields() arguments
sql/share/errmsg.txt:
  new error message
sql/sp.cc:
  Name resolution context added
sql/sp_head.cc:
  table list removed from fix_fields() arguments
sql/sp_head.h:
  Name resolution context added
sql/sql_base.cc:
  table list removed from fix_fields() arguments
  Name resolution context added
sql/sql_class.cc:
  renamed variable
sql/sql_delete.cc:
  Name resolution context added
sql/sql_derived.cc:
  Name resolution context added
sql/sql_do.cc:
  table list removed from fix_fields() arguments
sql/sql_handler.cc:
  Name resolution context added
sql/sql_help.cc:
  Name resolution context added
sql/sql_insert.cc:
  Name resolution context added
  table list removed from fix_fields() arguments
sql/sql_lex.cc:
  Name resolution context added
sql/sql_lex.h:
  removed resolve mode (information stored into name resolution context)
sql/sql_load.cc:
  table list removed from fix_fields() arguments
sql/sql_olap.cc:
  Name resolution context added
sql/sql_parse.cc:
  Name resolution context added
sql/sql_prepare.cc:
  table list removed from fix_fields() arguments
sql/sql_select.cc:
  table list removed from fix_fields() arguments
sql/sql_show.cc:
  Name resolution context added
sql/sql_trigger.cc:
  table list removed from fix_fields() arguments
sql/sql_udf.h:
  table list removed from fix_fields() arguments
sql/sql_union.cc:
  Name resolution context added
sql/sql_update.cc:
  Name resolution context added
sql/sql_view.cc:
  Name resolution context added
sql/sql_view.h:
  table list removed from fix_fields() arguments
sql/sql_yacc.yy:
  Name resolution context added
sql/table.cc:
  Name resolution context added
  merged view processing moved
sql/table.h:
  merged view processing moved
2005-07-01 07:05:42 +03:00
unknown
04f6f63dd8 A preparatory patch to help adding JOIN::transform() and move one-time
query transformations to the PREPARE stage (prepared statements).


sql/item.h:
  Remove an unused friend declaration.
sql/mysql_priv.h:
  Change signature of insert_fields()
sql/sp_head.cc:
  Make is_stmt_prepare_or_first_sp_execute really work: reset SP state
  to EXECUTED after execution.
sql/sql_base.cc:
  allocate_view_names flag of insert_fields is removed.
  The purpose of this variable was to amend the case when a view
  is replaced with a base table between subsequent executions of a prepared
  statement: in that case the new table theoretically can be used instead
  of the view. If allocate_view_names was set,
  all the references to the view expressions were replaced with Item_field's
  which in turn could have been resolved by their names.
  But this approach doesn't work for other reasons, so let's not try
  to help what must be solved by TDC.
sql/sql_class.h:
  Add is_first_sp_execute() helper method.
sql/sql_handler.cc:
  insert_fields signature changed.
sql/sql_lex.h:
  Add a comment for variable 'first_execution'.
2005-06-21 21:15:21 +04:00
unknown
fec1c6ac67 Merge
BitKeeper/etc/logging_ok:
  auto-union
myisam/mi_check.c:
  Auto merged
mysql-test/r/create.result:
  Auto merged
mysql-test/r/innodb_handler.result:
  Auto merged
mysql-test/r/ps_7ndb.result:
  Auto merged
mysql-test/t/create.test:
  Auto merged
sql/set_var.cc:
  Auto merged
mysql-test/r/sql_mode.result:
  SCCS merged
mysql-test/t/sql_mode.test:
  SCCS merged
sql/sql_acl.cc:
  SCCS merged
sql/sql_handler.cc:
  SCCS merged
sql/sql_table.cc:
  SCCS merged
2005-06-09 17:15:06 +01:00
unknown
575a46a1ef bug#5373: handler READ NEXT w/o HANDLER READ [FIRST]
check table->file->inited to catch incorrect calling sequence.


mysql-test/r/innodb_handler.result:
  bug#5373: handler READ NEXT w/o HANDLER READ [FIRST]
mysql-test/t/innodb_handler.test:
  bug#5373: handler READ NEXT w/o HANDLER READ [FIRST]
sql/sql_handler.cc:
  cleanup: call index_init *correctly*, not every time.
  check table->file->inited to catch incorrect calling sequence.
2005-06-07 22:43:25 +02:00
unknown
5188f031ae Patch two (the final one) for Bug#7306 "the server side preparedStatement
error for LIMIT placeholder".
The patch adds grammar support for LIMIT ?, ? and changes the
type of ST_SELECT_LEX::select_limit,offset_limit from ha_rows to Item*,
so that it can point to Item_param.


mysql-test/include/ps_modify.inc:
  Fix existing tests: now LIMIT can contain placeholders.
mysql-test/include/ps_query.inc:
  Fix existing tests: now LIMIT can contain placeholders.
mysql-test/r/ps.result:
  Add basic test coverage for LIMIT ?, ? and fix test results.
mysql-test/r/ps_2myisam.result:
  Fix test results: now LIMIT can contain placeholders.
mysql-test/r/ps_3innodb.result:
  Fix test results: now LIMIT can contain placeholders.
mysql-test/r/ps_4heap.result:
  Fix test results: now LIMIT can contain placeholders.
mysql-test/r/ps_5merge.result:
  Fix test results: now LIMIT can contain placeholders.
mysql-test/r/ps_6bdb.result:
  Fix test results: now LIMIT can contain placeholders.
mysql-test/r/ps_7ndb.result:
  Fix test results: now LIMIT can contain placeholders.
mysql-test/t/ps.test:
  Add basic test coverage for LIMIT ?, ?.
sql/item.h:
  Add a short-cut for (ulonglong) val_int() to Item.
  Add a constructor to Item_int() that accepts ulonglong.
  Simplify Item_uint constructor by using the c-tor above.
sql/item_subselect.cc:
  Now select_limit has type Item *.
  We can safely create an Item in Item_exists_subselect::fix_length_and_dec():
  it will be allocated in runtime memory root and freed in the end of
  execution.
sql/sp_head.cc:
  Add a special initalization state for stored procedures to 
  be able to easily distinguish the first execution of a stored procedure
  from prepared statement prepare.
sql/sql_class.h:
  Introduce new state 'INITIALIZED_FOR_SP' to be able to easily distinguish
  the first execution of a stored procedure from prepared statement prepare.
sql/sql_derived.cc:
  - use unit->set_limit() to set unit->select_limit_cnt, offset_limit_cnt
    evreryplace. Add a warning about use of set_limit in 
  mysql_derived_filling.
sql/sql_error.cc:
  - use unit->set_limit() to set unit->select_limit_cnt, offset_limit_cnt
    evreryplace.
  - this change is also aware of bug#11095 "show warnings limit 0 returns 
  all rows instead of zero rows", so the one who merges the bugfix from
  4.1 can use local version of sql_error.cc.
sql/sql_handler.cc:
  - use unit->set_limit() to initalize 
  unit->select_limit_cnt,offset_limit_cnt everyplace.
sql/sql_lex.cc:
  Now ST_SELECT_LEX::select_limit, offset_limit have type Item *
sql/sql_lex.h:
  Now ST_SELECT_LEX::select_limit, offset_limit have type Item *
sql/sql_parse.cc:
  - use unit->set_limit() to initalize 
  unit->select_limit_cnt,offset_limit_cnt everyplace. 
  - we can create an Item_int to set global limit of a statement:
  it will be created in the runtime mem root and freed in the end of
  execution.
sql/sql_repl.cc:
  Use unit->set_limit to initialize limits.
sql/sql_select.cc:
  - select_limit is now Item* so the proper way to check for default value
  is to compare it with NULL.
sql/sql_union.cc:
  Evaluate offset_limit_cnt using the new type of ST_SELECT_LEX::offset_limit
sql/sql_view.cc:
  Now ST_SELECT_LEX::select_limit, offset_limit have type Item *
sql/sql_yacc.yy:
  Add grammar support for LIMIT ?, ? clause.
2005-06-07 14:11:36 +04:00
unknown
046ced266a Bug#10224 - ANALYZE TABLE crashing with simultaneous CREATE ... SELECT statement.
Manual merge from 4.1.


mysql-test/r/create.result:
  Auto merged
mysql-test/t/create.test:
  Auto merged
sql/mysql_priv.h:
  Auto merged
sql/sql_handler.cc:
  Auto merged
sql/sql_insert.cc:
  Auto merged
sql/sql_yacc.yy:
  Auto merged
2005-06-01 11:15:21 +02:00
unknown
57d4adf60c Bug#10224 - ANALYZE TABLE crashing with simultaneous CREATE ... SELECT statement.
Hand merged from 4.0.


sql/lock.cc:
  Auto merged
sql/mysql_priv.h:
  Auto merged
sql/sql_acl.cc:
  Auto merged
sql/sql_handler.cc:
  Auto merged
sql/sql_table.cc:
  Auto merged
2005-05-31 19:37:24 +02:00
unknown
cf2188ca39 Bug#10224 - ANALYZE TABLE crashing with simultaneous CREATE ... SELECT statement.
1.) Added a new option to mysql_lock_tables() for ignoring FLUSH TABLES.
Used the new option in create_table_from_items().
It is necessary to prevent the SELECT table from being reopend.
It would get new storage assigned for its fields, while the
SELECT part of the command would still use the old (freed) storage.
2.) Protected the CREATE TABLE and CREATE TABLE ... SELECT commands
against a global read lock. This prevents a deadlock in
CREATE TABLE ... SELECT in conjunction with FLUSH TABLES WITH READ LOCK
and avoids the creation of new tables during a global read lock.
3.) Replaced set_protect_against_global_read_lock() and
unset_protect_against_global_read_lock() by
wait_if_global_read_lock() and start_waiting_global_read_lock()
in the INSERT DELAYED handling.


mysql-test/r/create.result:
  Bug#10224 - ANALYZE TABLE crashing with simultaneous CREATE ... SELECT statement.
  Added test results.
mysql-test/t/create.test:
  Bug#10224 - ANALYZE TABLE crashing with simultaneous CREATE ... SELECT statement.
  Added tests which do not require concurrency.
sql/lock.cc:
  Bug#10224 - ANALYZE TABLE crashing with simultaneous CREATE ... SELECT statement.
  Added a new option to mysql_lock_tables() for ignoring FLUSH TABLES.
  Changed the parameter list.
  Removed two unnecessary functions. Their functionality is included in
  wait_if_global_read_lock() and start_waiting_global_read_lock().
sql/mysql_priv.h:
  Bug#10224 - ANALYZE TABLE crashing with simultaneous CREATE ... SELECT statement.
  Changed the declaration of mysql_lock_tables().
  Added definitions for the new options.
sql/sql_acl.cc:
  Bug#10224 - ANALYZE TABLE crashing with simultaneous CREATE ... SELECT statement.
  Adjusted mysql_lock_tables() calls to the new argument list.
sql/sql_base.cc:
  Bug#10224 - ANALYZE TABLE crashing with simultaneous CREATE ... SELECT statement.
  Adjusted mysql_lock_tables() calls to the new argument list.
sql/sql_handler.cc:
  Bug#10224 - ANALYZE TABLE crashing with simultaneous CREATE ... SELECT statement.
  Adjusted mysql_lock_tables() calls to the new argument list.
sql/sql_insert.cc:
  Bug#10224 - ANALYZE TABLE crashing with simultaneous CREATE ... SELECT statement.
  Replaced set_protect_against_global_read_lock() and
  unset_protect_against_global_read_lock() by
  wait_if_global_read_lock() and start_waiting_global_read_lock()
  in the INSERT DELAYED handling.
  Adjusted mysql_lock_tables() calls to the new argument list.
sql/sql_parse.cc:
  Bug#10224 - ANALYZE TABLE crashing with simultaneous CREATE ... SELECT statement.
  Protected the CREATE TABLE and CREATE TABLE ... SELECT commands
  against a global read lock. This prevents a deadlock in
  CREATE TABLE ... SELECT in conjunction with FLUSH TABLES WITH READ LOCK
  and avoids the creation of new tables during a global read lock.
sql/sql_table.cc:
  Bug#10224 - ANALYZE TABLE crashing with simultaneous CREATE ... SELECT statement.
  Adjusted mysql_lock_tables() calls to the new argument list.
  Used the new option in create_table_from_items().
2005-05-31 11:08:14 +02:00
unknown
ac9f68b9fa Better approach for prelocking of tables for stored routines execution
and some SP-related cleanups.

- We don't have separate stage for calculation of list of tables
  to be prelocked and doing implicit LOCK/UNLOCK any more.
  Instead we calculate this list at open_tables() and do implicit
  LOCK in lock_tables() (and UNLOCK in close_thread_tables()).
  Also now we support cases when same table (with same alias) is
  used several times in the same query in SP.

- Cleaned up execution of SP. Moved all common code which handles
  LEX and does preparations before statement execution or complex
  expression evaluation to auxilary sp_lex_keeper class. Now 
  all statements in SP (and corresponding instructions) that
  evaluate expression which can contain subquery have their
  own LEX.


mysql-test/r/lock.result:
  Replaced wrong error code with the correct one after fixing bug in
  SP-locking.
mysql-test/r/mysqldump.result:
  Added dropping of view which is used in test to its beginning.
mysql-test/r/sp.result:
  Added tests for improved SP-locking.
  Temporarily disabled tests for SHOW PROCEDURE STATUS and alike
  (Until Monty will allow to open mysql.proc under LOCK TABLES without
  mentioning it in lock list).
  Replaced wrong results of test for bug #5240 with correct results after
  fixing bug in handling of cursors.
mysql-test/t/lock.test:
  Replaced wrong error code with the correct one after fixing bug in
  SP-locking.
mysql-test/t/mysqldump.test:
  Added dropping of view which is used in test to its beginning.
mysql-test/t/sp.test:
  Added tests for improved SP-locking.
  Temporarily disabled tests for SHOW PROCEDURE STATUS and alike
  (Until Monty will allow to open mysql.proc under LOCK TABLES without
  mentioning it in lock list).
  Removed test for bug #1654 since we already test exactly this function
  in one of SP-locking tests.
  Removed comment about cursor's wrong behavior in test for bug #5240
  after fixing bug which was its cause.
sql/item_func.cc:
  Removed comment which is no longer true.
sql/mysql_priv.h:
  Changed open_tables() signature.
  Now its 2nd parameter is in/out since it can add elements to table list.
sql/sp.cc:
  sp_find_procedure():
   Added one more parameter which enforces cache only lookup.
  
  sp_merge_hash():
   Now uses its return value to indicate that first of two hashes changed
   as result of merge.
  
  sp_cache_routines():
   This function caches all stored routines used in query now.
sql/sp.h:
  - sp_find_procedure() now has one more parameter which enforces cache only
    lookup.
  - sp_merge_hash() now uses its return value to indicate that first of two
    hashes changed as result of merge.
  - sp_cache_routines() caches all stored routines now. So it does not need
    third argument any more.
sql/sp_head.cc:
  sp_head::sp_head():
   Added initialization of new m_spfuns and m_spprocs members.
  
  sp_head::execute():
   Let us save/restore part of thread context which can be damaged by
   execution of instructions.
  sp_head::execute_function()/execute_procedure():
   Now it is responsibility of caller to close tables used in
   subqueries which are passed as routine parameters.
  
  sp_head::restore_lex():
   Let us accumulate information about routines used by this one
   in new m_spfuns, m_spprocs hashes.
  
  sp_lex_keeper::reset_lex_and_exec_core()
   Main method of new auxilary sp_lex_keeper class to which instructions 
   delegate responsibility for handling LEX and preparations before
   executing statement or calculating complex expression.
  
  Since all instructions which calculate complex expression or execute
  command now use sp_lex_keeper they have to implement
  sp_instr::exec_core() method. Most of instruction specific logic
  has moved from sp_instr::execute() to this new method.
  
  Removed sp_instr_set_user_var class which is no longer used, because
  nowdays we allow execution of statements in stored functions and
  triggers.
  
  sp_merge_table_list() became sp_head::merge_table_list() method. It
  also treats sp_head::m_sptabs as multi-set of tables now.
  
  sp_hash_to_table_list() became sp_head::add_used_tables_to_table_list().
  It takes into account that sp_head::m_sptabs is multi-set and allocates
  object into persistent arena of PS.
  
  Removed sp_merge_table_hash(), sp_open_and_lock_tables(),
  sp_unlock_tables(), sp_merge_routine_tables() methods since they are not
  used by new prelocking mechanism.
  
  Added sp_add_sp_tables_to_table_list() which serves for adding tables needed
  by routines used in query to the query table list for prelocking.
sql/sp_head.h:
  class sp_head:
  - Added m_spfuns, m_spprocs members for storing names of routines used
    by this routine.
  - Added add_used_tables_to_table_list() method which allows to add
    tables needed by this routine to query's table list.
  - Converted sp_merge_table_list() to sp_head::merge_table_list() method.
  - Changed semantics of THD::m_sptabs. Now it is multi-set which contains
    only tables which are used by this routine and not routines that are
    called from this one.
  
  Removed sp_merge_routine_tables(), sp_merge_table_hash(),
  sp_open_and_lock_tables(), sp_unlock_tables() calls since they are not
  used for our prelocking list calculation.
  
  Added auxilary sp_lex_keeper class to which instructions delegate
  responsibility for handling LEX and preparations before executing
  statement or calculating complex expression. This class uses
  new sp_instr::exec_core() method which is responsible for executing
  instruction's core function after all preparations were made.
  
  All instructions which hold and calculate complex expression now have
  their own LEX (by aggregating sp_lex_keeper instance). sp_instr_stmt
  now uses sp_lex_keeper too.
  
  Removed sp_instr_set_user_var class which is no longer used, because
  nowdays we allow execution of statements in stored functions and
  triggers.
sql/sp_rcontext.cc:
  Now sp_cursor holds pointer to sp_lex_keeper instead of LEX.
sql/sp_rcontext.h:
  Now sp_cursor holds pointer to sp_lex_keeper instead of LEX.
sql/sql_acl.cc:
  acl_init(), grant_init():
    Now we use simple_open_n_lock_tables() instead of explicit
    calls to open_tables() and mysql_lock_tables().
sql/sql_base.cc:
  Implemented support for execution of statements in "prelocked" mode.
  
  When we have statement which uses stored routines explicitly or
  implicitly (via views or triggers) we have to open and lock all tables
  for these routines at the same time as tables for the main statement.
  In fact we have to do implicit LOCK TABLES at the begining of such
  statement and implict UNLOCK TABLES at its end. We call such mode
  "prelocked".
  
  When open_tables() is called for the statement tables which are needed
  for execution of routines used by it are added to its tables list
  (this process also caches all routines used). Implicit use of routines
  is discovered when we open view or table with trigger and apropriate
  tables are added to the table list at this moment. Statement which has
  such extra tables in its list (well actually any that uses functions)
  is marked as requiring prelocked mode for its execution.
  
  When lock_tables() sees such statement it will issue implicit LOCK TABLES
  for this extended table list instead of doing usual locking, it will also
  set THD::prelocked_mode to indicate that we are in prelocked mode.
  
  When open_tables()/lock_tables() are called for statement of stored
  routine (substatement), they notice that we are running in prelocked mode
  and use one of prelocked tables from those that are not used by upper
  levels of execution.
  
  close_thread_tables() for substatement won't really close tables used
  but will mark them as free for reuse instead.
  
  Finally when close_thread_tables() is called for the main statement it
  really unlocks and closes all tables used.
  
  Everything will work even if one uses such statement under real LOCK
  TABLES (we are simply not doing implicit LOCK/UNLOCK in this case).
sql/sql_class.cc:
  Added initialization of THD::prelocked_mode member.
sql/sql_class.h:
  - Added prelocked_mode_type enum and THD::prelocked_mode member
    which are used for indication whenever "prelocked mode" is on 
    (i.e. that statement uses stored routines and is executed under
     implicit LOCK TABLES).
  - Removed THD::shortcut_make_view which is no longer needed.
    We use TABLE_LIST::prelocking_placeholder for the same purprose
    now.
sql/sql_handler.cc:
  Changed open_tables() invocation.
  Now its 2nd parameter is in/out since it can add elements to table list.
sql/sql_lex.cc:
  lex_start():
    Added initialization of LEX::query_tables_own_last.
    Unused LEX::sptabs member was removed.
  st_lex::unlink_first_table()/link_first_table_back():
    We should update LEX::query_tables_last properly if table list
    contains(ed) only one element.
sql/sql_lex.h:
  LEX:
  - Removed sptabs member since it is no longer used.
  - Added query_tables_own_last member, which if non-0 indicates that
    statement requires prelocking (implicit LOCK TABLES) for its execution
    and points to last own element in query table list. If it is zero
    then this query does not need prelocking.
  - Added requires_prelocking(), mark_as_requiring_prelocking(),
    first_not_own_table() inline methods to incapsulate and simplify
    usage of this new member.
sql/sql_parse.cc:
  dispatch_command():
    To properly leave prelocked mode when needed we should call
    close_thread_tables() even if there are no open tables.
  mysql_execute_command():
  - Removed part of function which were responsible for doing implicit
    LOCK TABLES before statement execution if statement used stored 
    routines (and doing UNLOCK TABLES at the end).
    Now we do all this in open_tables()/lock_tables()/close_thread_tables()
    instead.
  - It is also sensible to reset errors before execution of statement
    which uses routines.
  - SQLCOM_DO, SQLCOM_SET_OPTION, SQLCOM_CALL
    We should always try to open tables because even if statement has empty
    table list, it can call routines using tables, which should be preopened
    before statement execution.
  - SQLCOM_CALL
    We should not look up routine called in mysql.proc, since it should be
    already cached by this moment by open_tables() call.
  - SQLCOM_LOCK_TABLES
    it is better to use simple_open_n_lock_tables() since we want to avoid
    materialization of derived tables for this command.
sql/sql_prepare.cc:
  mysql_test_update():
    Changed open_tables() invocations. Now its 2nd parameter is in/out
    since it can add elements to table list.
  check_prepared_statement():
    Since now we cache all routines used by statement in open_tables() we 
    don't need to do it explicitly.
  mysql_stmt_prepare():
    Now we should call close_thread_tables() when THD::lex points to the
    LEX of statement which opened tables.
  reset_stmt_for_execute():
    Commented why we are resetting all tables in table list.
sql/sql_trigger.h:
  Table_triggers_list::process_triggers():
    We should surpress sending of ok packet when we are calling trigger's
    routine, since now we allow statements in them.
sql/sql_update.cc:
  Changed open_tables() invocations.
  Now its 2nd parameter is in/out since it can add elements to table list.
sql/sql_view.cc:
  mysql_make_view():
  - Removed handling of routines used in view. Instead we add tables which
    are needed for their execution to statement's table list in 
    open_tables().
  - Now we use TABLE_LIST::prelocking_placeholder instead of 
    THD::shortcut_make_view for indicating that view is opened
    only to discover which tables and routines it uses (this happens
    when we build extended table list for prelocking). Also now we try
    to avoid to modify main LEX in this case (except of its table list).
  - Corrected small error we added tables to the table list of the main
    LEX without updating its query_tables_last member properly.
sql/sql_yacc.yy:
  Now each expression which is used in SP statements and can contain
  subquery has its own LEX. This LEX is stored in corresponding sp_instr
  object and used along with Item tree for expression calculation.
  
  We don't need sp_instr_set_user_var() anymore since now we allow
  execution of statements in stored functions and triggers.
sql/table.h:
  Added TABLE_LIST::prelocking_placeholder member for distinguishing
  elements of table list which does not belong to the statement itself
  and added there only for prelocking (as they are to be used by routines
  called by this statement).
sql/tztime.cc:
  my_tz_init():
    Now we use more simplier simple_open_n_lock_tables() call instead of 
    open_tables()/lock_tables() pair.
2005-03-04 16:35:28 +03:00
unknown
91db48e35a Precision Math implementation
BitKeeper/etc/ignore:
  Added client/decimal.c client/my_decimal.cc client/my_decimal.h to the ignore list
2005-02-09 02:50:45 +04:00
unknown
acf76e3b88 First stage of table definition cache
Split TABLE to TABLE and TABLE_SHARE (TABLE_SHARE is still allocated as part of table, will be fixed soon)
Created Field::make_field() and made Field_num::make_field() to call this
Added 'TABLE_SHARE->db' that points to database name; Changed all usage of table_cache_key as database name to use this instead
Changed field->table_name to point to pointer to alias. This allows us to change alias for a table by just updating one pointer.
Renamed TABLE_SHARE->real_name to table_name
Renamed TABLE->table_name to alias
Renamed TABLE_LIST->real_name to table_name


include/myisam.h:
  Added const before names
mysql-test/r/group_min_max.result:
  Make results repeatable
mysql-test/t/group_min_max.test:
  Make results repeatable
sql/field.cc:
  Created Field::make_field() and made Field_num::make_field() to call this
  Use TABLE_SHARE
  Use sql_strmake() instead of sql_memdup() to simplify code
sql/field.h:
  Changed table_name to be pointer to table_name. This allows us to change alias for all fields by just changing one pointer.
  Use TABLE_SHARE
sql/field_conv.cc:
  Use TABLE_SHARE
sql/filesort.cc:
  Use TABLE_SHARE
sql/ha_berkeley.cc:
  Use TABLE_SHARE
sql/ha_heap.cc:
  Use TABLE_SHARE
sql/ha_innodb.cc:
  Use TABLE_SHARE
sql/ha_myisam.cc:
  Use TABLE_SHARE
sql/ha_myisammrg.cc:
  Use TABLE_SHARE
  Change some pointer handling to use const char*
sql/ha_ndbcluster.cc:
  Use TABLE_SHARE
sql/handler.cc:
  Use TABLE_SHARE
sql/item.cc:
  Use TABLE_SHARE
sql/item_func.cc:
  Use TABLE_SHARE
sql/item_subselect.cc:
  Use TABLE_SHARE
sql/item_sum.cc:
  Use TABLE_SHARE
sql/key.cc:
  Use TABLE_SHARE
sql/lock.cc:
  Use TABLE_SHARE
sql/log_event.cc:
  real_name -> table_name
sql/mysql_priv.h:
  Use TABLE_SHARE
sql/opt_range.cc:
  Use TABLE_SHARE
sql/opt_sum.cc:
  Use TABLE_SHARE
sql/records.cc:
  Use TABLE_SHARE
sql/repl_failsafe.cc:
  real_name -> table_name
sql/slave.cc:
  Use TABLE_SHARE
sql/sp.cc:
  Use TABLE_SHARE
sql/sp_head.cc:
  real_name -> table_name
sql/sql_acl.cc:
  Use TABLE_SHARE
  removed unnecessary assert
  fixed indentation
  changed some char * -> const char*
sql/sql_acl.h:
  changed some char* -> const char*
sql/sql_base.cc:
  Use TABLE_SHARE
sql/sql_cache.cc:
  Use TABLE_SHARE
sql/sql_class.cc:
  Use TABLE_SHARE
sql/sql_db.cc:
  real_name -> table_name
sql/sql_delete.cc:
  Use TABLE_SHARE
sql/sql_derived.cc:
  Use TABLE_SHARE
sql/sql_handler.cc:
  Use TABLE_SHARE
sql/sql_help.cc:
  Use TABLE_SHARE
sql/sql_insert.cc:
  Use TABLE_SHARE
sql/sql_load.cc:
  Use TABLE_SHARE
sql/sql_parse.cc:
  Use TABLE_SHARE
sql/sql_rename.cc:
  real_name -> table_name
sql/sql_select.cc:
  Use TABLE_SHARE
  table->blob_fields now points to field offsets, not fields
  tmp_table->table_name now points to alias name
sql/sql_show.cc:
  Use TABLE_SHARE
sql/sql_table.cc:
  Use TABLE_SHARE
sql/sql_test.cc:
  Use TABLE_SHARE
sql/sql_trigger.cc:
  Use TABLE_SHARE
sql/sql_udf.cc:
  Use TABLE_SHARE
sql/sql_union.cc:
  real_name -> table_name
sql/sql_update.cc:
  Use TABLE_SHARE
sql/sql_view.cc:
  Use TABLE_SHARE
sql/table.cc:
  Split TABLE to TABLE and TABLE_SHARE
  Changed blob_field to be field offsets instead of pointer to fields
  Only initialize table->s->default_values with default record (not all table->record[#])
  Some indentation changes
sql/table.h:
  Split TABLE to TABLE and TABLE_SHARE
sql/tztime.cc:
  real_name -> table_name
sql/unireg.cc:
  Use TABLE_SHARE
sql/unireg.h:
  Use TABLE_SHARE
2005-01-06 13:00:13 +02:00
unknown
bb2d3eaa30 Merge with 4.1
BitKeeper/etc/ignore:
  auto-union
BitKeeper/etc/logging_ok:
  auto-union
Build-tools/Do-compile:
  Auto merged
VC++Files/sql/mysqld.dsp:
  Auto merged
client/Makefile.am:
  Auto merged
client/mysql.cc:
  Auto merged
BitKeeper/deleted/.del-acinclude.m4~f4ab416bac5003:
  Auto merged
client/mysqltest.c:
  Auto merged
include/my_base.h:
  Auto merged
innobase/dict/dict0dict.c:
  Auto merged
innobase/dict/dict0load.c:
  Auto merged
innobase/include/dict0dict.h:
  Auto merged
innobase/include/row0mysql.h:
  Auto merged
innobase/os/os0file.c:
  Auto merged
innobase/srv/srv0srv.c:
  Auto merged
libmysql/libmysql.c:
  Auto merged
myisam/mi_check.c:
  Auto merged
myisam/mi_rnext_same.c:
  Auto merged
myisam/mi_write.c:
  Auto merged
myisam/sort.c:
  Auto merged
mysql-test/mysql-test-run.sh:
  Auto merged
mysql-test/r/ctype_ucs.result:
  Auto merged
mysql-test/r/ctype_ujis.result:
  Auto merged
mysql-test/r/gis-rtree.result:
  Auto merged
mysql-test/r/group_by.result:
  Auto merged
mysql-test/r/merge.result:
  Auto merged
mysql-test/r/metadata.result:
  Auto merged
mysql-test/r/ndb_alter_table.result:
  Auto merged
mysql-test/r/ps_1general.result:
  Auto merged
mysql-test/r/insert_update.result:
  Auto merged
mysql-test/r/timezone2.result:
  Auto merged
mysql-test/r/type_enum.result:
  Auto merged
mysql-test/r/variables.result:
  Auto merged
mysql-test/t/ctype_ucs.test:
  Auto merged
mysql-test/t/merge.test:
  Auto merged
mysql-test/t/ps_1general.test:
  Auto merged
mysql-test/t/subselect.test:
  Auto merged
mysql-test/t/system_mysql_db_fix.test:
  Auto merged
mysql-test/t/variables.test:
  Auto merged
ndb/include/ndbapi/NdbConnection.hpp:
  Auto merged
ndb/include/ndbapi/NdbDictionary.hpp:
  Auto merged
ndb/src/common/util/version.c:
  Auto merged
ndb/src/kernel/blocks/dbacc/DbaccInit.cpp:
  Auto merged
ndb/src/kernel/blocks/dbacc/Makefile.am:
  Auto merged
ndb/src/kernel/blocks/dbdict/Dbdict.cpp:
  Auto merged
ndb/src/kernel/blocks/dbdih/DbdihMain.cpp:
  Auto merged
ndb/src/kernel/blocks/dblqh/DblqhInit.cpp:
  Auto merged
ndb/src/kernel/blocks/dbtc/DbtcMain.cpp:
  Auto merged
ndb/src/kernel/blocks/dbtux/Dbtux.hpp:
  Auto merged
ndb/src/ndbapi/NdbBlob.cpp:
  Auto merged
ndb/src/ndbapi/NdbConnection.cpp:
  Auto merged
ndb/src/ndbapi/NdbDictionary.cpp:
  Auto merged
ndb/src/ndbapi/NdbDictionaryImpl.cpp:
  Auto merged
ndb/src/ndbapi/NdbDictionaryImpl.hpp:
  Auto merged
ndb/src/ndbapi/NdbOperationExec.cpp:
  Auto merged
ndb/src/ndbapi/NdbScanOperation.cpp:
  Auto merged
ndb/test/ndbapi/Makefile.am:
  Auto merged
scripts/make_win_src_distribution.sh:
  Auto merged
scripts/mysql_install_db.sh:
  Auto merged
sql/field.cc:
  Auto merged
sql/ha_innodb.cc:
  Auto merged
sql/ha_ndbcluster.cc:
  Auto merged
sql/ha_ndbcluster.h:
  Auto merged
sql/handler.cc:
  Auto merged
sql/item_cmpfunc.cc:
  Auto merged
sql/item_create.h:
  Auto merged
sql/item_func.cc:
  Auto merged
sql/item_geofunc.cc:
  Auto merged
sql/item_row.cc:
  Auto merged
sql/item_strfunc.cc:
  Auto merged
sql/item_strfunc.h:
  Auto merged
sql/item_sum.cc:
  Auto merged
sql/item_sum.h:
  Auto merged
sql/log.cc:
  Auto merged
sql/log_event.cc:
  Auto merged
sql/mysqld.cc:
  Auto merged
sql/net_serv.cc:
  Auto merged
sql/password.c:
  Auto merged
sql/protocol.cc:
  Auto merged
sql/repl_failsafe.cc:
  Auto merged
sql/set_var.cc:
  Auto merged
sql/slave.cc:
  Auto merged
sql/sql_acl.cc:
  Auto merged
sql/sql_cache.cc:
  Auto merged
sql/sql_class.cc:
  Auto merged
sql/sql_derived.cc:
  Auto merged
sql/sql_do.cc:
  Auto merged
sql/sql_handler.cc:
  Auto merged
sql/sql_help.cc:
  Auto merged
sql/sql_lex.cc:
  Auto merged
sql/sql_lex.h:
  Auto merged
sql/sql_repl.cc:
  Auto merged
sql/sql_show.cc:
  Auto merged
sql/sql_union.cc:
  Auto merged
sql/examples/ha_archive.cc:
  Auto merged
sql/strfunc.cc:
  Auto merged
sql/table.cc:
  Auto merged
sql/table.h:
  Auto merged
sql/tztime.h:
  Auto merged
sql/udf_example.cc:
  Auto merged
sql/unireg.cc:
  Auto merged
Makefile.am:
  Simple merge
client/mysqldump.c:
  Simple merge
configure.in:
  Simple merge
libmysqld/lib_sql.cc:
  Automatic merge
mysql-test/r/func_str.result:
  Automatic merge
mysql-test/r/grant.result:
  simple merge
mysql-test/r/multi_update.result:
  automatc merge
mysql-test/r/ps.result:
  automatic merge
mysql-test/r/ps_2myisam.result:
  Automatic merge
mysql-test/r/ps_3innodb.result:
  Automatic merge
mysql-test/r/ps_4heap.result:
  Automatic merge
mysql-test/r/ps_5merge.result:
  Automatic merge
mysql-test/r/ps_6bdb.result:
  Automatic merge
mysql-test/r/ps_7ndb.result:
  Automatic merge
mysql-test/r/show_check.result:
  Automatic merge
mysql-test/r/subselect.result:
  Automatic merge
mysql-test/t/grant.test:
  Automatic merge
mysql-test/t/multi_update.test:
  Automatic merge
mysql-test/t/ps.test:
  Automatic merge
mysql-test/t/show_check.test:
  Automatic merge
ndb/docs/wl2077.txt:
  merge
ndb/src/mgmsrv/main.cpp:
  merge
scripts/mysql_fix_privilege_tables.sh:
  merge
sql/item.cc:
  Merge (difficult)
sql/item.h:
  simple merge
sql/item_cmpfunc.h:
  Automatic merge
sql/item_subselect.cc:
  Simple merge
sql/item_subselect.h:
  Automatic merge
sql/mysql_priv.h:
  Simple merge
sql/slave.h:
  Automatic merge
sql/sql_base.cc:
  Removed code that was backported to 4.1
sql/sql_class.h:
  Merge (some code moved to sql_insert.cc)
sql/sql_db.cc:
  simple merge
sql/sql_insert.cc:
  Merge (difficult as logic had changed both in 4.1 and 5.0)
  Some coded moved here from sql_class.h
sql/sql_parse.cc:
  Merge (difficult)
sql/sql_prepare.cc:
  Simple merge
sql/sql_select.cc:
  Automatic merge
sql/sql_table.cc:
  Simple merge
sql/sql_update.cc:
  Difficult merge because of different logic for multi-updates
sql/sql_yacc.yy:
  Simple merge
tests/client_test.c:
  Simple merge
2004-12-22 13:54:39 +02:00
unknown
8322eb0aaa * Added comments and one assert
* Backport of safety measures from 5.0: make numeorous replaces:
    s/item->fix_fields()/if (!item->fixed) item->fix_fields()


sql/item.cc:
   * More comments
   * Backport of safety measures from 5.0: make numeorous replaces:
      s/item->fix_fields()/if (!item->fixed) item->fix_fields()
sql/item.h:
  Assert added
sql/item_cmpfunc.cc:
  Backport of safety measures from 5.0: make numeorous replaces:
    s/item->fix_fields()/if (!item->fixed) item->fix_fields()
sql/item_func.cc:
  Backport of safety measures from 5.0: make numeorous replaces:
    s/item->fix_fields()/if (!item->fixed) item->fix_fields()
sql/item_strfunc.h:
  Backport of safety measures from 5.0: make numeorous replaces:
    s/item->fix_fields()/if (!item->fixed) item->fix_fields()
sql/item_subselect.cc:
  Backport of safety measures from 5.0: make numeorous replaces:
    s/item->fix_fields()/if (!item->fixed) item->fix_fields()
sql/item_sum.cc:
  Backport of safety measures from 5.0: make numeorous replaces:
    s/item->fix_fields()/if (!item->fixed) item->fix_fields()
sql/set_var.cc:
  Backport of safety measures from 5.0: make numeorous replaces:
    s/item->fix_fields()/if (!item->fixed) item->fix_fields()
sql/sql_base.cc:
  Backport of safety measures from 5.0: make numeorous replaces:
    s/item->fix_fields()/if (!item->fixed) item->fix_fields()
sql/sql_handler.cc:
  Backport of safety measures from 5.0: make numeorous replaces:
    s/item->fix_fields()/if (!item->fixed) item->fix_fields()
sql/sql_help.cc:
  Backport of safety measures from 5.0: make numeorous replaces:
    s/item->fix_fields()/if (!item->fixed) item->fix_fields()
sql/sql_select.cc:
  Backport of safety measures from 5.0: make numeorous replaces:
    s/item->fix_fields()/if (!item->fixed) item->fix_fields()
2004-12-14 03:36:19 +03:00
unknown
8d71bcec21 now my_printf_error is not better then my_error, but my_error call is shorter
used only one implementation of format parser of (printf)
fixed multistatement


include/mysqld_error.h:
  newerror messages
mysql-test/t/key.test:
  unknown error replaced with real error
mysys/my_error.c:
  my_error & my_printf_error use my_vsprintf
sql/field_conv.cc:
  now my_printf_error is not better then my_error, but my_error call is shorter
sql/ha_innodb.cc:
  now my_printf_error is not better then my_error, but my_error call is shorter
sql/handler.cc:
  now my_printf_error is not better then my_error, but my_error call is shorter
sql/item.cc:
  now my_printf_error is not better then my_error, but my_error call is shorter
sql/item_cmpfunc.cc:
  now my_printf_error is not better then my_error, but my_error call is shorter
sql/item_func.cc:
  now my_printf_error is not better then my_error, but my_error call is shorter
sql/item_strfunc.cc:
  now my_printf_error is not better then my_error, but my_error call is shorter
sql/lock.cc:
  now my_printf_error is not better then my_error, but my_error call is shorter
sql/log.cc:
  now my_printf_error is not better then my_error, but my_error call is shorter
sql/parse_file.cc:
  now my_printf_error is not better then my_error, but my_error call is shorter
sql/procedure.cc:
  now my_printf_error is not better then my_error, but my_error call is shorter
sql/protocol.cc:
  no need reset thd->lex->found_colon to break multiline sequance now, send_error called too late
sql/repl_failsafe.cc:
  now my_printf_error is not better then my_error, but my_error call is shorter
sql/set_var.cc:
  now my_printf_error is not better then my_error, but my_error call is shorter
sql/share/czech/errmsg.txt:
  new errors converted from unknown error
sql/share/danish/errmsg.txt:
  new errors converted from unknown error
sql/share/dutch/errmsg.txt:
  new errors converted from unknown error
sql/share/english/errmsg.txt:
  new errors converted from unknown error
sql/share/estonian/errmsg.txt:
  new errors converted from unknown error
sql/share/french/errmsg.txt:
  new errors converted from unknown error
sql/share/german/errmsg.txt:
  new errors converted from unknown error
sql/share/greek/errmsg.txt:
  new errors converted from unknown error
sql/share/hungarian/errmsg.txt:
  new errors converted from unknown error
sql/share/italian/errmsg.txt:
  new errors converted from unknown error
sql/share/japanese/errmsg.txt:
  new errors converted from unknown error
sql/share/korean/errmsg.txt:
  new errors converted from unknown error
sql/share/norwegian-ny/errmsg.txt:
  new errors converted from unknown error
sql/share/norwegian/errmsg.txt:
  new errors converted from unknown error
sql/share/polish/errmsg.txt:
  new errors converted from unknown error
sql/share/portuguese/errmsg.txt:
  new errors converted from unknown error
sql/share/romanian/errmsg.txt:
  new errors converted from unknown error
sql/share/russian/errmsg.txt:
  new errors converted from unknown error
sql/share/serbian/errmsg.txt:
  new errors converted from unknown error
sql/share/slovak/errmsg.txt:
  new errors converted from unknown error
sql/share/spanish/errmsg.txt:
  new errors converted from unknown error
sql/share/swedish/errmsg.txt:
  new errors converted from unknown error
sql/share/ukrainian/errmsg.txt:
  new errors converted from unknown error
sql/slave.cc:
  now my_printf_error is not better then my_error, but my_error call is shorter
sql/sp.cc:
  now my_printf_error is not better then my_error, but my_error call is shorter
sql/sp_head.cc:
  now my_printf_error is not better then my_error, but my_error call is shorter
sql/sql_acl.cc:
  now my_printf_error is not better then my_error, but my_error call is shorter
sql/sql_analyse.cc:
  now my_printf_error is not better then my_error, but my_error call is shorter
sql/sql_base.cc:
  now my_printf_error is not better then my_error, but my_error call is shorter
sql/sql_class.cc:
  now my_printf_error is not better then my_error, but my_error call is shorter
sql/sql_db.cc:
  now my_printf_error is not better then my_error, but my_error call is shorter
sql/sql_delete.cc:
  now my_printf_error is not better then my_error, but my_error call is shorter
sql/sql_handler.cc:
  now my_printf_error is not better then my_error, but my_error call is shorter
sql/sql_insert.cc:
  now my_printf_error is not better then my_error, but my_error call is shorter
sql/sql_load.cc:
  now my_printf_error is not better then my_error, but my_error call is shorter
sql/sql_map.cc:
  now my_printf_error is not better then my_error, but my_error call is shorter
sql/sql_parse.cc:
  now my_printf_error is not better then my_error, but my_error call is shorter
  multi-row command fixed
sql/sql_prepare.cc:
  now my_printf_error is not better then my_error, but my_error call is shorter
  remover send_error ingected from 4.1
sql/sql_rename.cc:
  now my_printf_error is not better then my_error, but my_error call is shorter
sql/sql_repl.cc:
  now my_printf_error is not better then my_error, but my_error call is shorter
sql/sql_select.cc:
  now my_printf_error is not better then my_error, but my_error call is shorter
sql/sql_show.cc:
  now my_printf_error is not better then my_error, but my_error call is shorter
sql/sql_table.cc:
  now my_printf_error is not better then my_error, but my_error call is shorter
sql/sql_trigger.cc:
  now my_printf_error is not better then my_error, but my_error call is shorter
sql/sql_udf.cc:
  now my_printf_error is not better then my_error, but my_error call is shorter
sql/sql_update.cc:
  now my_printf_error is not better then my_error, but my_error call is shorter
sql/sql_view.cc:
  now my_printf_error is not better then my_error, but my_error call is shorter
sql/sql_yacc.yy:
  now my_printf_error is not better then my_error, but my_error call is shorter
sql/table.cc:
  now my_printf_error is not better then my_error, but my_error call is shorter
strings/my_vsnprintf.c:
  * format support added to my_vsprint
2004-11-13 19:35:51 +02:00
unknown
067863e184 merge
include/mysqld_error.h:
  Auto merged
libmysqld/lib_sql.cc:
  Auto merged
mysql-test/r/rpl_charset.result:
  Auto merged
mysql-test/r/sp.result:
  Auto merged
mysql-test/t/rpl_charset.test:
  Auto merged
mysql-test/t/sp.test:
  Auto merged
sql/filesort.cc:
  Auto merged
sql/ha_innodb.cc:
  Auto merged
sql/ha_innodb.h:
  Auto merged
sql/handler.cc:
  Auto merged
sql/item_cmpfunc.cc:
  Auto merged
sql/item_func.cc:
  Auto merged
sql/item_row.cc:
  Auto merged
sql/item_strfunc.cc:
  Auto merged
sql/item_timefunc.cc:
  Auto merged
sql/item_uniq.h:
  Auto merged
sql/log.cc:
  Auto merged
sql/log_event.cc:
  Auto merged
sql/mysqld.cc:
  Auto merged
sql/parse_file.cc:
  Auto merged
sql/protocol.cc:
  Auto merged
sql/protocol.h:
  Auto merged
sql/protocol_cursor.cc:
  Auto merged
sql/repl_failsafe.cc:
  Auto merged
sql/repl_failsafe.h:
  Auto merged
sql/set_var.cc:
  Auto merged
sql/slave.cc:
  Auto merged
sql/slave.h:
  Auto merged
sql/sp.cc:
  Auto merged
sql/sp_head.cc:
  Auto merged
sql/sql_analyse.cc:
  Auto merged
sql/sql_class.cc:
  Auto merged
sql/sql_class.h:
  Auto merged
sql/sql_db.cc:
  Auto merged
sql/sql_delete.cc:
  Auto merged
sql/sql_error.cc:
  Auto merged
sql/sql_help.cc:
  Auto merged
sql/sql_insert.cc:
  Auto merged
sql/sql_lex.cc:
  Auto merged
sql/sql_lex.h:
  Auto merged
sql/sql_load.cc:
  Auto merged
sql/sql_repl.h:
  Auto merged
sql/sql_select.h:
  Auto merged
sql/sql_show.cc:
  Auto merged
sql/share/czech/errmsg.txt:
  Auto merged
sql/share/danish/errmsg.txt:
  Auto merged
sql/share/dutch/errmsg.txt:
  Auto merged
sql/share/english/errmsg.txt:
  Auto merged
sql/share/estonian/errmsg.txt:
  Auto merged
sql/share/french/errmsg.txt:
  Auto merged
sql/share/german/errmsg.txt:
  Auto merged
sql/share/greek/errmsg.txt:
  Auto merged
sql/share/hungarian/errmsg.txt:
  Auto merged
sql/share/italian/errmsg.txt:
  Auto merged
sql/share/japanese/errmsg.txt:
  Auto merged
sql/share/korean/errmsg.txt:
  Auto merged
sql/share/norwegian-ny/errmsg.txt:
  Auto merged
sql/share/norwegian/errmsg.txt:
  Auto merged
sql/share/polish/errmsg.txt:
  Auto merged
sql/share/portuguese/errmsg.txt:
  Auto merged
sql/sql_udf.cc:
  Auto merged
sql/sql_view.cc:
  Auto merged
sql/table.cc:
  Auto merged
sql/unireg.cc:
  Auto merged
sql/share/romanian/errmsg.txt:
  Auto merged
sql/share/russian/errmsg.txt:
  Auto merged
sql/share/serbian/errmsg.txt:
  Auto merged
sql/share/slovak/errmsg.txt:
  Auto merged
sql/share/spanish/errmsg.txt:
  Auto merged
sql/share/swedish/errmsg.txt:
  Auto merged
sql/share/ukrainian/errmsg.txt:
  Auto merged
2004-11-12 15:36:31 +02:00
unknown
9e921615a1 post-review fixes
mysql-test/r/rpl_rotate_logs.result:
  removed host dependence in error messages
mysql-test/t/rpl_rotate_logs.test:
  removed host dependence in error messages
mysys/my_error.c:
  comment about using my_error family functions
sql/filesort.cc:
  changing my_error on my_message and my_printf_error where if they are prefered
sql/ha_innodb.cc:
  changing my_error on my_message and my_printf_error where if they are prefered
sql/handler.cc:
  changing my_error on my_message and my_printf_error where if they are prefered
sql/item.cc:
  changing my_error on my_message and my_printf_error where if they are prefered
sql/item_cmpfunc.cc:
  changing my_error on my_message and my_printf_error where if they are prefered
sql/item_func.cc:
  changing my_error on my_message and my_printf_error where if they are prefered
sql/item_strfunc.cc:
  changing my_error on my_message and my_printf_error where if they are prefered
sql/item_subselect.cc:
  changing my_error on my_message and my_printf_error where if they are prefered
sql/item_sum.cc:
  changing my_error on my_message and my_printf_error where if they are prefered
sql/lock.cc:
  changing my_error on my_message and my_printf_error where if they are prefered
sql/log.cc:
  changing my_error on my_message and my_printf_error where if they are prefered
sql/mysql_priv.h:
  error check moved to fill_record
sql/mysqld.cc:
  fixed error messages
sql/parse_file.cc:
  changing my_error on my_message and my_printf_error where if they are prefered
sql/protocol.cc:
  changing my_error on my_message and my_printf_error where if they are prefered
sql/protocol_cursor.cc:
  changing my_error on my_message and my_printf_error where if they are prefered
sql/repl_failsafe.cc:
  changing my_error on my_message and my_printf_error where if they are prefered
sql/set_var.cc:
  changing my_error on my_message and my_printf_error where if they are prefered
sql/slave.cc:
  changing my_error on my_message and my_printf_error where if they are prefered
sql/sp.cc:
  changing my_error on my_message and my_printf_error where if they are prefered
sql/sp_head.cc:
  changing my_error on my_message and my_printf_error where if they are prefered
sql/sp_rcontext.cc:
  changing my_error on my_message and my_printf_error where if they are prefered
sql/sql_acl.cc:
  changing my_error on my_message and my_printf_error where if they are prefered
sql/sql_analyse.cc:
  changing my_error on my_message and my_printf_error where if they are prefered
sql/sql_base.cc:
  changing my_error on my_message and my_printf_error where if they are prefered
  error check moved to fill_record
sql/sql_class.cc:
  changing my_error on my_message and my_printf_error where if they are prefered
sql/sql_class.h:
  changing my_error on my_message and my_printf_error where if they are prefered
sql/sql_db.cc:
  changing my_error on my_message and my_printf_error where if they are prefered
sql/sql_delete.cc:
  changing my_error on my_message and my_printf_error where if they are prefered
  error check moved to fill_record
sql/sql_handler.cc:
  changing my_error on my_message and my_printf_error where if they are prefered
sql/sql_help.cc:
  changing my_error on my_message and my_printf_error where if they are prefered
sql/sql_insert.cc:
  changing my_error on my_message and my_printf_error where if they are prefered
  error check moved to fill_record
sql/sql_lex.cc:
  layout fixed
sql/sql_load.cc:
  changing my_error on my_message and my_printf_error where if they are prefered
sql/sql_map.cc:
  changing my_error on my_message and my_printf_error where if they are prefered
sql/sql_parse.cc:
  error check moved to fill_record
  changing my_error on my_message and my_printf_error where if they are prefered
sql/sql_prepare.cc:
  changing my_error on my_message and my_printf_error where if they are prefered
sql/sql_rename.cc:
  changing my_error on my_message and my_printf_error where if they are prefered
sql/sql_repl.cc:
  changing my_error on my_message and my_printf_error where if they are prefered
sql/sql_select.cc:
  changing my_error on my_message and my_printf_error where if they are prefered
sql/sql_show.cc:
  changing my_error on my_message and my_printf_error where if they are prefered
sql/sql_table.cc:
  changing my_error on my_message and my_printf_error where if they are prefered
sql/sql_trigger.cc:
  changing my_error on my_message and my_printf_error where if they are prefered
sql/sql_udf.cc:
  changing my_error on my_message and my_printf_error where if they are prefered
sql/sql_union.cc:
  error check moved to fill_record
sql/sql_update.cc:
  error check moved to fill_record
sql/sql_view.cc:
  changing my_error on my_message and my_printf_error where if they are prefered
sql/sql_yacc.yy:
  changing my_error on my_message and my_printf_error where if they are prefered
sql/table.cc:
  changing my_error on my_message and my_printf_error where if they are prefered
sql/unireg.cc:
  changing my_error on my_message and my_printf_error where if they are prefered
2004-11-12 14:34:00 +02:00
unknown
f5a47f156b Fixes after merge with 4.1
FOUND is not a reserved keyword anymore
Added Item_field::set_no_const_sub() to be able to mark fields that can't be substituted
Added 'simple_select' method to be able to quickly determinate if a select_result is a normal SELECT
Note that the 5.0 tree is not yet up to date: Sanja will have to fix multi-update-locks for this merge to be complete


BUILD/SETUP.sh:
  Portability fix
client/mysqltest.c:
  Portability fix
mysql-test/r/drop.result:
  updated results
mysql-test/r/func_str.result:
  New warnings (after merge)
mysql-test/r/insert.result:
  Updated tests
mysql-test/r/join_nested.result:
  Updated results (because of new column types in 5.0)
mysql-test/r/lock_multi.result:
  Temporarly wrong results until Sanja fixes multi-update-lock in 5.0
mysql-test/r/multi_update.result:
  Temporary fix until Sanja fixes multi-update locking
mysql-test/r/ps_1general.result:
  Update of results after merge
mysql-test/r/ps_2myisam.result:
  Update of results after merge
mysql-test/r/ps_3innodb.result:
  Update of results after merge
mysql-test/r/ps_4heap.result:
  Update of results after merge
mysql-test/r/ps_5merge.result:
  Update of results after merge
mysql-test/r/ps_6bdb.result:
  Update of results after merge
mysql-test/r/query_cache.result:
  Update of results after merge
mysql-test/r/range.result:
  New results for new tests
mysql-test/r/rpl_auto_increment.result:
  Update with new 4.0 information
mysql-test/r/rpl_charset.result:
  After merge fixes
mysql-test/r/subselect.result:
  After merge fixes
mysql-test/r/view.result:
  Temporary fix until multi-update-locking is fixed
mysql-test/t/drop.test:
  Safety fix
mysql-test/t/multi_update.test:
  Temporary fix until multi-update-locking is fixed
mysql-test/t/rpl_charset.test:
  More comments
mysql-test/t/sp-error.test:
  Updated comments
mysql-test/t/view.test:
  Temporary fix until multi-update-locking is fixed
scripts/mysql_fix_privilege_tables.sh:
  Better error message
sql-common/client.c:
  More debugging
sql/ha_ndbcluster.cc:
  After merge fixes
sql/handler.cc:
  After merge fixes
sql/item.cc:
  Simple optimization of creating item
  After merge fixed
  Added Item_field::set_no_const_sub() to be able to mark fields that can't be substituted
  The problem is that if you compare a string field to a binary string, you can't replace the field with a string constant as the binary comparison may then fail (The original field value may be in a different case)
sql/item.h:
  Added Item::set_no_const_sub() to be able to mark fields that can't be substituted
sql/item_cmpfunc.cc:
  Mark fields compared as binary to not be substituted.
sql/item_func.cc:
  After merge fix
sql/log_event.cc:
  After merge fix
sql/mysql_priv.h:
  After merge fix
sql/opt_range.cc:
  After merge fix
sql/protocol.cc:
  Made flags uint instead of int (as it's used as a bit mask)
sql/protocol.h:
  Made flags uint instead of int (as it's used as a bit mask)
sql/protocol_cursor.cc:
  Made flags uint instead of int (as it's used as a bit mask)
  Indentation cleanups
sql/sp.cc:
  After merge fixes
  Removed compiler warnings
sql/sp_head.cc:
  After merge fixes
sql/sql_base.cc:
  After merge fixes
  Removed 'send_error' from 'insert_fields()' as the error is sent higher up
sql/sql_class.cc:
  Give assert if set_n_backup_item_arena is used twice
sql/sql_class.h:
  Give assert if set_n_backup_item_arena is used twice
  After merge fixes
  Added 'simple_select' method to be able to quickly determinate if a select_result is a normal SELECT
sql/sql_handler.cc:
  After merge fixes
sql/sql_parse.cc:
  After merge fixes
sql/sql_prepare.cc:
  After merge fixes
sql/sql_select.cc:
  After merge fixes
  Moved 'build_equal_items' to optimize_cond() (logical place)
sql/sql_table.cc:
  After merge fixes
sql/sql_trigger.cc:
  After merge fixes
sql/sql_update.cc:
  After merge fixes
  (This should be fixed by Sanja to have lower granuality locking of tables in multi-update)
sql/sql_view.cc:
  After merge fixes
sql/sql_yacc.yy:
  After merge fixes
  Don't have FOUND as a reserved keyword
2004-11-03 12:39:38 +02:00
unknown
f095274fe8 merge with 4.1
BitKeeper/etc/ignore:
  auto-union
BitKeeper/etc/logging_ok:
  auto-union
BitKeeper/triggers/post-commit:
  Auto merged
Docs/Support/texi2html:
  Auto merged
Makefile.am:
  Auto merged
client/Makefile.am:
  Auto merged
client/mysql.cc:
  Auto merged
client/mysqldump.c:
  Auto merged
include/my_base.h:
  Auto merged
include/my_global.h:
  Auto merged
include/my_pthread.h:
  Auto merged
include/my_sys.h:
  Auto merged
include/my_time.h:
  Auto merged
include/mysql.h:
  Auto merged
include/mysql_com.h:
  Auto merged
innobase/buf/buf0buf.c:
  Auto merged
innobase/include/row0mysql.h:
  Auto merged
innobase/row/row0sel.c:
  Auto merged
libmysql/libmysql.c:
  Auto merged
libmysqld/examples/Makefile.am:
  Auto merged
myisam/mi_check.c:
  Auto merged
mysql-test/include/ps_modify.inc:
  Auto merged
mysql-test/install_test_db.sh:
  Auto merged
mysql-test/r/alter_table.result:
  Auto merged
mysql-test/r/auto_increment.result:
  Auto merged
mysql-test/r/bdb.result:
  Auto merged
mysql-test/r/ctype_latin1_de.result:
  Auto merged
mysql-test/r/ctype_recoding.result:
  Auto merged
mysql-test/r/fulltext.result:
  Auto merged
mysql-test/r/func_gconcat.result:
  Auto merged
mysql-test/r/func_group.result:
  Auto merged
mysql-test/r/func_if.result:
  Auto merged
mysql-test/t/derived.test:
  Auto merged
mysql-test/t/insert.test:
  merge with 4.1
  Fixed test case to not use 'if exists' when it shouldn't
mysql-test/t/range.test:
  merge with 4.1
  Added missing drop table
sql/ha_ndbcluster.cc:
  merge with 4.1
  Simple optimization: use max() instead of ? :
sql/item_func.cc:
  merge with 4.1
  (Added back old variable names for easier merges)
sql/opt_range.cc:
  merge with 4.1
  Removed argument 'parent_alloc' from QUICK_RANGE_SELECT as this was not used
  Added assert if using QUICK_GROUP_MIN_MAX_SELECT with parent_alloc as the init() function can't handle this
  Changed back get_quick_select_for_ref() to use it's own alloc root becasue this function may be called several times for one query
sql/sql_handler.cc:
  merge with 4.1
  change variable 'err' to 'error' as same function had a label named 'err'
sql/sql_update.cc:
  Use multi-update code from 5.0 instead of 4.1
  We will fix the locking code shortly in 5.0 to be faster than in 4.1
2004-10-29 19:26:52 +03:00
unknown
11ff375efd - Applied some Windows portability fixes for myisampack.c and sql_handler.cc
(backports from fixes made in 4.1)


myisam/myisampack.c:
   - replaced "1ULL" with "((ulonglong)1)" to resolve a compile error on
     Windows
sql/sql_handler.cc:
   - removed some unused variables
   - added a (byte*) cast to fix a compile error on Windows (backport of a
     fix made in 4.1)
2004-10-27 21:51:27 +02:00
unknown
0a929c5e6e Merge sanja.is.com.ua:/home/bell/mysql/bk/mysql-5.0
into sanja.is.com.ua:/home/bell/mysql/bk/work-error-5.0


mysql-test/r/sp.result:
  Auto merged
mysql-test/t/sp.test:
  Auto merged
sql/item.cc:
  Auto merged
sql/item_sum.cc:
  Auto merged
sql/mysql_priv.h:
  Auto merged
sql/sp.cc:
  Auto merged
sql/sp_head.cc:
  Auto merged
sql/sql_acl.cc:
  Auto merged
sql/sql_handler.cc:
  Auto merged
sql/sql_insert.cc:
  Auto merged
sql/sql_lex.h:
  Auto merged
sql/sql_select.cc:
  Auto merged
sql/sql_select.h:
  Auto merged
sql/sql_show.cc:
  Auto merged
sql/sql_yacc.yy:
  Auto merged
2004-10-20 16:11:16 +03:00
unknown
066c90563a errors without code removed
net_printf/send_error calls replaced by my_error family functions
-1/1 (sent/unsent) error reporting removed
(WL#2133)


include/mysqld_error.h:
  new errors added.
mysql-test/r/rpl_charset.result:
  new error
mysql-test/r/rpl_timezone.result:
  new error
mysql-test/r/sp-security.result:
  more clean error message
mysql-test/r/sp.result:
  now error state intercepted correctly
mysql-test/t/connect.test:
  new error message
mysql-test/t/rpl_charset.test:
  new error message
mysql-test/t/rpl_timezone.test:
  new error
mysql-test/t/sp-security.test:
  more correct error handling
mysql-test/t/sp.test:
  now error state intercepted correctly
sql/ha_innodb.cc:
  -1/1 (sent/unsent) error reporting removed
sql/ha_innodb.h:
  -1/1 (sent/unsent) error reporting removed
sql/item.cc:
  only boolean values should be returned by fix_fields()
sql/item_cmpfunc.cc:
  only boolean values should be returned by fix_fields()
sql/item_func.cc:
  only boolean values should be returned by fix_fields()
  net_printf/send_error calls replaced by my_error family functions
sql/item_row.cc:
  only boolean values should be returned by fix_fields()
sql/item_subselect.cc:
  only boolean values should be returned by fix_fields()
  -1/1 (sent/unsent) error reporting removed
sql/item_subselect.h:
  -1/1 (sent/unsent) error reporting removed
sql/item_sum.cc:
  only boolean values should be returned by fix_fields()
sql/item_timefunc.cc:
  only boolean values should be returned by fix_fields()
sql/item_uniq.h:
  only boolean values should be returned by fix_fields()
sql/mysql_priv.h:
  -1/1 (sent/unsent) error reporting removed
sql/mysqld.cc:
  net_printf/send_error calls replaced by my_error family functions
  changes in my_message_sql to support error handling correctly
sql/protocol.cc:
  net_printf/send_error calls replaced by my_error family functions
sql/protocol_cursor.cc:
  net_printf/send_error calls replaced by my_error family functions
sql/repl_failsafe.cc:
  net_printf/send_error calls replaced by my_error family functions
  -1/1 (sent/unsent) error reporting removed
sql/repl_failsafe.h:
  -1/1 (sent/unsent) error reporting removed
sql/set_var.cc:
  net_printf/send_error calls replaced by my_error family functions
sql/share/czech/errmsg.txt:
  new error messages
sql/share/danish/errmsg.txt:
  new error messages
sql/share/dutch/errmsg.txt:
  new error messages
sql/share/english/errmsg.txt:
  new error messages
sql/share/estonian/errmsg.txt:
  new error messages
sql/share/french/errmsg.txt:
  new error messages
sql/share/german/errmsg.txt:
  new error messages
sql/share/greek/errmsg.txt:
  new error messages
sql/share/hungarian/errmsg.txt:
  new error messages
sql/share/italian/errmsg.txt:
  new error messages
sql/share/japanese/errmsg.txt:
  new error messages
sql/share/korean/errmsg.txt:
  new error messages
sql/share/norwegian-ny/errmsg.txt:
  new error messages
sql/share/norwegian/errmsg.txt:
  new error messages
sql/share/polish/errmsg.txt:
  new error messages
sql/share/portuguese/errmsg.txt:
  new error messages
sql/share/romanian/errmsg.txt:
  new error messages
sql/share/russian/errmsg.txt:
  new error messages
sql/share/serbian/errmsg.txt:
  new error messages
sql/share/slovak/errmsg.txt:
  new error messages
sql/share/spanish/errmsg.txt:
  new error messages
sql/share/swedish/errmsg.txt:
  new error messages
sql/share/ukrainian/errmsg.txt:
  new error messages
sql/slave.cc:
  net_printf/send_error calls replaced by my_error family functions
  -1/1 (sent/unsent) error reporting removed
sql/slave.h:
  -1/1 (sent/unsent) error reporting removed
sql/sp.cc:
  net_printf/send_error calls replaced by my_error family functions
sql/sp_head.cc:
  new eror handling support
  net_printf/send_error calls replaced by my_error family functions
sql/sp_rcontext.cc:
  net_printf/send_error calls replaced by my_error family functions
sql/sql_acl.cc:
  net_printf/send_error calls replaced by my_error family functions
  -1/1 (sent/unsent) error reporting removed
sql/sql_acl.h:
  -1/1 (sent/unsent) error reporting removed
sql/sql_base.cc:
  -1/1 (sent/unsent) error reporting removed
  net_printf/send_error calls replaced by my_error family functions
sql/sql_class.cc:
  net_printf/send_error calls replaced by my_error family functions
sql/sql_class.h:
  my_messhage_sql now set/reset query_error flag
sql/sql_db.cc:
  -1/1 (sent/unsent) error reporting removed
sql/sql_delete.cc:
  -1/1 (sent/unsent) error reporting removed
  net_printf/send_error calls replaced by my_error family functions
sql/sql_do.cc:
  -1/1 (sent/unsent) error reporting removed
sql/sql_error.cc:
  -1/1 (sent/unsent) error reporting removed
sql/sql_handler.cc:
  -1/1 (sent/unsent) error reporting removed
  net_printf/send_error calls replaced by my_error family functions
sql/sql_help.cc:
  net_printf/send_error calls replaced by my_error family functions
  -1/1 (sent/unsent) error reporting removed
sql/sql_insert.cc:
  -1/1 (sent/unsent) error reporting removed
  net_printf/send_error calls replaced by my_error family functions
sql/sql_lex.h:
  -1/1 (sent/unsent) error reporting removed
sql/sql_load.cc:
  -1/1 (sent/unsent) error reporting removed
sql/sql_map.cc:
  errors without code removed
sql/sql_parse.cc:
  net_printf/send_error calls replaced by my_error family functions
  -1/1 (sent/unsent) error reporting removed from mysql_execute_command
sql/sql_prepare.cc:
  net_printf/send_error calls replaced by my_error family functions
  -1/1 (sent/unsent) error reporting removed
sql/sql_repl.cc:
  error messages fixed
  net_printf/send_error calls replaced by my_error family functions
  -1/1 (sent/unsent) error reporting removed
sql/sql_repl.h:
  -1/1 (sent/unsent) error reporting removed
sql/sql_select.cc:
  -1/1 (sent/unsent) error reporting removed
sql/sql_select.h:
  -1/1 (sent/unsent) error reporting removed
sql/sql_show.cc:
  -1/1 (sent/unsent) error reporting removed
  net_printf/send_error calls replaced by my_error family functions
sql/sql_table.cc:
  net_printf/send_error calls replaced by my_error family functions
  -1/1 (sent/unsent) error reporting removed
sql/sql_trigger.cc:
  -1/1 (sent/unsent) error reporting removed
sql/sql_udf.cc:
  net_printf/send_error calls replaced by my_error family functions
sql/sql_union.cc:
  -1/1 (sent/unsent) error reporting removed
sql/sql_update.cc:
  -1/1 (sent/unsent) error reporting removed
  net_printf/send_error calls replaced by my_error family functions
sql/sql_view.cc:
  -1/1 (sent/unsent) error reporting removed
sql/sql_view.h:
  -1/1 (sent/unsent) error reporting removed
sql/sql_yacc.yy:
  net_printf/send_error calls replaced by my_error family functions
2004-10-20 04:04:37 +03:00
unknown
fd6009accb BUG#4286 - HANDLER tables are closed by FLUSH TABLE(S).
BUG#4335 - one name can be handler open'ed many times.
Fixed problems detected on Windows build by VC++.
Removed unused variables.
Applied a neccessary cast.
2004-10-13 17:42:22 +02:00
unknown
81f7ade662 Merge with implementation of WL#1724.
sql/ha_myisam.cc:
  Auto merged
sql/handler.cc:
  Auto merged
sql/item.cc:
  Auto merged
sql/item.h:
  Auto merged
sql/item_sum.cc:
  Auto merged
sql/item_sum.h:
  Auto merged
sql/key.cc:
  Auto merged
sql/mysql_priv.h:
  Auto merged
sql/opt_sum.cc:
  Auto merged
sql/sql_acl.cc:
  Auto merged
sql/sql_handler.cc:
  Auto merged
sql/sql_insert.cc:
  Auto merged
sql/sql_select.h:
  Auto merged
sql/opt_range.cc:
  Manual merge
sql/sql_select.cc:
  Manual merge
2004-10-11 10:47:08 +03:00
unknown
9232c91d39 Merge mysql.com:/home/my/mysql-4.0 into mysql.com:/home/my/mysql-4.1
client/mysqlimport.c:
  Auto merged
myisam/mi_locking.c:
  Auto merged
sql/mysql_priv.h:
  Auto merged
sql/sql_handler.cc:
  Auto merged
2004-10-07 12:51:32 +03:00
unknown
96e7be58c8 After merge fixes
Some bigger code changes was necessary becasue of the multi-table-update and the new HANDLER code


include/hash.h:
  Added back function that's was used in 4.0
mysql-test/r/delete.result:
  Update results after merge
mysql-test/r/flush_table.result:
  Update results after merge
mysql-test/r/func_str.result:
  Update results after merge
mysql-test/r/handler.result:
  Update results after merge
  Change is big becasue in MySQL 4.1 you are not allowed to qualify the handler alias with a databasename
mysql-test/r/multi_update.result:
  More startup cleanups
mysql-test/r/rename.result:
  More startup-cleanups
mysql-test/r/select.result:
  More startup cleanups
mysql-test/r/show_check.result:
  More startup-cleanups
mysql-test/t/ctype_latin1_de.test:
  Cleanup
mysql-test/t/derived.test:
  Portability fix
mysql-test/t/handler.test:
  Update results after merge
  Change is big becasue in MySQL 4.1 you are not allowed to qualify the handler alias with a databasename
mysql-test/t/multi_update.test:
  More startup cleanups
mysql-test/t/range.test:
  More comments
mysql-test/t/rename.test:
  More startup cleanups
mysql-test/t/select.test:
  More startup cleanups
mysql-test/t/show_check.test:
  More startup cleanups
mysql-test/t/type_timestamp.test:
  Add back test deleted during merge
sql/item_cmpfunc.cc:
  After merge fixes
sql/item_func.cc:
  Remove compiler warning
sql/mysql_priv.h:
  After merge fixes
sql/mysqld.cc:
  After merge fixes
sql/sql_acl.cc:
  More debugging
sql/sql_base.cc:
  After merge fixes
  (This fix was needed bacause of multi-table-update reopens tables)
sql/sql_handler.cc:
  After merge fixes
sql/sql_lex.h:
  After merge fixes
sql/sql_select.cc:
  After merge fixes
sql/sql_show.cc:
  After merge fixes
sql/sql_table.cc:
  After merge fixes
  Simple cleanup of mysql_discard_or_import_tablespace
sql/sql_update.cc:
  After merge fixes
  Rework mysql_multi_update to take into account derived tables.
sql/sql_yacc.yy:
  After merge fixes
2004-10-07 10:50:13 +03:00
unknown
bbab9ec678 Merge with 4.0 for 4.1 release
Noteworthy:
- New HANDLER code
- New multi-update-grant-check code
- Table lock code in ha_innodb.cc was not applied


BitKeeper/etc/logging_ok:
  auto-union
BitKeeper/deleted/.del-ctype-latin1_de.c~c5d8f9208bceb98e:
  Auto merged
Build-tools/mysql-copyright-2:
  Auto merged
acinclude.m4:
  Auto merged
client/mysqladmin.c:
  Auto merged
client/mysqldump.c:
  Auto merged
include/config-win.h:
  Auto merged
include/my_global.h:
  Auto merged
include/myisam.h:
  Auto merged
innobase/btr/btr0btr.c:
  Auto merged
innobase/buf/buf0buf.c:
  Auto merged
ltmain.sh:
  Auto merged
innobase/dict/dict0dict.c:
  Auto merged
innobase/fsp/fsp0fsp.c:
  Auto merged
innobase/include/dict0dict.h:
  Auto merged
innobase/include/row0mysql.h:
  Auto merged
innobase/log/log0log.c:
  Auto merged
innobase/log/log0recv.c:
  Auto merged
innobase/pars/pars0opt.c:
  Auto merged
innobase/row/row0row.c:
  Auto merged
innobase/sync/sync0arr.c:
  Auto merged
innobase/ut/ut0dbg.c:
  Auto merged
myisam/mi_check.c:
  Auto merged
myisam/mi_close.c:
  Auto merged
myisam/mi_create.c:
  Auto merged
myisam/mi_locking.c:
  Auto merged
myisam/myisampack.c:
  Auto merged
mysql-test/r/delete.result:
  Auto merged
mysql-test/r/func_if.result:
  Auto merged
Build-tools/mysql-copyright:
  Merge with 4.0 (too most of the code from 4.0)
Makefile.am:
  merge
client/mysql.cc:
  Used 4.1 code
configure.in:
  merge
innobase/os/os0file.c:
  merge
innobase/row/row0mysql.c:
  merge
mysql-test/r/ctype_latin1_de.result:
  merge
mysql-test/r/flush_table.result:
  merge
mysql-test/r/func_str.result:
  merge
mysql-test/r/handler.result:
  merge
mysql-test/r/multi_update.result:
  merge
mysql-test/r/type_timestamp.result:
  Removed testing of 'new' mode, as this is only relevant for 4.0
mysql-test/r/update.result:
  merge
mysql-test/t/delete.test:
  merge
mysql-test/t/flush_table.test:
  merge
mysql-test/t/func_str.test:
  merge
mysql-test/t/handler.test:
  merge
mysql-test/t/multi_update.test:
  merge
mysql-test/t/type_timestamp.test:
  Removed testing of 'new' mode, as this is only relevant for 4.0
mysql-test/t/update.test:
  merge
mysys/errors.c:
  merge
mysys/my_fstream.c:
  merge
mysys/my_pread.c:
  merge
mysys/my_write.c:
  merge
mysys/mysys_priv.h:
  merge
scripts/mysqlhotcopy.sh:
  merge
sql/field.cc:
  Keep code from 4.1
sql/field.h:
  Keep code from 4.1
sql/ha_innodb.cc:
  Don't merge lock code from 4.0; Heikki will look at this
sql/ha_myisam.cc:
  merge
sql/handler.cc:
  merge
sql/item_cmpfunc.cc:
  merge
sql/item_cmpfunc.h:
  merge
sql/item_strfunc.cc:
  merge
sql/mysql_priv.h:
  merge
sql/mysqld.cc:
  merge
sql/protocol.cc:
  merge
sql/records.cc:
  merge
sql/repl_failsafe.cc:
  merge
mysql-test/r/lock_multi.result:
  merge
mysql-test/t/ctype_latin1_de.test:
  merge
mysql-test/t/func_if.test:
  merge
mysql-test/t/lock_multi.test:
  merge
sql/repl_failsafe.h:
  merge
  Remove unnessessary header protection
sql/slave.h:
  merge
sql/sql_acl.cc:
  merge
sql/sql_base.cc:
  merge
sql/sql_cache.cc:
  auto merge
sql/sql_class.cc:
  merge
sql/sql_class.h:
  merge
sql/sql_delete.cc:
  merge
sql/sql_handler.cc:
  Get new HANDLER code into 4.1
sql/sql_parse.cc:
  Keep old file
sql/sql_repl.cc:
  merge
sql/sql_repl.h:
  merge
sql/sql_show.cc:
  merge
sql/sql_table.cc:
  merge
sql/sql_union.cc:
  Applied the examine_rows bug fix from 4.0 by hand
sql/sql_update.cc:
  New multi-update-grant-check code from 4.0
sql/sql_yacc.yy:
  New multi-update-grant-check code from 4.0
sql/stacktrace.c:
  merge
sql/table.h:
  merge
2004-10-06 19:14:33 +03:00
unknown
fe46310640 Code cleanups while doing review of pushed code
myisam/mi_locking.c:
  More comments
sql/mysql_priv.h:
  Change mode to uint (as it's a bitmap)
sql/sql_handler.cc:
  Change mode to uint (as it's a bitmap)
  Fixed DBUG_PRINT to use same format as other MySQL code
2004-10-06 17:20:39 +03:00
unknown
697cb7b106 BUG#4286 - HANDLER tables are closed by FLUSH TABLE(S).
BUG#4335 - one name can be handler open'ed many times.
Reworked the HANDLER functions and interface.
Using a HASH to store information on open tables that
survives FLUSH TABLE.
HANDLER tables alias names must now be unique, though it
is allowed in 4.0 to qualify them with the database name
of the base table.


mysql-test/r/flush_table.result:
  BUG#4286 - HANDLER tables are closed by FLUSH TABLE(S).
  BUG#4335 - one name can be handler open'ed many times.
  Moved pure handler test results to handler.result.
  Added the new test results.
mysql-test/r/handler.result:
  BUG#4286 - HANDLER tables are closed by FLUSH TABLE(S).
  BUG#4335 - one name can be handler open'ed many times.
  Moved pure handler test results from flush_table.result to here.
mysql-test/t/flush_table.test:
  BUG#4286 - HANDLER tables are closed by FLUSH TABLE(S).
  BUG#4335 - one name can be handler open'ed many times.
  Moved pure handler tests to handler.test.
  Added new tests.
mysql-test/t/handler.test:
  BUG#4286 - HANDLER tables are closed by FLUSH TABLE(S).
  BUG#4335 - one name can be handler open'ed many times.
  Moved pure handler tests from flush_table.test to here.
sql/mysql_priv.h:
  BUG#4286 - HANDLER tables are closed by FLUSH TABLE(S).
  BUG#4335 - one name can be handler open'ed many times.
  Reworked the handler interface.
sql/sql_base.cc:
  BUG#4286 - HANDLER tables are closed by FLUSH TABLE(S).
  BUG#4335 - one name can be handler open'ed many times.
  Replaced mysql_ha_close_list() by the better named
  function mysql_ha_flush() with readable options.
sql/sql_class.cc:
  BUG#4286 - HANDLER tables are closed by FLUSH TABLE(S).
  BUG#4335 - one name can be handler open'ed many times.
  Added initialization for the handler tables hash.
  Changed the handler tables clean-up code.
  Unreleted to bug: Changed the order of THD initialization
  to avoid warning messages on Linux with gcc.
sql/sql_class.h:
  BUG#4286 - HANDLER tables are closed by FLUSH TABLE(S).
  BUG#4335 - one name can be handler open'ed many times.
  Added the handler tables HASH to THD.
sql/sql_handler.cc:
  BUG#4286 - HANDLER tables are closed by FLUSH TABLE(S).
  BUG#4335 - one name can be handler open'ed many times.
  Completely reworked the handler functions.
  Added an introducing comment, describing the new functionality.
sql/sql_table.cc:
  BUG#4286 - HANDLER tables are closed by FLUSH TABLE(S).
  BUG#4335 - one name can be handler open'ed many times.
  replaced mysql_ha_close() by the better named
  function mysql_ha_flush() with readable options.
2004-09-24 18:39:25 +02:00
unknown
0650a2840e Merge
sql/sql_handler.cc:
  Auto merged
mysql-test/r/view.result:
  SCCS merged
mysql-test/t/view.test:
  SCCS merged
2004-09-10 14:01:02 +03:00
unknown
b386f888da post merge fixes
mysql-test/t/merge.test:
  additional test
sql/item.h:
  parameter to detect need of saving view field names
sql/item_subselect.cc:
  arena fix
  used nearest thd pointer
sql/item_sum.cc:
  after merge fix
sql/mysql_priv.h:
  after merge fix
sql/sql_base.cc:
  fixed unique test
  fixed postmerge arena mamgement
sql/sql_class.h:
  mey method to detect conventional execution
sql/sql_handler.cc:
  new parameter
sql/sql_lex.cc:
  fixed postmerge arena mamgement
sql/sql_parse.cc:
  fixed unique test
sql/sql_select.cc:
  fixed postmerge arena mamgement
sql/sql_union.cc:
  fixed postmerge arena mamgement
sql/sql_view.cc:
  fixed postmerge arena mamgement
sql/table.cc:
  fixed postmerge arena mamgement
2004-09-10 02:22:44 +03:00
unknown
6e0b468f18 requre BASE TABLE for HANDLER (BUG#5277)
mysql-test/r/view.result:
  HANDLER with VIEW
mysql-test/t/view.test:
  HANDLER with VIEW
sql/sql_handler.cc:
  requre BASE TABLE for HANDLER
2004-09-07 10:42:23 +03:00
unknown
d945033292 WL#1724 "Min/Max Optimization for Queries with Group By Clause"
- after-review changes
- merged with the source tree from 204-08-27


mysql-test/r/distinct.result:
  Different plans due to group-by optimization.
sql/ha_myisam.cc:
  More general interface to key_copy.
sql/handler.cc:
  More general interface to key_copy.
sql/item.cc:
  New method to collect all Item_field objects. Used by Item::walk.
sql/item.h:
  Several methods to collect different kinds of items from expression trees.
  Used by Item::walk.
sql/item_sum.cc:
  Added helper to collect Item_sum objects.
sql/item_sum.h:
  Methods to collect and test Item_sum objects.
sql/key.cc:
  More general interface to key_copy and key_restore.
sql/mysql_priv.h:
  More general interface to key_copy and key_restore.
sql/opt_range.cc:
  Complete implementaion of WL#1724 "Min/Max Optimization for Queries with Group By Clause".
sql/opt_range.h:
  Complete implementaion of WL#1724 "Min/Max Optimization for Queries with Group By Clause".
sql/opt_sum.cc:
  simple_pred is re-used in opt_range.cc
sql/sql_acl.cc:
  More general interface to key_copy and key_restore.
sql/sql_handler.cc:
  More general interface to key_copy.
sql/sql_insert.cc:
  More general interface to key_copy.
sql/sql_select.cc:
  Changes to hook the new QUICK_GROUP_MIN_MAX_SELECT due to two differences from all other
  quick selects:
  1)
  This quick select may be created (and used) even if there is no WHERE clause.
  Several places assumed that a QUICK_SELECT is constructed only if there is a WHERE clause,
  which had to be changed so that QUICK_GROUP_MIN_MAX can be used.
  2)
  Unlike all other quick selects, this QUICK_GROUP_MIN_MAX_SELECT operates for GROUP BY queries.
  Since for the caller the quick select already produces one result tuple per group, there is
  no need to call end_send_group, instead we have to call end_send as for a regular quick select.
sql/sql_select.h:
  simple_pred is re-used in opt_range.cc
2004-08-27 16:37:13 +03:00
unknown
eaf34dd8e3 Port of cursors to be pushed into 5.0 tree:
- client side part is simple and may be considered stable
- server side part now just joggles with THD state to save execution
  state and has no additional locking wisdom.
  Lot's of it are to be rewritten.


include/mysql.h:
  Cursor patch to push into the main tree, client library part (considered 
  stable):
  - new statement attribute STMT_ATTR_CURSOR_TYPE
  - MYSQL_STMT::flags to store statement cursor type
  - MYSQL_STMT::server_status to store server status (i. e. if the server
  was able to open a cursor for this query).
include/mysql_com.h:
  Cursor patch to push into the main tree, client library part (considered 
  stable):
  - new COMmand, COM_FETCH, to fetch K rows from read-only cursor.
    By design should support scrollable cursors as well.
  - a few new server statuses:
    SERVER_STATUS_CURSOR_EXISTS is sent by server in reply to COM_EXECUTE,
    when cursor was successfully opened for this query
    SERVER_STATUS_LAST_ROW_SENT is sent along with the last row to prevent one
    more round trip just for finding out that all rows were fetched from 
    this cursor (this is server mem savier also).
  - and finally, all possible values of STMT_ATTR_CURSOR_TYPE, 
    while now we support only CURSORT_TYPE_NO_CURSOR and 
    CURSOR_TYPE_READ_ONLY
libmysql/libmysql.c:
  Cursor patch to push into the main tree, client library part (considered 
  stable):
  - simple additions to mysql_stmt_fetch implementation to read data 
    from an opened cursor: we can read up to iteration count rows per
    one request; read rows are buffered in the same way as rows of
    mysql_stmt_store_result.
  - now send stmt->flags to server to let him now if we wish to have 
    a cursor for this statement.
  - support for setting/getting statement cursor type.
libmysqld/examples/Makefile.am:
  Testing cursors was originally implemented in C++. Now when these tests
  go into client_test, it's time to convert it to C++ as well.
libmysqld/lib_sql.cc:
  - cleanup: send_fields flags are now named.
sql/ha_innodb.cc:
  - cleanup: send_fields flags are now named.
sql/mysql_priv.h:
  - cursors support: declaration for server-side handler of COM_FETCH
sql/protocol.cc:
  - cleanup: send_fields flags are now named.
  - we can't anymore assert that field_types[field_pos] is sensible:
    if we have COM_EXCUTE(stmt1), COM_EXECUTE(stmt2), COM_FETCH(stmt1)
    field_types[field_pos] will point to fields of stmt2.
sql/protocol.h:
  - cleanup: send_fields flag_s_ are now named.
sql/protocol_cursor.cc:
  - cleanup: send_fields flags are now named.
sql/repl_failsafe.cc:
  - cleanup: send_fields flags are now named.
sql/slave.cc:
  - cleanup: send_fields flags are now named.
sql/sp.cc:
  - cleanup: send_fields flags are now named.
sql/sp_head.cc:
  - cleanup: send_fields flags are now named.
sql/sql_acl.cc:
  - cleanup: send_fields flags are now named.
sql/sql_class.cc:
  - cleanup: send_fields flags are now named.
sql/sql_class.h:
  - cleanup: send_fields flags are now named.
sql/sql_error.cc:
  - cleanup: send_fields flags are now named.
sql/sql_handler.cc:
  - cleanup: send_fields flags are now named.
sql/sql_help.cc:
  - cleanup: send_fields flags are now named.
sql/sql_parse.cc:
  Server side support for cursors:
  - handle COM_FETCH
  - enforce assumption that whenever we free thd->free_list, 
    we reset it to zero. This way it's much easier to handle free_list
    in prepared statements implementation.
sql/sql_prepare.cc:
  Server side support for cursors:
  - implementation of mysql_stmt_fetch (fetch some rows from open cursor).
  - management of cursors memory is quite tricky now.
  - execute_stmt can't be reused anymore in mysql_stmt_execute and 
    mysql_sql_stmt_execute
sql/sql_repl.cc:
  - cleanup: send_fields flags are now named.
sql/sql_select.cc:
  Server side support for cursors:
  - implementation of Cursor::open, Cursor::fetch (buggy when it comes to
    non-equi joins), cursor cleanups.
  - -4 -3 -0 constants indicating return value of sub_select and end_send are
    to be renamed to something more readable:
    it turned out to be not so simple, so it should come with the other patch.
sql/sql_select.h:
  Server side support for cursors:
  - declaration of Cursor class.
  - JOIN::fetch_limit contains runtime value of rows fetched via cursor.
sql/sql_show.cc:
  - cleanup: send_fields flags are now named.
sql/sql_table.cc:
  - cleanup: send_fields flags are now named.
sql/sql_union.cc:
  - if there was a cursor, don't cleanup unit: we'll need it to fetch
    the rest of the rows.
tests/Makefile.am:
  Now client_test is in C++.
tests/client_test.cc:
  A few elementary tests for cursors.
BitKeeper/etc/ignore:
  Added libmysqld/examples/client_test.cc to the ignore list
2004-08-03 03:32:21 -07:00
unknown
8790b1e65c VIEW
two TABLE_LIST copy eliminated


include/mysqld_error.h:
  errors of view
libmysqld/Makefile.am:
  new view file
mysql-test/r/connect.result:
  SHOW TABLE show type of table
mysql-test/r/ctype_recoding.result:
  SHOW TABLE show type of table
mysql-test/r/drop.result:
  SHOW TABLE show type of table
mysql-test/r/grant.result:
  new two privileges (CRETEA|SHOW VIEW)
mysql-test/r/lowercase_table.result:
  SHOW TABLE show type of table
mysql-test/r/ps_1general.result:
  SHOW TABLE show type of table
mysql-test/r/rename.result:
  SHOW TABLE show type of table
mysql-test/r/rpl000009.result:
  SHOW TABLE show type of table
mysql-test/r/rpl_error_ignored_table.result:
  SHOW TABLE show type of table
mysql-test/r/select.result:
  SHOW TABLE show type of table
mysql-test/r/system_mysql_db.result:
  SHOW TABLE show type of table
  new two privileges (CRETEA|SHOW VIEW)
mysql-test/t/system_mysql_db_fix.test:
  removing all system tables
scripts/mysql_fix_privilege_tables.sql:
  new two privileges (CRETEA|SHOW VIEW)
sql/Makefile.am:
  new VIEW related file
sql/ha_myisammrg.cc:
  two TABLE_LIST copy eliminated
sql/item.cc:
  VIEW
sql/item.h:
  VIEW
sql/item_subselect.cc:
  VIEW
sql/item_subselect.h:
  VIEW
sql/lex.h:
  VIEW
sql/lock.cc:
  VIEW
sql/mysql_priv.h:
  VIEW
sql/mysqld.cc:
  VIEW
  new parameter - sql_updatable_view_key
sql/opt_sum.cc:
  two TABLE_LIST copy eliminated
sql/set_var.cc:
  new parameter - sql_updatable_view_key
sql/share/czech/errmsg.txt:
  errors messages of views
sql/share/danish/errmsg.txt:
  errors messages of views
sql/share/dutch/errmsg.txt:
  errors messages of views
sql/share/english/errmsg.txt:
  errors messages of views
sql/share/estonian/errmsg.txt:
  errors messages of views
sql/share/french/errmsg.txt:
  errors messages of views
sql/share/german/errmsg.txt:
  errors messages of views
sql/share/greek/errmsg.txt:
  errors messages of views
sql/share/hungarian/errmsg.txt:
  errors messages of views
sql/share/italian/errmsg.txt:
  errors messages of views
sql/share/japanese/errmsg.txt:
  errors messages of views
sql/share/korean/errmsg.txt:
  errors messages of views
sql/share/norwegian-ny/errmsg.txt:
  errors messages of views
sql/share/norwegian/errmsg.txt:
  errors messages of views
sql/share/polish/errmsg.txt:
  errors messages of views
sql/share/portuguese/errmsg.txt:
  errors messages of views
sql/share/romanian/errmsg.txt:
  errors messages of views
sql/share/russian/errmsg.txt:
  errors messages of views
sql/share/serbian/errmsg.txt:
  errors messages of views
sql/share/slovak/errmsg.txt:
  errors messages of views
sql/share/spanish/errmsg.txt:
  errors messages of views
sql/share/swedish/errmsg.txt:
  errors messages of views
sql/share/ukrainian/errmsg.txt:
  errors messages of views
sql/slave.cc:
  two TABLE_LIST copy eliminated
sql/sp.cc:
  VIEW
sql/sql_acl.cc:
  VIEW
sql/sql_acl.h:
  VIEW
sql/sql_base.cc:
  VIEW
sql/sql_cache.cc:
  two TABLE_LIST copy eliminated
sql/sql_class.h:
  VIEW
sql/sql_db.cc:
  two TABLE_LIST copy eliminated
sql/sql_delete.cc:
  VIEW
sql/sql_derived.cc:
  VIEW
sql/sql_handler.cc:
  two TABLE_LIST copy eliminated
sql/sql_help.cc:
  two TABLE_LIST copy eliminated
sql/sql_insert.cc:
  VIEW
sql/sql_lex.cc:
  VIEW
sql/sql_lex.h:
  VIEW
sql/sql_load.cc:
  VIEW
sql/sql_olap.cc:
  VIEW
sql/sql_parse.cc:
  two TABLE_LIST copy eliminated
  VIEW
sql/sql_prepare.cc:
  VIEW
sql/sql_rename.cc:
  two TABLE_LIST copy eliminated
sql/sql_select.cc:
  VIEW
sql/sql_show.cc:
  VIEW
sql/sql_table.cc:
  VIEW
sql/sql_union.cc:
  VIEW
sql/sql_update.cc:
  VIEW
sql/sql_yacc.yy:
  VIEW
sql/table.cc:
  VIEW
sql/table.h:
  VIEW
sql/tztime.cc:
  two TABLE_LIST copy eliminated
sql/unireg.h:
  VIEW
tests/client_test.c:
  VIEW
2004-07-16 01:15:55 +03:00
unknown
46ea874fb7 After merge fixes
Note: The following tests fails
- fulltext (Sergei has promised to fix)
- rpl_charset (Guilhem should fix)
- rpl_timezone (Dimitray has promised to fix)

Sanja needs to check out the calling of close_thread_tables() in sp_head.cc


myisam/mi_check.c:
  After merge fix
myisam/sort.c:
  After merge fix
mysql-test/mysql-test-run.sh:
  Export master socket to mysqltest
mysql-test/r/func_group.result:
  Make result repeatable
mysql-test/r/mysqlbinlog.result:
  After merge fix
mysql-test/r/ps_1general.result:
  After merge fix
mysql-test/r/ps_2myisam.result:
  After merge fix
mysql-test/r/ps_3innodb.result:
  After merge fix
mysql-test/r/ps_4heap.result:
  After merge fix
mysql-test/r/ps_5merge.result:
  After merge fix
mysql-test/r/ps_6bdb.result:
  After merge fix
mysql-test/r/rpl_flush_log_loop.result:
  After merge fix
mysql-test/r/rpl_replicate_do.result:
  After merge fix
mysql-test/r/rpl_temporary.result:
  After merge fix
mysql-test/r/rpl_timezone.result:
  After merge fix
  Note that this test fails now (Dimitry has promised to fix this)
mysql-test/r/rpl_user_variables.result:
  After merge fix
mysql-test/r/select.result:
  After merge fix
mysql-test/r/sp-error.result:
  After merge fix
mysql-test/r/sp-security.result:
  After merge fix
mysql-test/r/sp.result:
  After merge fix
mysql-test/r/user_var.result:
  After merge fix
mysql-test/r/variables.result:
  After merge fix
mysql-test/t/alter_table.test:
  After merge fix
mysql-test/t/derived.test:
  After merge fix
mysql-test/t/func_group.test:
  Make result repeatable
mysql-test/t/grant_cache.test:
  Use MASTER_MYSOCK instead of master.sock
mysql-test/t/multi_update.test:
  Use MASTER_MYSOCK instead of master.sock
mysql-test/t/rpl000015.test:
  Use MASTER_MYSOCK instead of master.sock
mysql-test/t/rpl000017.test:
  Use MASTER_MYSOCK instead of master.sock
mysql-test/t/rpl000018.test:
  Use MASTER_MYSOCK instead of master.sock
mysql-test/t/rpl_charset.test:
  After merge fix
mysql-test/t/rpl_heap.test:
  Use MASTER_MYSOCK instead of master.sock
mysql-test/t/rpl_rotate_logs.test:
  Use MASTER_MYSOCK instead of master.sock
mysql-test/t/sp-error.test:
  after merge fix
mysql-test/t/sp-security.test:
  after merge fix
mysql-test/t/user_var.test:
  after merge fix
scripts/mysql_fix_privilege_tables.sh:
  This can now be exectued from the source distribution
sql/handler.cc:
  Cleanup
sql/handler.h:
  More debugging
sql/item.h:
  Indentation fixes
sql/item_cmpfunc.cc:
  After merge fixes
sql/opt_range.cc:
  After merge fixes
sql/opt_range.h:
  After merge fixes
sql/sp.cc:
  After merge fixes
sql/sp_head.cc:
  Remove closing of thread tables in a SP function as this caused a core dump.
  (Has to be fixed better)
sql/sql_base.cc:
  More debugging
sql/sql_handler.cc:
  After merge fixes
  (We have to call ha_index_or_rnd_end() before calling close_thread_table())
sql/sql_parse.cc:
  More debugging
sql/sql_prepare.cc:
  After merge fixes
sql/sql_select.cc:
  After merge fixes
2004-07-15 04:19:07 +03:00
unknown
ba8ffc50a9 After merge fixes
include/mysql.h:
  Cleanup
sql-common/client.c:
  Allow client.c to compile after changes to mysql.h
sql/opt_range.cc:
  Make bdb.test repeatable (and assume that table scans is a little bit slower)
sql/sql_handler.cc:
  Fixed typo during merge
sql/sql_insert.cc:
  Fixed indentation
2004-06-25 21:56:23 +03:00
unknown
c6e23c8549 Merge with 4.0 to get the latest bug patches to 4.1
BitKeeper/etc/ignore:
  added sql/mysql_tzinfo_to_sql
BitKeeper/etc/logging_ok:
  auto-union
acinclude.m4:
  Auto merged
extra/perror.c:
  Auto merged
include/mysql.h:
  Auto merged
innobase/include/mach0data.ic:
  Auto merged
innobase/include/mtr0log.h:
  Auto merged
innobase/include/mtr0log.ic:
  Auto merged
innobase/mem/mem0dbg.c:
  Auto merged
innobase/pars/lexyy.c:
  Auto merged
BitKeeper/deleted/.del-4.0.XX-gpl.ipr~f5909a9e9bd8094:
  Auto merged
BitKeeper/deleted/.del-Clients and Tools.fgl~bf0f776883577f02:
  Auto merged
BitKeeper/deleted/.del-Development.fgl~6392ce285e73f5fc:
  Auto merged
mysql-test/mysql-test-run.sh:
  Auto merged
mysql-test/r/innodb_cache.result:
  Auto merged
mysql-test/r/lowercase_table2.result:
  Auto merged
mysql-test/t/innodb_cache.test:
  Auto merged
mysql-test/t/lowercase_table2.test:
  Auto merged
sql/ha_berkeley.cc:
  Auto merged
sql/handler.cc:
  Auto merged
scripts/make_win_src_distribution.sh:
  Auto merged
sql/sql_base.cc:
  Auto merged
sql/sql_parse.cc:
  Auto merged
sql/sql_yacc.yy:
  Auto merged
libmysql/libmysql.c:
  Merge with 4.0
mysql-test/r/bdb.result:
  Merge with 4.0
mysql-test/r/range.result:
  Merge with 4.0
mysql-test/t/bdb.test:
  Merge with 4.0
mysys/hash.c:
  Merge with 4.0
scripts/mysql_install_db.sh:
  Merge with 4.0
sql/field.cc:
  Merge with 4.0
sql/field.h:
  Merge with 4.0
sql/mysql_priv.h:
  Merge with 4.0
sql/sql_handler.cc:
  Merge with 4.0
sql/sql_select.cc:
  Merge with 4.0
sql/sql_table.cc:
  Merge with 4.0
2004-06-25 20:13:05 +03:00
unknown
8f6664c59a bug#3565 - HANDLER and FLUSH TABLE/TABLES deadlock.
Redesigned the handler close functions so that they are usable
at different places where waiting for closing tables is done.


mysql-test/r/flush_table.result:
  bug#3565 - HANDLER and FLUSH TABLE/TABLES deadlock.
  Added the test results.
mysql-test/t/flush_table.test:
  bug#3565 - HANDLER and FLUSH TABLE/TABLES deadlock.
  Activated old test case.
  Added new test cases.
sql/mysql_priv.h:
  bug#3565 - HANDLER and FLUSH TABLE/TABLES deadlock.
  Made mysql_ha_close() more flexible.
  Removed mysql_ha_closeall(), which closed only one table despite its name.
  Added mysql_ha_close_list(), which closes the complete list or all tables and does not lock.
  Removed a duplicate declaration.
sql/sql_base.cc:
  bug#3565 - HANDLER and FLUSH TABLE/TABLES deadlock.
  Added proper close calls before some wait points to avoid deadlocks
  or infinite loops.
sql/sql_handler.cc:
  bug#3565 - HANDLER and FLUSH TABLE/TABLES deadlock.
  Redesigned the internal function find_table_ptr_by_name().
  It can now suppress locking and tells if the requested table
  has been flushed by itself.
  Extended mysql_ha_close() so that it can now suppres locking
  and error reporting. That way it can be used at more places and the
  old function mysql_ha_closeall() is now obsolete.
  Added a new function mysql_ha_close_list() which closes a whole list
  of HANDLER tables or all HANDLER tables, if the list is NULL.
  Furthermore is can close all 'old' (marked for flush) HANDLER tables.
sql/sql_table.cc:
  bug#3565 - HANDLER and FLUSH TABLE/TABLES deadlock.
  Replaced the obsolte mysql_ha_closeall() by the new mysql_ha_close().
2004-06-24 15:06:56 +02:00
unknown
9a554b4751 handler interface cleanups:
more logical table/index_flags
  return  HA_ERR_WRONG_COMMAND instead of abstract methods where appropriate
  max_keys and other limits renamed to max_supported_keys/etc
  max_keys/etc are now wrappers to max_supported_keys/etc 
  ha_index_init/ha_rnd_init/ha_index_end/ha_rnd_end are now wrappers to real {index,rnd}_{init,end} to enforce strict pairing


include/myisam.h:
  increasing myisam_max_temp_file_length
include/my_base.h:
  handler interface cleanup
myisam/mi_static.c:
  warning removed
mysql-test/Makefile.am:
  followup
mysql-test/r/fulltext.result:
  fulltext indexes are not ordered
mysql-test/r/rpl_user_variables.result:
  followup
sql/field.cc:
  index_flags
sql/filesort.cc:
  rnd_init -> ha_rnd_init
  rnd_end -> ha_rnd_end
sql/ha_berkeley.cc:
  cleanup
sql/ha_berkeley.h:
  table/index_flags revamped
sql/ha_heap.cc:
  ensure index is accessed only after index_init (esp. important for temp tables)
sql/ha_heap.h:
  table/index_flags revamped
sql/ha_innodb.cc:
  don't workaround MySQL sloppiness
sql/ha_innodb.h:
  table/index_flags revamped
sql/ha_isam.h:
  table/index_flags revamped
sql/ha_isammrg.h:
  table/index_flags revamped
sql/ha_myisam.cc:
  ensure index is accessed only after index_init (esp. important for temp tables)
sql/ha_myisam.h:
  table/index_flags revamped
sql/ha_myisammrg.h:
  table/index_flags revamped
sql/handler.cc:
  handler interface cleanups
sql/handler.h:
  handler interface cleanups:
    more logical table/index_flags
    return  HA_ERR_WRONG_COMMAND instead of abstract methods
    max_keys and other limits renamed to max_supported_keys/etc
    max_keys/etc are now wrappers to max_supported_keys/etc 
    ha_index_init/ha_rnd_init/ha_index_end/ha_rnd_end are now wrappers to enforce strict pairing
sql/item_subselect.cc:
  index_init/index_end/rnd_init/rnd_end strict pairing fixed
sql/lex.h:
  renamed to avoid conflicts
sql/opt_range.cc:
  index_init/index_end/rnd_init/rnd_end strict pairing fixed
  table/index_flags cleanup
sql/opt_range.h:
  index_init/index_end/rnd_init/rnd_end strict pairing fixed
sql/opt_sum.cc:
  index_init/index_end/rnd_init/rnd_end strict pairing fixed
  table/index_flags cleanup
sql/records.cc:
  index_init/index_end/rnd_init/rnd_end strict pairing fixed
sql/sql_acl.cc:
  index_init/index_end/rnd_init/rnd_end strict pairing fixed
sql/sql_cache.cc:
  cleanup
sql/sql_delete.cc:
  index_init/index_end/rnd_init/rnd_end strict pairing fixed
sql/sql_handler.cc:
  index_init/index_end/rnd_init/rnd_end strict pairing fixed
sql/sql_help.cc:
  index_init/index_end/rnd_init/rnd_end strict pairing fixed
sql/sql_insert.cc:
  table/index_flags cleanup
sql/sql_select.cc:
  index_init/index_end/rnd_init/rnd_end strict pairing fixed
  table/index_flags cleanup
sql/sql_table.cc:
  index_init/index_end/rnd_init/rnd_end strict pairing fixed
  table/index_flags cleanup
sql/sql_update.cc:
  index_init/index_end/rnd_init/rnd_end strict pairing fixed
sql/sql_yacc.yy:
  INDEX -> INDEX_SYM
sql/table.cc:
  table/index_flags cleanup
2004-06-23 12:29:05 +02:00
unknown
1d9fbbe3ce Merge with 4.0, mainly to get changes to windows project files
VC++Files/client/mysqladmin.dsp:
  Auto merged
VC++Files/client/mysqldump.dsp:
  Auto merged
VC++Files/client/mysqlimport.dsp:
  Auto merged
VC++Files/client/mysqlshow.dsp:
  Auto merged
VC++Files/dbug/dbug.dsp:
  Auto merged
VC++Files/heap/heap.dsp:
  Auto merged
VC++Files/innobase/innobase.dsp:
  Auto merged
VC++Files/isam/isam.dsp:
  Auto merged
VC++Files/isamchk/isamchk.dsp:
  Auto merged
VC++Files/libmysql/libmysql.dsp:
  Auto merged
VC++Files/mysql.dsw:
  Auto merged
BitKeeper/deleted/.del-sync0ipm.ic~2024167f6418de39:
  Auto merged
VC++Files/libmysqltest/myTest.dsp:
  Auto merged
VC++Files/merge/merge.dsp:
  Auto merged
VC++Files/my_print_defaults/my_print_defaults.dsp:
  Auto merged
VC++Files/myisam/myisam.dsp:
  Auto merged
VC++Files/myisam_ftdump/myisam_ftdump.dsp:
  Auto merged
VC++Files/myisammrg/myisammrg.dsp:
  Auto merged
VC++Files/mysqlbinlog/mysqlbinlog.dsp:
  Auto merged
VC++Files/mysqlcheck/mysqlcheck.dsp:
  Auto merged
VC++Files/mysqlshutdown/mysqlshutdown.dsp:
  Auto merged
VC++Files/mysqlwatch/mysqlwatch.dsp:
  Auto merged
VC++Files/mysys/mysys.dsp:
  Auto merged
VC++Files/pack_isam/pack_isam.dsp:
  Auto merged
VC++Files/perror/perror.dsp:
  Auto merged
VC++Files/regex/regex.dsp:
  Auto merged
VC++Files/replace/replace.dsp:
  Auto merged
VC++Files/test1/test1.dsp:
  Auto merged
VC++Files/thr_test/thr_test.dsp:
  Auto merged
VC++Files/vio/vio.dsp:
  Auto merged
VC++Files/zlib/zlib.dsp:
  Auto merged
extra/my_print_defaults.c:
  Auto merged
include/m_string.h:
  Auto merged
include/mysql_embed.h:
  Auto merged
include/mysql_version.h.in:
  Auto merged
innobase/dict/dict0dict.c:
  Auto merged
innobase/mem/mem0pool.c:
  Auto merged
innobase/srv/srv0srv.c:
  Auto merged
innobase/trx/trx0sys.c:
  Auto merged
myisam/myisam_ftdump.c:
  Auto merged
VC++Files/bdb/bdb.dsp:
  Merge with 4.0
VC++Files/client/mysql.dsp:
  Merge with 4.0
VC++Files/client/mysqlclient.dsp:
  Merge with 4.0
VC++Files/comp_err/comp_err.dsp:
  Merge with 4.0
VC++Files/libmysqld/examples/test_libmysqld.dsp:
  Merge with 4.0
VC++Files/libmysqld/libmysqld.dsp:
  Merge with 4.0
VC++Files/myisamchk/myisamchk.dsp:
  Merge with 4.0
VC++Files/myisamlog/myisamlog.dsp:
  Merge with 4.0
VC++Files/myisampack/myisampack.dsp:
  Merge with 4.0
VC++Files/mysqldemb/mysqldemb.dsp:
  Merge with 4.0
VC++Files/mysqlserver/mysqlserver.dsp:
  Merge with 4.0
VC++Files/sql/mysqld.dsp:
  Merge with 4.0
VC++Files/strings/strings.dsp:
  Merge with 4.0
libmysqld/lib_sql.cc:
  Merge with 4.0
libmysqld/libmysqld.def:
  Merge with 4.0
mysql-test/r/func_str.result:
  Merge with 4.0
mysql-test/r/handler.result:
  auto
mysql-test/r/variables.result:
  Merge with 4.0
mysql-test/t/func_str.test:
  auto
mysql-test/t/handler.test:
  auto
mysql-test/t/variables.test:
  Merge with 4.0
scripts/make_win_src_distribution.sh:
  auto
scripts/mysql_install_db.sh:
  Use original file
sql/Makefile.am:
  Merge with 4.0
sql/ha_innodb.cc:
  auto
sql/item_strfunc.cc:
  Merge with 4.0
sql/mysql_priv.h:
  auto
sql/mysqld.cc:
  Merge with 4.0
sql/set_var.cc:
  Merge with 4.0
sql/slave.cc:
  auto
sql/sql_class.h:
  auto
sql/sql_handler.cc:
  Merge with 4.0
strings/ctype-tis620.c:
  Merge with 4.0
2004-05-20 00:54:52 +03:00