Commit graph

660 commits

Author SHA1 Message Date
unknown
6a60accef2 don't let bugfix for bug#8303 break the bugfix for bug#8378
revert the fix for bug#8303
correct the test for bug#8378


mysql-test/r/ctype_sjis.result:
  updated
mysql-test/t/ctype_sjis.test:
  updated
sql/sql_lex.cc:
  revert the fix for bug#8303
tests/mysql_client_test.c:
  correct the test for bug#8378
2006-05-24 00:55:53 +02:00
unknown
375749b8af Fixed bug #14927.
A query with a group by and having clauses could return a wrong
result set if the having condition contained a constant conjunct 
evaluated to FALSE.
It happened because the pushdown condition for table with
grouping columns lost its constant conjuncts.
Pushdown conditions are always built by the function make_cond_for_table
that ignores constant conjuncts. This is apparently not correct when
constant false conjuncts are present.



mysql-test/r/having.result:
  Added a test case for bug #14927.
mysql-test/t/having.test:
  Added a test case for bug #14927.
sql/sql_lex.cc:
  Fixed bug #14927.
  Initialized fields for having conditions in  st_select_lex::init_query().
sql/sql_lex.h:
  Fixed bug #14927.
  Added a field to restore having condititions for execution in SP and PS.
sql/sql_prepare.cc:
  Fixed bug #14927.
  Added code to restore havinf conditions for execution in SP and PS.
sql/sql_select.cc:
  Fixed bug #14927.
  Performed evaluation of constant expressions in having clauses.
  If the having condition contains a constant conjunct that is always false
  an empty result set is returned after the optimization phase.
  In this case the corresponding EXPLAIN command now returns 
  "Impossible HAVING" in the last column.
2006-05-06 23:48:13 -07:00
unknown
edfc33bed0 Merge mysql.com:/home/my/mysql-5.0
into  mysql.com:/home/my/mysql-5.1


mysql-test/lib/mtr_report.pl:
  Auto merged
mysql-test/mysql-test-run.sh:
  Auto merged
mysql-test/r/subselect.result:
  Auto merged
sql/mysql_priv.h:
  Auto merged
sql/sql_select.cc:
  Auto merged
sql/sql_test.cc:
  Auto merged
sql/sql_view.cc:
  Auto merged
sql/sql_lex.cc:
  manual merge
2006-05-04 22:27:12 +03:00
unknown
afe4715242 Fixed wrong free in sql_view.cc
mysql-test-run now fails in case of warnings


mysql-test/lib/mtr_report.pl:
  Fail if find warnings
mysql-test/mysql-test-run.sh:
  Fail if find warnings
sql/sql_lex.cc:
  Initalize st_lex properly
sql/sql_view.cc:
  Fixed problem with unaligned memory (wrong free)
2006-05-04 22:19:31 +03:00
unknown
791a5d9444 Fixed compiler warnings
Move plugin declarations after system functions have been checked
(Fixes problem with ndb_config failing becasue SHM is not declared)
Fixed some memory leaks


configure.in:
  Move plugin declarations after system functions have been checked
  (Fixes problem with ndb_config failing becasue SHM is not declared)
mysql-test/t/disabled.def:
  Disabled ndb_load, as it is in 5.0
  (Fails randomly in binlog_close_connection())
mysql-test/t/log_tables.test:
  Update error numbers
mysql-test/t/ndb_config.test:
  Moved test depending on SHM to ndb_config2.test
mysql-test/t/ndb_partition_error.test:
  Update error numbers
sql/event_timed.cc:
  Removed not needed line
sql/ha_berkeley.cc:
  Fixed compiler warning
sql/ha_heap.cc:
  Fixed compiler warning
sql/ha_innodb.cc:
  Fixed compiler warning
sql/ha_myisam.cc:
  Fixed compiler warning
sql/ha_myisammrg.cc:
  Fixed compiler warning
sql/ha_ndbcluster.cc:
  Fixed compiler warning
sql/ha_partition.cc:
  Fixed compiler warning
sql/mysql_priv.h:
  After merge fix
sql/mysqld.cc:
  Fixed memory leak in skip_grant.test
sql/share/errmsg.txt:
  Removed wrong error messages
sql/sql_lex.cc:
  More debugging
  Faster lex_end()
sql/sql_partition.cc:
  Fixed memory leak
sql/sql_view.cc:
  Fixed memory leak
mysql-test/r/ndb_config2.result:
  New BitKeeper file ``mysql-test/r/ndb_config2.result''
mysql-test/t/ndb_config2.test:
  New BitKeeper file ``mysql-test/t/ndb_config2.test''
2006-05-04 19:39:47 +03:00
unknown
328778a1f1 fix for distcheck
configure.in:
  fix the test for distcheck
2006-04-13 09:57:51 +02:00
unknown
b9f6f9bc64 Fixes to the replication mixed mode (patch approved by Monty):
- detect the need for row-based binlogging not at execution stage but earlier at parsing stage; needed for example for CREATE TABLE SELECT UUID().
- more tests of this mixed mode.


mysql-test/r/rpl_switch_stm_row_mixed.result:
  result update
mysql-test/t/rpl_switch_stm_row_mixed.test:
  testing more scenarios for the mixed replication mode.
  Added support for manual testing of UDFs vs the mixed mode (behind a variable in the test).
  Changing old file names to better ones.
sql/item_create.cc:
  at parse time, when we see a UUID(), put up a flag in LEX to say this binlogs properly only with row-based binlogging.
sql/item_func.cc:
  it's not perfect to put up the flag at this execution stage, better do it at parse stage.
sql/item_strfunc.cc:
  it's not perfect to put up the flag at this execution stage, better do it at parse stage
sql/set_var.cc:
  this assertion is wrong, this piece of code can happen in RBR mode too.
sql/sql_lex.cc:
  when we reinitialize the LEX members before every query, we have to reinitialize the new flag
sql/sql_lex.h:
  A new flag, set at parsing stage, which tells if some items seen during parsing stage require row-based replication to binlog/replicate correctly
  when this statement is later executed.
  It has to be in LEX and not directly in THD, for this to work in prepared statements.
sql/sql_parse.cc:
  Parsing stage happened at some time in the past and set up the flag in LEX, now that we execute the statement we actually turn on row-based binlogging
  if the thread's binlog format is "mixed". We then turn it off when leaving mysql_execute_command().
  Some cleanup code was not executed if leaving mysql_execute_command() at the "error" label, fixing this. A better fix than the "goto end" would be
  to modify each "goto error" to "res=1; goto end" but it required changing many lines which I don't want to do now ("make smallest possible patch").
sql/sql_yacc.yy:
  When at parsing stage we see a UDF we put up a flag to say that row-based binlogging is preferred.
2006-03-13 15:34:30 +01:00
unknown
8c3b4b14f1 Merge zim.(none):/home/brian/mysql/mysql-5.0
into  zim.(none):/home/brian/mysql/mysql-5.1-new


sql/mysql_priv.h:
  Auto merged
sql/mysqld.cc:
  Auto merged
sql/sp.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_trigger.cc:
  Auto merged
sql/sql_view.cc:
  Auto merged
2006-03-09 17:06:04 -08:00
unknown
01d69c4b96 This patch does 1) fix my build breakage 2) Complete the removal of all symbols which could clash with another parser.
sql/mysql_priv.h:
  Porting update
sql/mysqld.cc:
  Porting update
sql/sp.cc:
  Porting update
sql/sql_lex.cc:
  Porting update
sql/sql_lex.h:
  Porting update
sql/sql_parse.cc:
  Porting update
sql/sql_prepare.cc:
  Portinng update
sql/sql_trigger.cc:
  Porting update
sql/sql_view.cc:
  Porting update
2006-03-09 16:44:08 -08:00
unknown
4f3a18d5b5 Merge zim.(none):/home/brian/mysql/mysql-5.0
into  zim.(none):/home/brian/mysql/mysql-5.1-new


configure.in:
  Auto merged
mysql-test/r/view.result:
  Auto merged
mysql-test/t/view.test:
  Auto merged
sql/item_cmpfunc.cc:
  Auto merged
sql/sql_lex.cc:
  Auto merged
sql/sql_lex.h:
  Auto merged
sql/sql_parse.cc:
  Auto merged
2006-03-09 10:39:40 -08:00
unknown
85d705b651 Porting fix that allows others to include compiled code with different parsers.
Makes you wonder what I am up to, doesn't?


configure.in:
  Adjusts bison to not create symbols that clash.
sql/sql_analyse.cc:
  Adding define to make sure sql_yacc.h gets included.
sql/sql_lex.cc:
  Fixing it so that sql_yacc.h is included
sql/sql_lex.h:
  Fixing include rules
sql/sql_parse.cc:
  Adding flag to compile sql_yacc.yy
2006-03-09 10:09:52 -08:00
unknown
99b9f7a45b Merge mysql.com:/home/alik/Documents/AllProgs/MySQL/devel/5.0-tree
into  mysql.com:/home/alik/Documents/AllProgs/MySQL/devel/5.1-merged


client/mysqldump.c:
  Auto merged
mysql-test/mysql-test-run.pl:
  Auto merged
mysql-test/r/information_schema.result:
  Auto merged
mysql-test/r/mysqldump.result:
  Auto merged
mysql-test/r/rpl_ddl.result:
  Auto merged
mysql-test/r/rpl_sp.result:
  Auto merged
mysql-test/r/rpl_trigger.result:
  Auto merged
mysql-test/r/sp-security.result:
  Auto merged
mysql-test/r/sp.result:
  Auto merged
mysql-test/r/sql_mode.result:
  Auto merged
mysql-test/t/rpl_trigger.test:
  Auto merged
mysql-test/t/skip_grants.test:
  Auto merged
mysql-test/t/sp-security.test:
  Auto merged
sql/mysql_priv.h:
  Auto merged
sql/sp_head.cc:
  Auto merged
sql/sp_head.h:
  Auto merged
sql/sql_lex.cc:
  Auto merged
sql/sql_lex.h:
  Auto merged
sql/sql_parse.cc:
  Auto merged
sql/sql_show.cc:
  Auto merged
sql/sql_trigger.cc:
  Auto merged
sql/sql_view.cc:
  Auto merged
mysql-test/lib/mtr_cases.pl:
  Manually merged.
sql/sp.cc:
  Manually merged.
sql/sql_yacc.yy:
  Manually merged.
2006-03-09 20:41:21 +03:00
unknown
bc6b7859ae Fix for multiple test failures on some platforms.
sql/sql_lex.cc:
  Added a debug assertion that the passed string is not empty.
sql/sql_show.cc:
  Do not quote empty string.
2006-03-09 03:10:39 +03:00
unknown
d7becbc2c8 Merge mysql.com:/home/kostja/mysql/mysql-5.0-root
into  mysql.com:/home/kostja/mysql/mysql-5.1-merge


BitKeeper/deleted/.del-ndb_load.result:
  Delete: mysql-test/r/ndb_load.result
BitKeeper/deleted/.del-ndb_load.test:
  Delete: mysql-test/t/ndb_load.test
extra/perror.c:
  Auto merged
mysql-test/r/fulltext.result:
  Auto merged
mysql-test/r/ndb_blob.result:
  Auto merged
mysql-test/r/sp-code.result:
  Auto merged
mysql-test/r/sp.result:
  Auto merged
mysql-test/r/view.result:
  Auto merged
mysql-test/t/fulltext.test:
  Auto merged
mysql-test/t/sp-destruct.test:
  Auto merged
mysql-test/t/sp.test:
  Auto merged
mysql-test/t/view.test:
  Auto merged
sql/ha_ndbcluster.cc:
  Auto merged
sql/ha_ndbcluster.h:
  Auto merged
sql/item_func.cc:
  Auto merged
sql/opt_range.cc:
  Auto merged
sql/sp.cc:
  Auto merged
sql/sp.h:
  Auto merged
sql/sp_head.cc:
  Auto merged
sql/sp_head.h:
  Auto merged
sql/sql_acl.cc:
  Auto merged
sql/sql_base.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_prepare.cc:
  Auto merged
sql/sql_select.cc:
  Auto merged
sql/sql_yacc.yy:
  Auto merged
storage/ndb/src/kernel/blocks/dbacc/Dbacc.hpp:
  Auto merged
storage/ndb/src/kernel/main.cpp:
  Auto merged
storage/ndb/src/kernel/vm/Configuration.cpp:
  Auto merged
storage/ndb/src/kernel/vm/Configuration.hpp:
  Auto merged
storage/ndb/src/ndbapi/NdbBlob.cpp:
  Auto merged
storage/ndb/test/ndbapi/testBlobs.cpp:
  Auto merged
storage/ndb/tools/delete_all.cpp:
  Auto merged
mysql-test/t/disabled.def:
  Manual merge.
2006-02-09 13:35:59 +03:00
unknown
8300149963 Merge rurik.mysql.com:/home/igor/dev/mysql-4.1-0
into  rurik.mysql.com:/home/igor/dev/mysql-5.0-0


mysql-test/t/having.test:
  Auto merged
mysql-test/r/having.result:
  Manual merge
sql/sql_lex.cc:
  Manual merge
sql/sql_lex.h:
  Manual merge
sql/sql_prepare.cc:
  Manual merge
sql/sql_select.cc:
  Manual merge
2006-02-02 21:23:36 -08:00
unknown
a400e7feb9 FIxed bug #14927.
A query with a group by and having clauses could return a wrong
result set if the having condition contained a constant conjunct 
evaluated to FALSE.
It happened because the pushdown condition for table with
grouping columns lost its constant conjuncts.
Pushdown conditions are always built by the function make_cond_for_table
that ignores constant conjuncts. This is apparently not correct when
constant false conjuncts are present.


mysql-test/r/having.result:
  Added A test case for bug #14927.
mysql-test/t/having.test:
  Added A test case for bug #14927.
sql/sql_lex.cc:
  Fixed bug #14927.
  Initialized fields for having conditions in  st_select_lex::init_query().
sql/sql_lex.h:
  Fixed bug #14927.
  Added a field to restore having condititions for execution in SP and PS.
sql/sql_prepare.cc:
  Fixed bug #14927.
  Added code to restore havinf conditions for execution in SP and PS.
sql/sql_select.cc:
  Fixed bug #14927.
  Performed evaluation of constant expressions in having clauses.
  If the having condition contains a constant conjunct that is always false
  an empty result set is returned after the optimization phase.
  In this case the corresponding EXPLAIN command now returns 
  "Impossible HAVING" in the last column.
2006-01-31 21:48:32 -08:00
unknown
209ff87455 BUG #16596
Moved init to lex_start


sql/sql_lex.cc:
  Added init to lex_start
sql/sql_yacc.yy:
  Removed init from CREATE INDEX code
2006-01-18 16:18:42 -05:00
unknown
bb0b7f5dda WL #1034 (Internal CRON)
merge before push


BUILD/SETUP.sh:
  Auto merged
include/my_sys.h:
  Auto merged
mysql-test/r/grant.result:
  Auto merged
mysql-test/r/ps.result:
  Auto merged
sql/Makefile.am:
  Auto merged
sql/lex.h:
  Auto merged
sql/mysqld.cc:
  Auto merged
sql/set_var.cc:
  Auto merged
sql/set_var.h:
  Auto merged
sql/sp.cc:
  Auto merged
sql/sp.h:
  Auto merged
sql/sp_head.h:
  Auto merged
sql/sql_acl.cc:
  Auto merged
sql/sql_acl.h:
  Auto merged
sql/sql_lex.cc:
  Auto merged
sql/sql_parse.cc:
  Auto merged
sql/sql_show.cc:
  Auto merged
sql/table.cc:
  Auto merged
sql/tztime.cc:
  Auto merged
libmysqld/Makefile.am:
  manual merge
mysql-test/r/information_schema.result:
  manual merge
sql/share/errmsg.txt:
  manual merge
sql/sp_head.cc:
  manual merge
sql/sql_lex.h:
  manual merge
sql/sql_yacc.yy:
  manual merge
2006-01-10 21:02:19 +01:00
unknown
6a53fec551 Merge mysql.com:/home/jimw/my/mysql-5.0-clean
into  mysql.com:/home/jimw/my/mysql-5.1-clean


mysql-test/r/sp.result:
  Auto merged
sql/item.cc:
  Auto merged
sql/item.h:
  Auto merged
sql/item_cmpfunc.cc:
  Auto merged
sql/item_func.cc:
  Auto merged
sql/item_strfunc.cc:
  Auto merged
sql/item_subselect.cc:
  Auto merged
sql/item_sum.cc:
  Auto merged
sql/mysql_priv.h:
  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_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_select.cc:
  Auto merged
sql/sql_update.cc:
  Auto merged
sql/sql_yacc.yy:
  Auto merged
sql/sql_base.cc:
  Resolve conflict
2005-12-12 11:57:07 -08:00
unknown
53f8fed437 Merge rurik.mysql.com:/home/igor/mysql-5.0
into  rurik.mysql.com:/home/igor/dev/mysql-5.0-2


sql/item.cc:
  Auto merged
sql/item.h:
  Auto merged
sql/item_func.cc:
  Auto merged
sql/mysql_priv.h:
  Auto merged
sql/sql_base.cc:
  Auto merged
sql/sql_class.cc:
  Auto merged
sql/sql_class.h:
  Auto merged
sql/sql_lex.cc:
  Auto merged
sql/sql_lex.h:
  Auto merged
sql/sql_parse.cc:
  Auto merged
sql/sql_select.cc:
  Auto merged
sql/sql_yacc.yy:
  Auto merged
2005-12-10 23:31:03 -08:00
unknown
f1ac6bb975 Merge mysql.com:/home/timka/mysql/src/5.0-2486
into  mysql.com:/home/timka/mysql/src/5.1-dbg


sql/item.cc:
  Auto merged
sql/item.h:
  Auto merged
sql/mysql_priv.h:
  Auto merged
sql/sql_acl.cc:
  Auto merged
sql/sql_acl.h:
  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_yacc.yy:
  Auto merged
sql/table.h:
  Auto merged
sql/sql_base.cc:
  SCCS merged
sql/table.cc:
  SCCS merged
2005-12-07 10:47:43 +02:00
unknown
4d891eb91c WL1034 update for latest 5.1 sources
BUILD/SETUP.sh:
  for now no optimizations in debug build - get rid of "value optimized out"
2005-12-02 13:07:02 +01:00
unknown
4fd41f7c0b WL#2486 - Natural/using join according to SQL:2003.
Post-review fixes according to Monty's review.


sql/item.h:
  Unite all code that stores and restores the state of a name resolution context
  into a class to represent the state, and methods to save/restore that
  state.
sql/mysql_priv.h:
  Reorder parameters so that length is after the name of a field,
  and database is before table name.
sql/sql_acl.cc:
  Reorder parameters so that length is after the name of a field,
  and database is before table name.
sql/sql_base.cc:
  * Reorder parameters so that length is after the name of a field,
    and database is before table name.
  * Added new method - Field_iterator_table_ref::get_natural_column_ref
    to avoid unnecessary code when it is knwon that no new columns will
    be created when accessing natural join columns.
sql/sql_insert.cc:
  Unite all code that stores and restores the state of a name resolution context
  into a class to represent the state, and methods to save/restore that
  state.
sql/sql_lex.cc:
  Removed obsolete comment.
sql/sql_lex.h:
  Return error from push_contex() if there is no memory.
sql/sql_list.h:
  Extended base_list_iterator, List_iterator, and List_iterator_fast with an
  empty constructor, and init() methods, so that one doesn't have to construct
  a new iterator object every time one needs to iterate over a new list.
sql/sql_parse.cc:
  Moved common functionality from the parser into one function, and renamed
  the function to better reflect what it does.
sql/sql_yacc.yy:
  Moved common functionality from the parser into one function, and renamed
  the function to better reflect what it does.
sql/table.cc:
  * Extended base_list_iterator, List_iterator, and List_iterator_fast with an
    empty constructor, and init() methods, so that one doesn't have to construct
    a new iterator object every time one needs to iterate over a new list.
  * Added new method Field_iterator_table_ref::get_natural_column_ref to be
    used in cases when it is known for sure that no new columns should be
    created.
sql/table.h:
  - column_ref_it no longer allocated for each new list of columns
  - new method get_natural_join_column for faster/simpler access
    to natural join columns.
2005-11-28 21:57:50 +02:00
unknown
039168c2fa Merge mysql.com:/home/my/mysql-5.1
into  mysql.com:/home/my/mysql-5.1-TDC


mysql-test/r/variables.result:
  Auto merged
mysql-test/t/variables.test:
  Auto merged
sql/ha_berkeley.cc:
  Auto merged
sql/ha_federated.cc:
  Auto merged
sql/ha_federated.h:
  Auto merged
sql/ha_innodb.cc:
  Auto merged
sql/ha_myisammrg.cc:
  Auto merged
sql/ha_ndbcluster.cc:
  Auto merged
sql/handler.cc:
  Auto merged
sql/item.cc:
  Auto merged
sql/item.h:
  Auto merged
sql/item_cmpfunc.cc:
  Auto merged
sql/item_func.cc:
  Auto merged
sql/item_subselect.cc:
  Auto merged
sql/item_sum.cc:
  Auto merged
sql/item_timefunc.cc:
  Auto merged
sql/key.cc:
  Auto merged
sql/mysqld.cc:
  Auto merged
sql/opt_range.cc:
  Auto merged
sql/parse_file.cc:
  Auto merged
sql/set_var.cc:
  Auto merged
sql/slave.cc:
  Auto merged
sql/sp.cc:
  Auto merged
sql/sp_head.cc:
  Auto merged
sql/sp_head.h:
  Auto merged
sql/sql_acl.cc:
  Auto merged
sql/sql_class.cc:
  Auto merged
sql/sql_class.h:
  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_show.cc:
  Auto merged
sql/sql_table.cc:
  Auto merged
sql/sql_trigger.cc:
  Auto merged
sql/sql_view.cc:
  Auto merged
sql/structs.h:
  Auto merged
sql/field.cc:
  Merge with global tree
sql/sql_base.cc:
  Merge with global tree
sql/table.cc:
  Merge with global tree
2005-11-23 22:58:53 +02:00
unknown
f631b361b6 Table definition cache, part 2
The table opening process now works the following way:
- Create common TABLE_SHARE object
- Read the .frm file and unpack it into the TABLE_SHARE object
- Create a TABLE object based on the information in the TABLE_SHARE
  object and open a handler to the table object

Other noteworthy changes:
- In TABLE_SHARE the most common strings are now LEX_STRING's
- Better error message when table is not found
- Variable table_cache is now renamed 'table_open_cache'
- New variable 'table_definition_cache' that is the number of table defintions that will be cached
- strxnmov() calls are now fixed to avoid overflows
- strxnmov() will now always add one end \0 to result
- engine objects are now created with a TABLE_SHARE object instead of a TABLE object.
- After creating a field object one must call field->init(table) before using it

- For a busy system this change will give you:
 - Less memory usage for table object
 - Faster opening of tables (if it's has been in use or is in table definition cache)
 - Allow you to cache many table definitions objects
 - Faster drop of table


mysql-test/mysql-test-run.sh:
  Fixed some problems with --gdb option
  Test both with socket and tcp/ip port that all old servers are killed
mysql-test/r/flush_table.result:
  More tests with lock table with 2 threads + flush table
mysql-test/r/information_schema.result:
  Removed old (now wrong) result
mysql-test/r/innodb.result:
  Better error messages (thanks to TDC patch)
mysql-test/r/merge.result:
  Extra flush table test
mysql-test/r/ndb_bitfield.result:
  Better error messages (thanks to TDC patch)
mysql-test/r/ndb_partition_error.result:
  Better error messages (thanks to TDC patch)
mysql-test/r/query_cache.result:
  Remove tables left from old tests
mysql-test/r/temp_table.result:
  Test truncate with temporary tables
mysql-test/r/variables.result:
  Table_cache -> Table_open_cache
mysql-test/t/flush_table.test:
  More tests with lock table with 2 threads + flush table
mysql-test/t/merge.test:
  Extra flush table test
mysql-test/t/multi_update.test:
  Added 'sleep' to make test predictable
mysql-test/t/query_cache.test:
  Remove tables left from old tests
mysql-test/t/temp_table.test:
  Test truncate with temporary tables
mysql-test/t/variables.test:
  Table_cache -> Table_open_cache
mysql-test/valgrind.supp:
  Remove warning that may happens becasue threads dies in different order
mysys/hash.c:
  Fixed wrong DBUG_PRINT
mysys/mf_dirname.c:
  More DBUG
mysys/mf_pack.c:
  Better comment
mysys/mf_tempdir.c:
  More DBUG
  Ensure that we call cleanup_dirname() on all temporary directory paths.
  
  If we don't do this, we will get a failure when comparing temporary table
  names as in some cases the temporary table name is run through convert_dirname())
mysys/my_alloc.c:
  Indentation fix
sql/examples/ha_example.cc:
  We new use TABLE_SHARE instead of TABLE when creating engine handlers
sql/examples/ha_example.h:
  We new use TABLE_SHARE instead of TABLE when creating engine handlers
sql/examples/ha_tina.cc:
  We new use TABLE_SHARE instead of TABLE when creating engine handlers
sql/examples/ha_tina.h:
  We new use TABLE_SHARE instead of TABLE when creating engine handlers
sql/field.cc:
  Update for table definition cache:
  - Field creation now takes TABLE_SHARE instead of TABLE as argument
    (This is becasue field definitions are now cached in TABLE_SHARE)
    When a field is created, one now must call field->init(TABLE) before using it
  - Use s->db instead of s->table_cache_key
  - Added Field::clone() to create a field in TABLE from a field in TABLE_SHARE
  - make_field() takes TABLE_SHARE as argument instead of TABLE
  - move_field() -> move_field_offset()
sql/field.h:
  Update for table definition cache:
  - Field creation now takes TABLE_SHARE instead of TABLE as argument
    (This is becasue field definitions are now cached in TABLE_SHARE)
    When a field is created, one now must call field->init(TABLE) before using it
  - Added Field::clone() to create a field in TABLE from a field in TABLE_SHARE
  - make_field() takes TABLE_SHARE as argument instead of TABLE
  - move_field() -> move_field_offset()
sql/ha_archive.cc:
  We new use TABLE_SHARE instead of TABLE when creating engine handlers
sql/ha_archive.h:
  We new use TABLE_SHARE instead of TABLE when creating engine handlers
sql/ha_berkeley.cc:
  We new use TABLE_SHARE instead of TABLE when creating engine handlers
  Changed name of argument create() to not hide internal 'table' variable.
  table->s  -> table_share
sql/ha_berkeley.h:
  We new use TABLE_SHARE instead of TABLE when creating engine handlers
sql/ha_blackhole.cc:
  We new use TABLE_SHARE instead of TABLE when creating engine handlers
sql/ha_blackhole.h:
  We new use TABLE_SHARE instead of TABLE when creating engine handlers
sql/ha_federated.cc:
  We new use TABLE_SHARE instead of TABLE when creating engine handlers
  Fixed comments
  Remove index variable and replace with pointers (simple optimization)
  move_field() -> move_field_offset()
  Removed some strlen() calls
sql/ha_federated.h:
  We new use TABLE_SHARE instead of TABLE when creating engine handlers
sql/ha_heap.cc:
  We new use TABLE_SHARE instead of TABLE when creating engine handlers
  Simplify delete_table() and create() as the given file names are now without extension
sql/ha_heap.h:
  We new use TABLE_SHARE instead of TABLE when creating engine handlers
sql/ha_innodb.cc:
  We new use TABLE_SHARE instead of TABLE when creating engine handlers
sql/ha_innodb.h:
  We new use TABLE_SHARE instead of TABLE when creating engine handlers
sql/ha_myisam.cc:
  We new use TABLE_SHARE instead of TABLE when creating engine handlers
  Remove not needed fn_format()
  Fixed for new table->s structure
sql/ha_myisam.h:
  We new use TABLE_SHARE instead of TABLE when creating engine handlers
sql/ha_myisammrg.cc:
  We new use TABLE_SHARE instead of TABLE when creating engine handlers
  Don't set 'is_view' for MERGE tables
  Use new interface to find_temporary_table()
sql/ha_myisammrg.h:
  We new use TABLE_SHARE instead of TABLE when creating engine handlers
  Added flag HA_NO_COPY_ON_ALTER
sql/ha_ndbcluster.cc:
  We new use TABLE_SHARE instead of TABLE when creating engine handlers
  Fixed wrong calls to strxnmov()
  Give error HA_ERR_TABLE_DEF_CHANGED if table definition has changed
  drop_table -> intern_drop_table()
  table->s -> table_share
  Move part_info to TABLE
  Fixed comments & DBUG print's
  New arguments to print_error()
sql/ha_ndbcluster.h:
  We new use TABLE_SHARE instead of TABLE when creating engine handlers
sql/ha_partition.cc:
  We new use TABLE_SHARE instead of TABLE when creating engine handlers
  We can't set up or use part_info when creating handler as there is not yet any table object
  New ha_intialise() to work with TDC (Done by Mikael)
sql/ha_partition.h:
  We new use TABLE_SHARE instead of TABLE when creating engine handlers
  Got set_part_info() from Mikael
sql/handler.cc:
  We new use TABLE_SHARE instead of TABLE when creating engine handlers
  ha_delete_table() now also takes database as an argument
  handler::ha_open() now takes TABLE as argument
  ha_open() now calls ha_allocate_read_write_set()
  Simplify ha_allocate_read_write_set()
  Remove ha_deallocate_read_write_set()
  Use table_share (Cached by table definition cache)
sql/handler.h:
  New table flag: HA_NO_COPY_ON_ALTER (used by merge tables)
  Remove ha_deallocate_read_write_set()
  get_new_handler() now takes TABLE_SHARE as argument
  ha_delete_table() now gets database as argument
sql/item.cc:
  table_name and db are now LEX_STRING objects
  When creating fields, we have now have to call field->init(table)
  move_field -> move_field_offset()
sql/item.h:
  tmp_table_field_from_field_type() now takes an extra paramenter 'fixed_length' to allow one to force usage of CHAR
   instead of BLOB
sql/item_cmpfunc.cc:
  Fixed call to tmp_table_field_from_field_type()
sql/item_create.cc:
  Assert if new not handled cast type
sql/item_func.cc:
  When creating fields, we have now have to call field->init(table)
  dummy_table used by 'sp' now needs a TABLE_SHARE object
sql/item_subselect.cc:
  Trivial code cleanups
sql/item_sum.cc:
  When creating fields, we have now have to call field->init(table)
sql/item_timefunc.cc:
  Item_func_str_to_date::tmp_table_field() now replaced by call to
   tmp_table_field_from_field_type() (see item_timefunc.h)
sql/item_timefunc.h:
  Simply tmp_table_field()
sql/item_uniq.cc:
  When creating fields, we have now have to call field->init(table)
sql/key.cc:
  Added 'KEY' argument to 'find_ref_key' to simplify code
sql/lock.cc:
  More debugging
  Use create_table_def_key() to create key for table cache
  Allocate TABLE_SHARE properly when creating name lock
  Fix that locked_table_name doesn't test same table twice
sql/mysql_priv.h:
  New functions for table definition cache
  New interfaces to a lot of functions.
  New faster interface to find_temporary_table() and close_temporary_table()
sql/mysqld.cc:
  Added support for table definition cache of size 'table_def_size'
  Fixed som calls to strnmov()
  Changed name of 'table_cache' to 'table_open_cache'
sql/opt_range.cc:
  Use new interfaces
  Fixed warnings from valgrind
sql/parse_file.cc:
  Safer calls to strxnmov()
  Fixed typo
sql/set_var.cc:
  Added variable 'table_definition_cache'
  Variable table_cache renamed to 'table_open_cache'
sql/slave.cc:
  Use new interface
sql/sp.cc:
  Proper use of TABLE_SHARE
sql/sp_head.cc:
  Remove compiler warnings
  We have now to call field->init(table)
sql/sp_head.h:
  Pointers to parsed strings are now const
sql/sql_acl.cc:
  table_name is now a LEX_STRING
sql/sql_base.cc:
  Main implementation of table definition cache
  (The #ifdef's are there for the future when table definition cache will replace open table cache)
  Now table definitions are cached indepndent of open tables, which will speed up things when a table is in use at once from several places
  Views are not yet cached; For the moment we only cache if a table is a view or not.
  
  Faster implementation of find_temorary_table()
  Replace 'wait_for_refresh()' with the more general function 'wait_for_condition()'
  Drop table is slightly faster as we can use the table definition cache to know the type of the table
sql/sql_cache.cc:
  table_cache_key and table_name are now LEX_STRING
  'sDBUG print fixes
sql/sql_class.cc:
  table_cache_key is now a LEX_STRING
  safer strxnmov()
sql/sql_class.h:
  Added number of open table shares (table definitions)
sql/sql_db.cc:
  safer strxnmov()
sql/sql_delete.cc:
  Use new interface to find_temporary_table()
sql/sql_derived.cc:
  table_name is now a LEX_STRING
sql/sql_handler.cc:
  TABLE_SHARE->db and TABLE_SHARE->table_name are now LEX_STRING's
sql/sql_insert.cc:
  TABLE_SHARE->db and TABLE_SHARE->table_name are now LEX_STRING's
sql/sql_lex.cc:
  Make parsed string a const (to quickly find out if anything is trying to change the query string)
sql/sql_lex.h:
  Make parsed string a const (to quickly find out if anything is trying to change the query string)
sql/sql_load.cc:
  Safer strxnmov()
sql/sql_parse.cc:
  Better error if wrong DB name
sql/sql_partition.cc:
  part_info moved to TABLE from TABLE_SHARE
  Indentation changes
sql/sql_select.cc:
  Indentation fixes
  Call field->init(TABLE) for new created fields
  Update create_tmp_table() to use TABLE_SHARE properly
sql/sql_select.h:
  Call field->init(TABLE) for new created fields
sql/sql_show.cc:
  table_name is now a LEX_STRING
  part_info moved to TABLE
sql/sql_table.cc:
  Use table definition cache to speed up delete of tables
  Fixed calls to functions with new interfaces
  Don't use 'share_not_to_be_used'
  Instead of doing openfrm() when doing repair, we now have to call
  get_table_share() followed by open_table_from_share().
  Replace some fn_format() with faster unpack_filename().
  Safer strxnmov()
  part_info is now in TABLE
  Added Mikaels patch for partition and ALTER TABLE
  Instead of using 'TABLE_SHARE->is_view' use 'table_flags() & HA_NO_COPY_ON_ALTER
sql/sql_test.cc:
  table_name and table_cache_key are now LEX_STRING's
sql/sql_trigger.cc:
  TABLE_SHARE->db and TABLE_SHARE->table_name are now LEX_STRING's
  safer strxnmov()
  Removed compiler warnings
sql/sql_update.cc:
  Call field->init(TABLE) after field is created
sql/sql_view.cc:
  safer strxnmov()
  Create common TABLE_SHARE object for views to allow us to cache if table is a view
sql/structs.h:
  Added SHOW_TABLE_DEFINITIONS
sql/table.cc:
  Creation and destruct of TABLE_SHARE objects that are common for many TABLE objects
  
  The table opening process now works the following way:
  - Create common TABLE_SHARE object
  - Read the .frm file and unpack it into the TABLE_SHARE object
  - Create a TABLE object based on the information in the TABLE_SHARE
    object and open a handler to the table object
  
  open_table_def() is written in such a way that it should be trival to add parsing of the .frm files in new formats
sql/table.h:
  TABLE objects for the same database table now share a common TABLE_SHARE object
  In TABLE_SHARE the most common strings are now LEX_STRING's
sql/unireg.cc:
  Changed arguments to rea_create_table() to have same order as other functions
  Call field->init(table) for new created fields
sql/unireg.h:
  Added OPEN_VIEW
strings/strxnmov.c:
  Change strxnmov() to always add end \0
  This makes usage of strxnmov() safer as most of MySQL code assumes that strxnmov() will create a null terminated string
2005-11-23 22:45:02 +02:00
unknown
33a2716a85 Merge a193-229-222-105.elisa-laajakaista.fi:/home/my/bk/mysql-5.0
into  a193-229-222-105.elisa-laajakaista.fi:/home/my/bk/mysql-5.1-new


Makefile.am:
  Auto merged
client/mysqltest.c:
  Auto merged
configure.in:
  Auto merged
extra/Makefile.am:
  Auto merged
include/Makefile.am:
  Auto merged
include/my_global.h:
  Auto merged
libmysqld/examples/Makefile.am:
  Auto merged
mysql-test/Makefile.am:
  Auto merged
mysql-test/r/ndb_alter_table.result:
  Auto merged
mysql-test/t/ndb_alter_table.test:
  Auto merged
scripts/Makefile.am:
  Auto merged
sql/Makefile.am:
  Auto merged
sql/field.cc:
  Auto merged
sql/ha_federated.cc:
  Auto merged
sql/ha_federated.h:
  Auto merged
sql/ha_innodb.cc:
  Auto merged
sql/ha_myisammrg.cc:
  Auto merged
sql/ha_ndbcluster.cc:
  Auto merged
sql/handler.cc:
  Auto merged
sql/item.cc:
  Auto merged
sql/item_subselect.cc:
  Auto merged
sql/key.cc:
  Auto merged
sql/log.cc:
  Auto merged
sql/log_event.cc:
  Auto merged
sql/mysqld.cc:
  Auto merged
sql/opt_range.cc:
  Auto merged
sql/repl_failsafe.cc:
  Auto merged
sql/slave.cc:
  Auto merged
sql/sp.cc:
  Auto merged
sql/sp_head.cc:
  Auto merged
sql/sql_acl.cc:
  Auto merged
sql/sql_base.cc:
  Auto merged
sql/sql_cache.h:
  Auto merged
sql/sql_class.cc:
  Auto merged
sql/sql_class.h:
  Auto merged
sql/sql_lex.cc:
  Auto merged
sql/sql_load.cc:
  Auto merged
sql/sql_parse.cc:
  Auto merged
sql/sql_prepare.cc:
  Auto merged
sql/sql_repl.cc:
  Auto merged
sql/sql_select.cc:
  Auto merged
sql/sql_table.cc:
  Auto merged
sql/structs.h:
  Auto merged
sql/table.cc:
  Auto merged
sql/tztime.cc:
  Auto merged
storage/myisam/myisamchk.c:
  Auto merged
storage/myisam/myisampack.c:
  Auto merged
storage/ndb/docs/Makefile.am:
  Auto merged
support-files/mysql.spec.sh:
  Auto merged
libmysqld/Makefile.am:
  Merged from 5.0 to 5.1.
sql/ha_berkeley.cc:
  Merged from 5.0 to 5.1.
sql/lex.h:
  Merged from 5.0 to 5.1.
sql/set_var.cc:
  Merged from 5.0 to 5.1.
sql/share/errmsg.txt:
  Merged from 5.0 to 5.1.
sql/sql_lex.h:
  Merged from 5.0 to 5.1.
sql/sql_show.cc:
  Merged from 5.0 to 5.1.
sql/sql_yacc.yy:
  Merged from 5.0 to 5.1.
2005-11-23 14:57:00 +02:00
unknown
c3c232a88c Merge rurik.mysql.com:/home/igor/mysql-5.0
into  rurik.mysql.com:/home/igor/dev/mysql-5.0-2


mysql-test/r/func_gconcat.result:
  Auto merged
mysql-test/t/func_gconcat.test:
  Auto merged
sql/item.cc:
  Auto merged
sql/item.h:
  Auto merged
sql/item_cmpfunc.cc:
  Auto merged
sql/item_func.cc:
  Auto merged
sql/item_strfunc.cc:
  Auto merged
sql/item_subselect.cc:
  Auto merged
sql/item_sum.cc:
  Auto merged
sql/sql_base.cc:
  Auto merged
sql/sql_class.cc:
  Auto merged
sql/sql_class.h:
  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_select.cc:
  Auto merged
sql/sql_yacc.yy:
  Auto merged
2005-11-22 23:00:57 -08:00
unknown
fe63e09581 Inefficient usage of String::append() fixed.
Bad examples of usage of a string with its length fixed.
The incorrect length in the trigger file configuration descriptor
  fixed (BUG#14090).
A hook for unknown keys added to the parser to support old .TRG files.


sql/field.cc:
  Inefficient usage of String::append() fixed.
  Bad examples of usage of a string with its length fixed.
sql/ha_berkeley.cc:
  A bad example of usage of a string with its length fixed.
sql/ha_federated.cc:
  Inefficient usage of String::append() fixed.
sql/ha_myisammrg.cc:
  Bad examples of usage of a string with its length fixed.
sql/handler.cc:
  Inefficient usage of String::append() fixed.
sql/item.cc:
  Bad examples of usage of a string with its length fixed.
sql/item.h:
  A bad example of usage of a string with its length fixed.
sql/item_cmpfunc.cc:
  Bad examples of usage of a string with its length fixed.
sql/item_func.cc:
  Bad examples of usage of a string with its length fixed.
sql/item_strfunc.cc:
  Bad examples of usage of a string with its length fixed.
sql/item_subselect.cc:
  Bad examples of usage of a string with its length fixed.
sql/item_sum.cc:
  Bad examples of usage of a string with its length fixed.
  Inefficient usage of String::append() fixed.
sql/item_timefunc.cc:
  Inefficient using of String::append() fixed.
  Bad examples of usage of a string with its length fixed.
sql/item_uniq.h:
  Bad examples of usage of a string with its length fixed.
sql/key.cc:
  Bad examples of usage of a string with its length fixed.
sql/log.cc:
  Bad examples of usage of a string with its length fixed.
sql/log_event.cc:
  Bad examples of usage of a string with its length fixed.
sql/mysqld.cc:
  The dummy parser hook allocated.
sql/opt_range.cc:
  Inefficient usage of String::append() fixed.
sql/parse_file.cc:
  Bad examples of usage of a string with its length fixed.
  A hook for unknown keys added to the parser.
sql/parse_file.h:
  A hook for unknown keys added to the parser.
sql/protocol.cc:
  A bad example of usage of a string with its length fixed.
sql/repl_failsafe.cc:
  Bad examples of usage of a string with its length fixed.
sql/share/errmsg.txt:
  A warning for old format config file.
sql/slave.cc:
  Bad examples of usage of a string with its length fixed.
sql/sp.cc:
  Bad examples of usage of a string with its length fixed.
sql/sp_head.cc:
  Bad examples of usage of a string with its length fixed.
sql/spatial.cc:
  A bad example of usage of a string with its length fixed.
sql/sql_acl.cc:
  Bad examples of usage of a string with its length fixed.
sql/sql_analyse.cc:
  Bad examples of usage of a string with its length fixed.
  Inefficient usage of String::append() fixed.
sql/sql_lex.cc:
  Bad examples of usage of a string with its length fixed.
sql/sql_load.cc:
  A bad example of usage of a string with its length fixed.
sql/sql_parse.cc:
  Bad examples of usage of a string with its length fixed.
sql/sql_prepare.cc:
  A bad example of usage of a string with its length fixed.
sql/sql_select.cc:
  Bad examples of usage of a string with its length fixed.
sql/sql_show.cc:
  Bad examples of usage of a string with its length fixed.
sql/sql_string.cc:
  Bad examples of usage of a string with its length fixed.
sql/sql_string.h:
  The macro definition moved to sql_string.h to
    be accessible in all parts of server.
sql/sql_table.cc:
  Bad examples of usage of a string with its length fixed.
sql/sql_trigger.cc:
  Bad examples of usage of a string with its length fixed.
  The incorrect length in the trigger file configuration descriptor
    fixed (BUG#14090).
  The hook for processing incorrect sql_mode record added.
sql/sql_view.cc:
  A dummy  hook used for parsing views.
sql/structs.h:
  The macro definition moved to sql_string.h to be
    accessible in all parts of server.
sql/table.cc:
  A bad example of usage of a string with its length fixed.
sql/tztime.cc:
  A bad example of usage of a string with its length fixed.
2005-11-20 20:47:07 +02:00
unknown
41de6f9a7c Merge mysql.com:/home/mysql_src/mysql-5.0
into  mysql.com:/home/mysql_src/mysql-5.1-merge-of-5.0 (not all files are good,
I'll fix; I'll ask some devs to check their part)


BitKeeper/etc/ignore:
  auto-union
include/my_global.h:
  Auto merged
mysql-test/mysql-test-run.pl:
  Auto merged
mysql-test/mysql-test-run.sh:
  Auto merged
mysql-test/r/information_schema.result:
  Auto merged
mysql-test/t/view.test:
  Auto merged
scripts/mysql_fix_privilege_tables.sql:
  Auto merged
sql/field.cc:
  Auto merged
sql/item.cc:
  Auto merged
sql/mysql_priv.h:
  Auto merged
sql/mysqld.cc:
  Auto merged
sql/opt_range.cc:
  Auto merged
sql/set_var.h:
  Auto merged
sql/sp.cc:
  Auto merged
sql/sp_head.cc:
  Auto merged
sql/sql_acl.cc:
  Auto merged
sql/sql_class.h:
  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_repl.cc:
  Auto merged
sql/sql_select.cc:
  Auto merged
sql/sql_select.h:
  Auto merged
sql/sql_table.cc:
  Auto merged
sql/table.h:
  Auto merged
storage/myisam/mi_key.c:
  Auto merged
storage/ndb/src/kernel/blocks/dbtc/DbtcMain.cpp:
  Auto merged
storage/ndb/src/ndbapi/NdbImpl.hpp:
  Auto merged
storage/ndb/src/ndbapi/ndb_cluster_connection.cpp:
  Auto merged
support-files/mysql.spec.sh:
  Auto merged
configure.in:
  merge
mysql-test/r/ps_1general.result:
  merge ("ul", will fix)
sql/examples/ha_tina.cc:
  merge
sql/ha_innodb.cc:
  merge
sql/handler.h:
  merge
sql/log.cc:
  merge
sql/set_var.cc:
  merge
sql/share/errmsg.txt:
  merge (bad, will fix)
sql/sql_show.cc:
  merge (bad, will fix)
sql/sql_yacc.yy:
  merge
storage/ndb/src/ndbapi/NdbRecAttr.cpp:
  merge
2005-11-18 16:38:01 +01:00
unknown
2c748c3ef9 Merge rurik.mysql.com:/home/igor/mysql-5.0
into  rurik.mysql.com:/home/igor/dev/mysql-5.0-2


sql/item.cc:
  Auto merged
sql/item_func.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_select.cc:
  Auto merged
sql/sql_yacc.yy:
  Auto merged
sql/mysql_priv.h:
  Manual merge
2005-11-13 17:56:20 -08:00
unknown
d090acf320 1. sys_variables[] array is removed.
2. All have_xxx variables are now selectable.


sql/set_var.cc:
  1. sys_have_xxx variables added.
  2. Removed sys_var *sys_variables[] array as we don't need it any more.
  3. void set_var_init() changed to use sys_var_xxx chain insted of sys_variables[] array.
sql/set_var.h:
  1. add_sys_var() method added to the sys_var class. It's called from constructors
  to chain all successor objects. The first one is stored in the 'static sys_var *first'.
  The total number of variables is in the 'static uint sys_vars'. Each sys_var successor object
  has the 'sys_var *next' pointer to the next one in the chain. 
  2. sys_var_have_variable class introduced to make all have_xxx variables selectable.
sql/sql_lex.cc:
  trg_new_row_fake_var(0, 0) replaced with '(sys_var*) 0x01' as we don't want to have such fake variables in the sys_var_xxx chain.
sql/sql_lex.h:
  Proper use of the changed trg_new_row_fake_var.
sql/sql_yacc.yy:
  Proper use of the changed trg_new_row_fake_var.
2005-11-06 01:36:40 +01:00
unknown
2361720c98 Merge mysql.com:/home/my/mysql-5.0
into  mysql.com:/home/my/mysql-5.1


BUILD/FINISH.sh:
  Auto merged
BitKeeper/deleted/.del-makefilewin.i~5c8479dcb8a455b2:
  Auto merged
BitKeeper/deleted/.del-makefilewin~13888739357b3025:
  Auto merged
BitKeeper/deleted/.del-makefilewin~14f24a4a173e2fcd:
  Auto merged
BitKeeper/deleted/.del-makefilewin~15e9e5c9e8fa870b:
  Auto merged
BitKeeper/deleted/.del-makefilewin~1c53f31b88dd36e:
  Auto merged
BitKeeper/deleted/.del-makefilewin~1dbc058d76ebf1db:
  Auto merged
BitKeeper/deleted/.del-makefilewin~2e0407fe123f8365:
  Auto merged
BitKeeper/deleted/.del-makefilewin~2fc379bd4065c995:
  Auto merged
BitKeeper/deleted/.del-makefilewin~389ee2dcf79afb79:
  Auto merged
BitKeeper/deleted/.del-makefilewin~4d139e182457e553:
  Auto merged
BitKeeper/deleted/.del-makefilewin~5104767c73775697:
  Auto merged
BitKeeper/deleted/.del-makefilewin~608ed49dcd88e0f7:
  Auto merged
BitKeeper/deleted/.del-makefilewin~63acd666293282a:
  Auto merged
BitKeeper/deleted/.del-makefilewin~6ba64863bce3d0b8:
  Auto merged
BitKeeper/deleted/.del-makefilewin~72a64128bacce71b:
  Auto merged
BitKeeper/deleted/.del-makefilewin~78000390c783b1c5:
  Auto merged
BitKeeper/deleted/.del-makefilewin~7a9d7d5a42bbfaf5:
  Auto merged
Makefile.am:
  Auto merged
BitKeeper/deleted/.del-makefilewin~a40ea12eebdd6ef0:
  Auto merged
BitKeeper/deleted/.del-makefilewin~aeea7c82f21f7cf5:
  Auto merged
BitKeeper/deleted/.del-makefilewin~b643e38d8da389ac:
  Auto merged
BitKeeper/deleted/.del-makefilewin~c7b621c745e5de95:
  Auto merged
BitKeeper/deleted/.del-makefilewin~c8273a47b90f52bb:
  Auto merged
BitKeeper/deleted/.del-makefilewin~d1a9d1f7d33fcb73:
  Auto merged
BitKeeper/deleted/.del-makefilewin~d37b6b303348c871:
  Auto merged
BitKeeper/deleted/.del-makefilewin~d90f35fdc3f2ee5f:
  Auto merged
BitKeeper/deleted/.del-makefilewin~dc4b8ad5ea53bd:
  Auto merged
BitKeeper/deleted/.del-makefilewin~dea10ec1c94f7be:
  Auto merged
BitKeeper/deleted/.del-makefilewin~ef3a208fa0e9b0db:
  Auto merged
BitKeeper/deleted/.del-makefilewin~f1e3b890aa1c9ea3:
  Auto merged
BitKeeper/deleted/.del-makefilewin~f4b7b99a887b7de:
  Auto merged
BitKeeper/deleted/.del-makefilewin~fdda94ad32fa9e34:
  Auto merged
BitKeeper/deleted/.del-my_cnf~977f69858affc57b:
  Auto merged
BitKeeper/etc/config:
  Auto merged
VC++Files/libmysqld/libmysqld.dsp:
  Auto merged
VC++Files/sql/mysqld.dsp:
  Auto merged
client/mysqltest.c:
  Auto merged
include/Makefile.am:
  Auto merged
include/base64.h:
  Auto merged
include/my_base.h:
  Auto merged
include/mysql_com.h:
  Auto merged
libmysqld/Makefile.am:
  Auto merged
mysql-test/mysql-test-run.pl:
  Auto merged
mysql-test/mysql-test-run.sh:
  Auto merged
mysql-test/r/ndb_basic.result:
  Auto merged
mysql-test/r/ndb_condition_pushdown.result:
  Auto merged
mysql-test/t/alter_table.test:
  Auto merged
mysql-test/t/disabled.def:
  Auto merged
mysql-test/t/query_cache.test:
  Auto merged
mysys/Makefile.am:
  Auto merged
mysys/base64.c:
  Auto merged
scripts/make_win_src_distribution.sh:
  Auto merged
scripts/mysql_create_system_tables.sh:
  Auto merged
scripts/mysql_fix_privilege_tables.sql:
  Auto merged
sql/Makefile.am:
  Auto merged
sql/field.cc:
  Auto merged
sql/field.h:
  Auto merged
sql/ha_berkeley.cc:
  Auto merged
sql/ha_berkeley.h:
  Auto merged
sql/ha_federated.cc:
  Auto merged
sql/ha_innodb.cc:
  Auto merged
sql/ha_myisam.cc:
  Auto merged
sql/ha_ndbcluster.cc:
  Auto merged
sql/handler.h:
  Auto merged
sql/item.cc:
  Auto merged
sql/item_subselect.cc:
  Auto merged
sql/log.cc:
  Auto merged
sql/log_event.cc:
  Auto merged
sql/mysqld.cc:
  Auto merged
sql/opt_range.cc:
  Auto merged
sql/repl_failsafe.cc:
  Auto merged
sql/slave.cc:
  Auto merged
sql/slave.h:
  Auto merged
sql/sp.cc:
  Auto merged
sql/sql_acl.cc:
  Auto merged
sql/sql_base.cc:
  Auto merged
sql/sql_cache.cc:
  Auto merged
sql/sql_class.h:
  Auto merged
sql/sql_delete.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_prepare.cc:
  Auto merged
sql/sql_repl.cc:
  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
sql/table.h:
  Auto merged
storage/heap/_check.c:
  Auto merged
storage/heap/hp_create.c:
  Auto merged
storage/innobase/include/Makefile.am:
  Auto merged
storage/innobase/include/rem0rec.h:
  Auto merged
storage/innobase/include/rem0rec.ic:
  Auto merged
storage/innobase/row/row0ins.c:
  Auto merged
storage/innobase/row/row0upd.c:
  Auto merged
storage/myisam/mi_check.c:
  Auto merged
storage/myisam/mi_delete.c:
  Auto merged
storage/myisam/mi_rkey.c:
  Auto merged
storage/myisam/mi_rnext_same.c:
  Auto merged
storage/myisam/mi_search.c:
  Auto merged
storage/myisam/mi_write.c:
  Auto merged
storage/myisam/myisamchk.c:
  Auto merged
storage/myisam/myisamdef.h:
  Auto merged
storage/myisam/sort.c:
  Auto merged
storage/myisammrg/myrg_queue.c:
  Auto merged
storage/ndb/config/type_util.mk.am:
  Auto merged
storage/ndb/include/kernel/signaldata/DumpStateOrd.hpp:
  Auto merged
storage/ndb/include/mgmapi/mgmapi_config_parameters.h:
  Auto merged
storage/ndb/include/mgmapi/ndbd_exit_codes.h:
  Auto merged
storage/ndb/include/transporter/TransporterCallback.hpp:
  Auto merged
storage/ndb/src/common/mgmcommon/IPCConfig.cpp:
  Auto merged
storage/ndb/src/common/transporter/SHM_Transporter.cpp:
  Auto merged
storage/ndb/src/common/transporter/SHM_Transporter.hpp:
  Auto merged
storage/ndb/src/common/transporter/SHM_Transporter.unix.cpp:
  Auto merged
storage/ndb/src/common/transporter/SHM_Transporter.win32.cpp:
  Auto merged
storage/ndb/src/common/transporter/Transporter.hpp:
  Auto merged
storage/ndb/src/common/transporter/TransporterRegistry.cpp:
  Auto merged
storage/ndb/src/common/util/Makefile.am:
  Auto merged
storage/ndb/src/common/util/Parser.cpp:
  Auto merged
storage/ndb/src/kernel/blocks/dbdict/Dbdict.cpp:
  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/QmgrMain.cpp:
  Auto merged
storage/ndb/src/kernel/error/ndbd_exit_codes.c:
  Auto merged
storage/ndb/src/kernel/vm/FastScheduler.cpp:
  Auto merged
storage/ndb/src/kernel/vm/TransporterCallback.cpp:
  Auto merged
storage/ndb/src/kernel/vm/VMSignal.hpp:
  Auto merged
storage/ndb/src/mgmapi/mgmapi.cpp:
  Auto merged
storage/ndb/src/mgmsrv/ConfigInfo.cpp:
  Auto merged
storage/ndb/src/mgmsrv/InitConfigFileParser.cpp:
  Auto merged
storage/ndb/src/mgmsrv/MgmtSrvr.cpp:
  Auto merged
storage/ndb/src/mgmsrv/MgmtSrvr.hpp:
  Auto merged
storage/ndb/src/mgmsrv/Services.cpp:
  Auto merged
storage/ndb/src/ndbapi/TransporterFacade.cpp:
  Auto merged
storage/ndb/test/ndbapi/testBackup.cpp:
  Auto merged
storage/ndb/test/ndbapi/testOperations.cpp:
  Auto merged
storage/ndb/test/src/HugoCalculator.cpp:
  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
BUILD/SETUP.sh:
  manual merge
configure.in:
  manual merge
mysql-test/r/alter_table.result:
  manual merge
sql/handler.cc:
  manual merge
sql/mysql_priv.h:
  manual merge
sql/records.cc:
  manual merge
sql/share/errmsg.txt:
  manual merge
sql/sql_table.cc:
  manual merge
  Fix labels
sql/sql_update.cc:
  manual merge
sql/table.cc:
  manual merge
sql/unireg.cc:
  manual merge
storage/ndb/config/type_ndbapi.mk.am:
  manual merge
2005-11-05 01:32:55 +02:00
unknown
17fcbcf772 BUG#14026: When doing the end-of-prepare fix up for TABLE_LISTs used in the PS, do the fixup
for underlying tables of a merge VIEWs, too.


mysql-test/r/view.result:
  Testcase for BUG#14026
mysql-test/t/view.test:
  Testcase for BUG#14026
2005-11-02 07:05:19 +03:00
unknown
cd49e32407 Merge rurik.mysql.com:/home/igor/mysql-5.0
into rurik.mysql.com:/home/igor/dev/mysql-5.0-2


sql/item.cc:
  Auto merged
sql/item.h:
  Auto merged
sql/item_cmpfunc.cc:
  Auto merged
sql/item_func.cc:
  Auto merged
sql/mysql_priv.h:
  Auto merged
sql/sql_class.cc:
  Auto merged
sql/sql_delete.cc:
  Auto merged
sql/sql_lex.cc:
  Auto merged
sql/sql_lex.h:
  Auto merged
sql/sql_parse.cc:
  Auto merged
sql/sql_update.cc:
  Auto merged
sql/sql_yacc.yy:
  Auto merged
2005-10-22 19:35:37 -07:00
unknown
ccc051cd40 fix for bug #12595 (ESCAPE must be exactly 1 character long)
ESCAPE has length of 1 if specified and sql_mode is NO_BACKSLASH_ESCAPES
or has length of 0 or 1 in every other situation.
(approved patch applied on a up-to-date tree re-commit) 


mysql-test/r/select.result:
  results of test for bug 12595
mysql-test/t/select.test:
  test for bug #12595 (ESCAPE must be exactly one character long)
sql/item_cmpfunc.cc:
  if ESCAPE was in the statement check whether its length is
  different than 1. In NO_BACKSLASH_ESCAPES mode only length of 1 is
  allowed, otherwise the length could be 0 or 1 character (code point
  in the sense of Unicode).
sql/item_cmpfunc.h:
  pass variable from the parsing stage - whether
  ESCAPE clause was found in the statement
sql/sql_help.cc:
  pass FALSE for escape_used_in_parsing because we
  want the default mode of no error checking - our internal code.
sql/sql_lex.cc:
  initialized variable used to transfer information during
  parsing up in the stack when reducing in the grammar
sql/sql_lex.h:
  new variable used for transfering information when
  reducing in the grammar.
sql/sql_yacc.yy:
  initialize Lex->escape_used and then use it when reducing.
  This is needed as fix for bug #12595 to distinguish between
  situation where ESCAPE was found and when not because internally
  we may pass a string an empty string and there is no other way
  to find out whether this is correct or not in case of 
  NO_BACKSLASH_ESCAPES mode, which allows only length of 1 if
  ESCAPE is part of the SQL statement.
2005-10-21 04:01:52 +03:00
unknown
6a0695fe93 Fixed bug #12762:
allowed set functions aggregated in outer subqueries, allowed nested set functions.


mysql-test/r/func_gconcat.result:
  Changed a query when fixing bug #12762.
mysql-test/r/subselect.result:
  Added test cases for bug #12762.
  Allowed set functions aggregated in outer subqueries. Allowed nested set functions.
mysql-test/t/func_gconcat.test:
  Changed a query when fixing bug #12762.
mysql-test/t/subselect.test:
  Added test cases for bug #12762.
  Allowed set functions aggregated in outer subqueries. Allowed nested set functions.
sql/item.cc:
  Fixed bug #12762:
  allowed set functions aggregated in outer subqueries, allowed nested set functions.
  Added a parameter to Item::split_sum_func2 aliowing to defer splitting for set functions
  aggregated in outer subquries.
  Changed Item_field::fix_fields to calculate attributes used when checking context conditions
  for set functions.
  Allowed alliases for set functions defined in outer subqueries.
sql/item.h:
  Fixed bug #12762:
  allowed set functions aggregated in outer subqueries, allowed nested set functions.
  Added a parameter to Item::split_sum_func2 aliowing to defer splitting for set functions
  aggregated in outer subquries.
sql/item_cmpfunc.cc:
  Fixed bug #12762:
  allowed set functions aggregated in outer subqueries, allowed nested set functions.
  Added a parameter to Item::split_sum_func2 aliowing to defer splitting for set functions
  aggregated in outer subquries.
sql/item_func.cc:
  Fixed bug #12762:
  allowed set functions aggregated in outer subqueries, allowed nested set functions.
  Added a parameter to Item::split_sum_func2 aliowing to defer splitting for set functions
  aggregated in outer subquries.
sql/item_row.cc:
  Fixed bug #12762:
  allowed set functions aggregated in outer subqueries, allowed nested set functions.
  Added a parameter to Item::split_sum_func2 aliowing to defer splitting for set functions
  aggregated in outer subquries.
sql/item_strfunc.cc:
  Fixed bug #12762:
  allowed set functions aggregated in outer subqueries, allowed nested set functions.
  Added a parameter to Item::split_sum_func2 aliowing to defer splitting for set functions
  aggregated in outer subquries.
sql/item_subselect.cc:
  Fixed bug #12762:
  allowed set functions aggregated in outer subqueries, allowed nested set functions.
  Introduced next levels for subqueries and a bitmap of nesting levels showing
  in what subqueries a set function can be aggregated.
sql/item_sum.cc:
  Fixed bug #12762:
  allowed set functions aggregated in outer subqueries, allowed nested set functions.
  Added Item_sum methods to check context conditions imposed on set functions.
sql/item_sum.h:
  Fixed bug #12762:
  allowed set functions aggregated in outer subqueries, allowed nested set functions.
  Added Item_sum methods to check context conditions imposed on set functions.
sql/mysql_priv.h:
  Fixed bug #12762:
  allowed set functions aggregated in outer subqueries, allowed nested set functions.
  Introduced a type of bitmaps to be used for nesting constructs.
sql/sql_base.cc:
  Fixed bug #12762:
  allowed set functions aggregated in outer subqueries, allowed nested set functions.
  Introduced next levels for subqueries and a bitmap of nesting levels showing
  in what subqueries a set function can be aggregated.
sql/sql_class.cc:
  Fixed bug #12762:
  allowed set functions aggregated in outer subqueries, allowed nested set functions.
  Introduced a bitmap of nesting levels showing in what subqueries a set function can be aggregated.
sql/sql_class.h:
  Fixed bug #12762:
  allowed set functions aggregated in outer subqueries, allowed nested set functions.
  Introduced a bitmap of nesting levels showing in what subqueries a set function can be aggregated.
sql/sql_delete.cc:
  Fixed bug #12762:
  allowed set functions aggregated in outer subqueries, allowed nested set functions.
  Introduced a bitmap of nesting levels showing in what subqueries a set function can be aggregated.
sql/sql_lex.cc:
  Fixed bug #12762:
  allowed set functions aggregated in outer subqueries, allowed nested set functions.
  Introduced next levels for subqueries and a bitmap of nesting levels showing
  in what subqueries a set function can be aggregated.
sql/sql_lex.h:
  Fixed bug #12762:
  allowed set functions aggregated in outer subqueries, allowed nested set functions.
  Introduced next levels for subqueries and a bitmap of nesting levels showing
  in what subqueries a set function can be aggregated.
sql/sql_parse.cc:
  Fixed bug #12762:
  allowed set functions aggregated in outer subqueries, allowed nested set functions.
  Introduced next levels for subqueries.
sql/sql_prepare.cc:
  Fixed bug #12762:
  allowed set functions aggregated in outer subqueries, allowed nested set functions.
  Introduced a bitmap of nesting levels showingin what subqueries a set function can be aggregated.
sql/sql_select.cc:
  Fixed bug #12762:
  allowed set functions aggregated in outer subqueries, allowed nested set functions.
  Introduced next levels for subqueries and a bitmap of nesting levels showing
  in what subqueries a set function can be aggregated.
sql/sql_update.cc:
  Fixed bug #12762:
  allowed set functions aggregated in outer subqueries, allowed nested set functions.
  Introduced a bitmap of nesting levels showing in what subqueries a set function can be aggregated.
sql/sql_yacc.yy:
  Fixed bug #12762:
  allowed set functions aggregated in outer subqueries, allowed nested set functions.
  Introduced next levels for subqueries.
2005-10-15 14:32:37 -07:00
unknown
785b7dbccf Manual merge of bug fix #7672
sql/sql_lex.h:
  Auto merged
2005-10-13 16:00:26 +04:00
unknown
a46e8e230e select.test, sql_select.cc, sql_lex.cc, item.cc:
Bug #7672 after merge fix


sql/item.cc:
  Bug #7672 after merge fix
sql/sql_lex.cc:
  Bug #7672 after merge fix
sql/sql_select.cc:
  Bug #7672 after merge fix
mysql-test/t/select.test:
  Bug #7672 after merge fix
2005-10-13 00:58:59 +04:00
unknown
b455f7c575 Manual merge, fix for bug #7672
mysql-test/r/select.result:
  Manual merge
mysql-test/t/select.test:
  Manual merge
sql/item.cc:
  Manual merge
sql/sql_lex.cc:
  Manual merge
sql/sql_lex.h:
  Manual merge
sql/sql_select.cc:
  Manual merge
2005-10-12 03:32:14 +04:00
unknown
f3f84ed8a0 Fix bug#7672 Unknown column error in order clause
When fixing Item_func_plus in ORDER BY clause field c is searched in all
opened tables, but because c is an alias it wasn't found there.

This patch adds a flag to select_lex which allows Item_field::fix_fields() 
to look up in select's item_list to find aliased fields.


sql/item.cc:
  Fix bug#7672 Unknown column error in order clause
  When fixing fields in ORDER BY clause allow Item_field::fix_fields() to look up items in select's item list to find aliased fields.
sql/sql_lex.cc:
   Fix bug#7672 Unknown column error in order clause
sql/sql_lex.h:
  Fix bug#7672 Unknown column error in order clause
  Added flag to select_lex allowing Item_field::fix_fields to look up items in select's item list.
sql/sql_select.cc:
  Fix bug#7672 Unknown column error in order clause
mysql-test/t/select.test:
  Test case for bug#7672 Unknown column error in order clause
mysql-test/r/select.result:
  Test case for bug#7672 Unknown column error in order clause
2005-10-09 23:05:44 +04:00
unknown
69bfcd9c40 Merge neptunus.(none):/home/msvensson/mysql/mysql-4.1
into  neptunus.(none):/home/msvensson/mysql/mysql-5.0


client/mysql.cc:
  Auto merged
client/mysqltest.c:
  Auto merged
mysql-test/mysql-test-run.pl:
  Auto merged
mysql-test/r/mysqltest.result:
  Auto merged
mysql-test/t/mysqltest.test:
  Auto merged
mysys/my_init.c:
  Auto merged
sql/sql_update.cc:
  Auto merged
Makefile.am:
  Manual merge
mysql-test/r/cast.result:
  Manual merge
mysql-test/t/cast.test:
  Manual merge
ndb/src/kernel/blocks/dbdict/printSchemaFile.cpp:
  Manual merge
sql/ha_ndbcluster.cc:
  Manual merge
sql/item.h:
  Manual merge
sql/opt_sum.cc:
  Manual merge
sql/sql_delete.cc:
  Manual merge
sql/sql_lex.cc:
  Manual merge
sql/sql_load.cc:
  Manual merge
sql/sql_prepare.cc:
  Manual merge
2005-09-28 11:34:53 +02:00
unknown
466b46a66a Fixed error found during review of new pushed code
client/mysql.cc:
  Don't use c_ptr() for cgets() and ensure buffer is not overwritten
mysql-test/r/cast.result:
  More test for CAST(0x.... as signed)
sql/opt_sum.cc:
  Fix bugs found during review
  - Changed code to be able to remove one if
  - Ensure that count == 0 only if is_exact_count == TRUE
sql/sql_delete.cc:
  Ensure 'allow_sum_func' is reset before call to setup_conds
sql/sql_lex.cc:
  allow_sum_func doesn't have to be reset for each query
  (It's to be reset in setup_fields() or before call to setup_conds()
sql/sql_load.cc:
  Move set of auto_increment_field_not_null so that it's not set if field value is NULL
sql/sql_prepare.cc:
  allow_sum_func doesn't have to be reset for each query
  (It's to be reset in setup_fields() or before call to setup_conds()
sql/sql_update.cc:
  Ensure 'allow_sum_func' is reset before call to setup_conds
2005-09-25 21:22:23 +03:00
unknown
c64d0fc634 Manual merge
mysql-test/r/update.result:
  Auto merged
mysql-test/t/update.test:
  Auto merged
2005-09-22 02:38:14 +04:00
unknown
1b02a815dd Fix bug #13180 thd->allow_sum_funcs wasn't reset before query processing.
thd->allow_sum_func was left 'true' after previous statement thus allowing
sum funcs to be present in conditions.

thd->allow_sum_func should be set to 0 for each query and each prepared
statement reinitialization. This is done in lex_start() and 
reset_stmt_for_execute().


sql/sql_lex.cc:
  Fix bug#13180 thd->allow_sum_func wasn't reset obefore query processing.
  thd->allow_sum_func is set to 0 in lex_start().
sql/sql_prepare.cc:
  Fix bug#13180 thd->allow_sum_func wasn't reset obefore query processing.
  thd->allow_sum_func is set to 0 in  reset_stmt_for_execute().
mysql-test/t/update.test:
  Test case for bug#13180 thd->allow_sum_funcs wasn't reset before query
  processing.
mysql-test/r/update.result:
  Test case for bug#13180 thd->allow_sum_funcs wasn't reset before query
  processing.
2005-09-22 01:38:39 +04: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
f6c1d4191c Merge
Makefile.am:
  Auto merged
BitKeeper/etc/config:
  Auto merged
scripts/Makefile.am:
  Auto merged
sql/ha_federated.h:
  Auto merged
sql/ha_innodb.cc:
  Auto merged
sql/item.cc:
  Auto merged
sql/item_subselect.cc:
  Auto merged
sql/mysql_priv.h:
  Auto merged
sql/set_var.cc:
  Auto merged
sql/sp.cc:
  Auto merged
sql/sql_base.cc:
  Auto merged
sql/sql_class.h:
  Auto merged
sql/sql_delete.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_select.cc:
  Auto merged
sql/sql_show.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/innobase/include/page0page.ic:
  Auto merged
storage/innobase/include/univ.i:
  Auto merged
storage/innobase/row/row0mysql.c:
  Auto merged
storage/innobase/row/row0sel.c:
  Auto merged
storage/myisam/mi_check.c:
  Auto merged
storage/myisam/mi_packrec.c:
  Auto merged
storage/myisam/mi_static.c:
  Auto merged
storage/myisam/myisamdef.h:
  Auto merged
storage/myisam/myisampack.c:
  Auto merged
storage/ndb/include/kernel/signaldata/SignalData.hpp:
  Auto merged
storage/ndb/include/kernel/signaldata/StartFragReq.hpp:
  Auto merged
storage/ndb/src/common/debugger/EventLogger.cpp:
  Auto merged
storage/ndb/src/common/debugger/signaldata/SignalDataPrint.cpp:
  Auto merged
storage/ndb/src/common/debugger/signaldata/StartRec.cpp:
  Auto merged
storage/ndb/src/kernel/blocks/dbdih/DbdihMain.cpp:
  Auto merged
storage/ndb/src/kernel/blocks/dblqh/redoLogReader/records.cpp:
  Auto merged
storage/ndb/src/kernel/blocks/dblqh/redoLogReader/records.hpp:
  Auto merged
storage/ndb/src/kernel/blocks/dblqh/redoLogReader/redoLogFileReader.cpp:
  Auto merged
storage/ndb/src/kernel/main.cpp:
  Auto merged
storage/ndb/src/kernel/blocks/dbtc/DbtcMain.cpp:
  Auto merged
storage/ndb/src/kernel/vm/Emulator.cpp:
  Auto merged
sql/log_event.cc:
  SCCS merged
sql/sql_prepare.cc:
  SCCS merged
sql/share/errmsg.txt:
  merge
2005-09-06 09:20:15 +02:00
unknown
c910050a76 Implement WL#2661 "Prepared Statements: Dynamic SQL in Stored Procedures".
The idea of the patch is to separate statement processing logic,
such as parsing, validation of the parsed tree, execution and cleanup, 
from global query processing logic, such as logging, resetting
priorities of a thread, resetting stored procedure cache, resetting
thread count of errors and warnings.
This makes PREPARE and EXECUTE behave similarly to the rest of SQL
statements and allows their use in stored procedures.
This patch contains a change in behaviour:
until recently for each SQL prepared statement command, 2 queries
were written to the general log, e.g.
[Query]   prepare stmt from @stmt_text;
[Prepare] select * from t1 <-- contents of @stmt_text
The chagne was necessary to prevent [Prepare] commands from being written
to the general log when executing a stored procedure with Dynamic SQL.
We should consider whether the old behavior is preferrable and probably
restore it.
This patch refixes Bug#7115, Bug#10975 (partially), Bug#10605 (various bugs
in Dynamic SQL reported before it was disabled).


mysql-test/r/not_embedded_server.result:
  Since we don't want to log Dynamic SQL in stored procedures,
  now the general log gets only one log entry per SQL statement.
mysql-test/r/sp-error.result:
  - remove obsolete tests
  - a better error message for the case when a stored procedure that
  returns a result set is called from a function
mysql-test/r/trigger.result:
  - a better error message for the case when a stored procedure that
  returns a result set is called from a trigger
mysql-test/t/sp-error.test:
  - a better error message for the case when a stored procedure that
    returns a result set is called from a function.
  - move the comment to its place (end of file).
mysql-test/t/trigger.test:
  - a better error message for the case when a stored procedure that
  returns a result set is called from a trigger
sql/item_func.cc:
  - we need to pass sql_command explicitly to get_var_with_binlog, because
  when creating a query for SQL prepared statement thd->lex->sql_command
  points at SQLCOM_EXECUTE, which is not listed in the list of update
  queries.
sql/log_event.h:
  - remove an extra copy of the previous sentence
sql/mysql_priv.h:
  - fix declarations of sql_prepare.cc API
sql/share/errmsg.txt:
  - a new error message, when one attempts to execute a prepared statement
  which is currently being executed (this can happen only in Dynamic SQL
  at the moment).
sql/sp_head.cc:
  - extend sp_multi_results_command to return different flags for a
  command (and rename it)
  - add support for SQLCOM_PREPARE,SQLCOM_EXECUTE, SQLCOM_DEALLOCATE
    to sp_get_flags_for_command
  - replace multiple boolean sp_head members with uint m_flags
  - a fix for a crash when user variables are used in a stored procedure
    and binlog is on. A temporary fix for Bug#12637 "SP crashes the server 
   if it has update query with user var & binlog is enabled", which actually
   stands for stored functions: now instead of a crash we break
   replication if a user variable is used in a stored function which 
   is executed in prelocked mode.
sql/sp_head.h:
  - replace multiple boolean flags of sp_head with uint m_flags;
  - add flag CONTAINS_DYNAMIC_SQL
  - use this flag to error if a stored procedure with Dynamic SQL is
    called from a function or trigger.
sql/sql_class.cc:
  - Statement_map::insert should not delete a statement if it exists,
    now it's done externally to be able to handle the case when the
    statement being deleted is in use.
  - remove extra code (free_list is already reset in free_items)
sql/sql_lex.cc:
  - add lex->stmt_prepare_mode; we can't rely on thd->command any more,
    because we don't reset it any more (Dynamic SQL requirement is that
    PS are as little intrusive as possible).
sql/sql_lex.h:
  - declare bool LEX::stmt_prepare_mode
sql/sql_parse.cc:
  - move prepared statement code to sql_prepare.cc
  - change declarations (refactored code)
  - better error message when one attempts to use Dynamic SQL or a 
    stored procedure that returns a result set in a function or trigger.
sql/sql_prepare.cc:
  - major refactoring to ensure PREPARE/EXECUTE commands do not reset global THD
    state and allow their use in stored procedures.
  - add Prepared_statement::flags and use it to ensure no recursive execution
    of a prepared statement is possible
  - better comments
sql/sql_yacc.yy:
  - enable PREPARE/EXECUTE/DEALLOCATE in stored procedures
  - produce an error message on attempt to use PREPARE/EXECUTE/DEALLOCATE
    in a stored function or trigger
mysql-test/r/sp-dynamic.result:
  - sp-dynamic.test results
mysql-test/t/sp-dynamic.test:
  - a new test for PREPARE/EXECUTE/DEALLOCATE in stored procedures.
2005-09-03 03:13:18 +04:00
unknown
dc92221300 Rename:
- current_arena to stmt_arena: the thread may have more than one
'current' arenas: one for runtime data, and one for the parsed 
tree of a statement. Only one of them is active at any moment.
- set_item_arena -> set_query_arena, because Item_arena was renamed to 
Query_arena a while ago
- set_n_backup_item_arena -> set_n_backup_active_arena;
the active arena is the arena thd->mem_root and thd->free_list
are currently pointing at.
- restore_backup_item_arena -> restore_active_arena (with the same
rationale)
- change_arena_if_needed -> activate_stmt_arena_if_needed; this
method sets thd->stmt_arena active if it's not done yet.


sql/item.cc:
  Rename.
sql/item_cmpfunc.cc:
  Rename.
sql/item_func.cc:
  Rename.
sql/item_subselect.cc:
  Rename.
sql/item_subselect.h:
  Remove an unused forward declaration.
sql/item_sum.h:
  Remove an unused forward declaration.
sql/mysql_priv.h:
  Remove an unused forward declaration.
sql/sp.cc:
  Rename.
sql/sp_head.cc:
  Rename.
sql/sql_base.cc:
  Rename.
sql/sql_class.cc:
  Rename.
sql/sql_class.h:
  Rename.
sql/sql_lex.cc:
  Rename.
sql/sql_parse.cc:
  Rename.
sql/sql_prepare.cc:
  Rename.
sql/sql_select.cc:
  Rename.
sql/sql_show.cc:
  Rename.
sql/sql_union.cc:
  Rename.
sql/sql_view.cc:
  Rename.
sql/table.cc:
  Rename.
2005-09-02 17:21:19 +04:00
unknown
9ea1d5e293 Merge zim.(none):/home/brian/mysql/mysql-5.0
into  zim.(none):/home/brian/mysql/mysql-5.1

Resolved to minor issues. 


BitKeeper/etc/config:
  Auto merged
Makefile.am:
  Auto merged
VC++Files/sql/mysqld.vcproj:
  Auto merged
extra/perror.c:
  Auto merged
include/my_global.h:
  Auto merged
mysql-test/mysql-test-run.pl:
  Auto merged
mysql-test/mysql-test-run.sh:
  Auto merged
mysql-test/t/alter_table.test:
  Auto merged
mysql-test/t/disabled.def:
  Auto merged
mysys/Makefile.am:
  Auto merged
scripts/mysql_fix_privilege_tables.sql:
  Auto merged
sql/Makefile.am:
  Auto merged
sql/ha_innodb.cc:
  Auto merged
sql/ha_innodb.h:
  Auto merged
sql/handler.h:
  Auto merged
sql/item.cc:
  Auto merged
sql/lex.h:
  Auto merged
sql/log.cc:
  Auto merged
sql/mysql_priv.h:
  Auto merged
sql/mysqld.cc:
  Auto merged
sql/opt_range.cc:
  Auto merged
sql/set_var.cc:
  Auto merged
sql/sp.cc:
  Auto merged
sql/sql_class.h:
  Auto merged
sql/sql_delete.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_select.cc:
  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/examples/ha_tina.cc:
  Auto merged
sql/table.h:
  Auto merged
sql/unireg.h:
  Auto merged
storage/innobase/lock/lock0lock.c:
  Auto merged
storage/myisam/mi_check.c:
  Auto merged
storage/myisam/mi_search.c:
  Auto merged
storage/myisam/myisamchk.c:
  Auto merged
storage/myisam/myisamlog.c:
  Auto merged
storage/myisam/myisampack.c:
  Auto merged
storage/ndb/src/kernel/blocks/dbdict/Dbdict.cpp:
  Auto merged
configure.in:
  Fixed the resolve of versions.
mysql-test/r/alter_table.result:
  Fixed results.
2005-08-30 14:40:02 -07: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
8a5e527453 Fix for BUG#12335 (SP replication) : New binlogging strategy for stored PROCEDUREs/FUNCTIONs.
"Interleaved SPs execution is now binlogged properly, "SELECT spfunc()" is binlogged too.
The known remaining issue is binlogging/replication of "a routine is deleted while it is executed" scenario.


mysql-test/r/rpl_sp.result:
  Fix for BUG#12335: updated test cases/results
mysql-test/t/rpl_sp.test:
  Fix for BUG#12335: updated test cases/results
sql/item.cc:
  Fix for BUG#12335 (SP replication): 
   - Added Item_name_const 'function'
   - Addede 'delete reuse' to call dtor on item reuse
sql/item.h:
  Fix for BUG#12335 (SP replication) : Added Item_name_const 'function' + code cleanup
sql/item_create.cc:
   Fix for BUG#12335 (SP replication) : Added Item_name_const 'function'
sql/item_create.h:
   Fix for BUG#12335 (SP replication) : Added Item_name_const 'function'
sql/item_func.cc:
  Fix for BUG#12335 (SP replication) : binary log is now constrolled from within execute_function.
sql/lex.h:
  Fix for BUG#12335 (SP replication) : Added Item_name_const 'function'
sql/log.cc:
  Fix for BUG#12335 (SP replication) : Added MYSQL_LOG::{start|stop}_union_events to allow
  one to temporary disable binlogging but collect a 'union' information about binlog write
  calls.
sql/mysql_priv.h:
  Fix for BUG#12335 (SP replication)
sql/sp_head.cc:
  Fix for BUG#12335 (SP replication) : Now we use different SP binlogging strategy, grep for 
  StoredRoutinesBinlogging for details
sql/sp_head.h:
  Comments added
sql/sp_pcontext.h:
  Comments added
sql/sp_rcontext.h:
  Comments added
sql/sql_class.cc:
  Fix for BUG#12335 (SP replication) : Now we use different SP binlogging strategy, grep for 
  StoredRoutinesBinlogging for details
sql/sql_class.h:
  Fix for BUG#12335 (SP replication) : Added MYSQL_LOG::{start|stop}_union_events to allow
  one to temporary disable binlogging but collect a 'union' information about binlog write
  calls.
sql/sql_delete.cc:
  Fix for BUG#12335: check THD::query_str_binlog_unsuitable when writing to binlog.
sql/sql_insert.cc:
  Fix for BUG#12335: check THD::query_str_binlog_unsuitable when writing to binlog.
sql/sql_lex.cc:
  Fix for BUG#12335 (SP replication): Add ability to extract previous returned token from
  the tokenizer.
sql/sql_lex.h:
  Fix for BUG#12335 (SP replication): Add ability to extract previous returned token from
  the tokenizer.
sql/sql_parse.cc:
  Fix for BUG#12335 (SP replication) : Now we use different SP binlogging strategy, grep for 
  StoredRoutinesBinlogging for details
sql/sql_update.cc:
  Fix for BUG#12335: check THD::query_str_binlog_unsuitable when writing to binlog.
sql/sql_yacc.yy:
  Fix for BUG#12335 (SP replication) : When creating Item_splocal, remember where it is located
  in the query.
2005-08-25 17:34:34 +04:00
unknown
72340a481a Cleanup during review of new pushed code
include/my_global.h:
  Safer macros to avoid possible overflows
sql/item_cmpfunc.cc:
  Simple optimization
sql/sp_head.cc:
  Indentation fixes
  Remove not needed "else" levels
  Added error checking for 'new'
  Simpler reseting of thd->spcont in execute_procedure
sql/sql_base.cc:
  Faster new
sql/sql_lex.cc:
  Use 'TRUE' instead of 'true'
sql/sql_parse.cc:
  Faster new
sql/sql_view.cc:
  No need to set 'tables' as it's not used
sql/table.cc:
  Simpler DBUG_ASSERT()
2005-08-22 01:13:37 +03:00
unknown
88a7d01eba Merge epotemkin@bk-internal.mysql.com:/home/bk/mysql-5.0
into moonbone.local:/work/10624-bug-5.0-mysql


sql/sql_lex.cc:
  Auto merged
2005-08-18 22:46:17 +04:00
unknown
44086a625b Cleanups and optimization during review of new code
mysql-test/t/kill.test:
  Moved --disable_reconnect earlier to avoid race condition
sql/sql_help.cc:
  Cleanup during review of new code
  (Moved variable definitions first in function
sql/sql_insert.cc:
  Cleanup during review of new code
sql/sql_lex.cc:
  Cleanup during review of new code
sql/sql_parse.cc:
  Cleanup during review of new code
  Changed potential problem with previous_table_ref where it dependent that TABLE_LIST first element would be next_local
  Rearanged code in add_table_to_list() to remove extra if
  Combined 2 calls to calloc() to one
sql/sql_view.cc:
  Remove extra indentation level
  Combined common 'on error' exit
sql/sql_yacc.yy:
  Fixed comment style
sql/table.cc:
  Cleanup during review of new code
  - Changed while() loops to for() loop (to make code more readable)
  - Removed not needed initialization of variables
  - Removed not needed 'else' cases
  - Removed trivial ASSERT's that was checked by previous code
  - Moved comment setting last in Natural_join_column::check_grants()
2005-08-18 03:12:42 +03:00
unknown
def42df9fe Fix bug #10624 Views with multiple UNION and UNION ALL produce incorrect
results.

st_select_lex_unit::print() was losing UNION ALL if in statement were present
UNION DISTINCT.


mysql-test/r/view.result:
  Test case for bug #10624  Views with multiple UNION and UNION ALL produce incorrect results.
mysql-test/t/view.test:
  Test case for bug #10624  Views with multiple UNION and UNION ALL produce incorrect results.
sql/sql_lex.cc:
  Fix bug #10624 Views with multiple UNION and UNION ALL produce incorrect results.
2005-08-15 23:05:05 +04:00
unknown
2b53b711d8 Merge mysql.com:/home/timka/mysql/src/5.0-virgin
into  mysql.com:/home/timka/mysql/src/5.0-2486-merge


mysql-test/r/errors.result:
  Auto merged
mysql-test/r/fulltext.result:
  Auto merged
mysql-test/r/fulltext_order_by.result:
  Auto merged
mysql-test/r/innodb.result:
  Auto merged
mysql-test/r/join_nested.result:
  Auto merged
mysql-test/r/subselect.result:
  Auto merged
mysql-test/t/errors.test:
  Auto merged
mysql-test/t/fulltext.test:
  Auto merged
mysql-test/t/fulltext_order_by.test:
  Auto merged
mysql-test/t/innodb.test:
  Auto merged
mysql-test/t/join_nested.test:
  Auto merged
mysql-test/t/subselect.test:
  Auto merged
sql/item.cc:
  Auto merged
sql/mysql_priv.h:
  Auto merged
sql/sp.cc:
  Auto merged
sql/sql_base.cc:
  Auto merged
sql/sql_class.h:
  Auto merged
sql/sql_delete.cc:
  Auto merged
sql/sql_lex.cc:
  Auto merged
sql/sql_lex.h:
  Auto merged
sql/sql_parse.cc:
  Auto merged
sql/sql_select.cc:
  Auto merged
sql/sql_update.cc:
  Auto merged
sql/sql_yacc.yy:
  Auto merged
sql/table.h:
  Auto merged
tests/mysql_client_test.c:
  Auto merged
sql/sql_insert.cc:
  merge WL#2486
sql/sql_show.cc:
  merge WL#2486
2005-08-12 19:27:54 +03:00
unknown
7517d7e112 Implementation of WL#2486 -
"Process NATURAL and USING joins according to SQL:2003".

* Some of the main problems fixed by the patch:
  - in "select *" queries the * expanded correctly according to
    ANSI for arbitrary natural/using joins
  - natural/using joins are correctly transformed into JOIN ... ON
    for any number/nesting of the joins.
  - column references are correctly resolved against natural joins
    of any nesting and combined with arbitrary other joins.

* This patch also contains a fix for name resolution of items
  inside the ON condition of JOIN ... ON - in this case items must
  be resolved only against the JOIN operands. To support such
  'local' name resolution, the patch introduces a stack of
  name resolution contexts used at parse time.

NOTICE:
- This patch is not complete in the sense that
  - there are 2 test cases that still do not pass -
    one in join.test, one in select.test. Both are marked
    with a comment "TODO: WL#2486".
  - it does not include a new test specific for the task


mysql-test/include/ps_query.inc:
  Adjusted according to standard NATURAL/USING join semantics.,
mysql-test/r/bdb.result:
  Adjusted according to standard NATURAL/USING join semantics.
mysql-test/r/derived.result:
  Adjusted according to standard NATURAL/USING join semantics.
mysql-test/r/errors.result:
  The column as a whole cannot be resolved, so different error message.
mysql-test/r/fulltext.result:
  Adjusted according to standard JOIN ... ON semantics =>
  the ON condition can refer only to the join operands.
mysql-test/r/fulltext_order_by.result:
  More detailed error message.
mysql-test/r/innodb.result:
  Adjusted according to standard NATURAL/USING join semantics.
  This test doesn't pass completetly yet!
mysql-test/r/insert_select.result:
  More detailed error message.
mysql-test/r/join.result:
  Adjusted according to standard NATURAL/USING join semantics.
  
  NOTICE: there is one test case that still fails, and it is
  commeted out and marked with WL#2486 in the test file.
mysql-test/r/join_crash.result:
  Adjusted according to standard NATURAL/USING join semantics.
mysql-test/r/join_nested.result:
  Adjusted according to standard NATURAL/USING join semantics.
mysql-test/r/join_outer.result:
  Adjusted according to standard NATURAL/USING join semantics.
mysql-test/r/multi_update.result:
  Adjusted according to standard NATURAL/USING join semantics.
mysql-test/r/null_key.result:
  Adjusted according to standard NATURAL/USING join semantics.
mysql-test/r/order_by.result:
  Adjusted according to standard NATURAL/USING join semantics.
mysql-test/r/ps_2myisam.result:
  Adjusted according to standard NATURAL/USING join semantics.
mysql-test/r/ps_3innodb.result:
  Adjusted according to standard NATURAL/USING join semantics.
mysql-test/r/ps_4heap.result:
  Adjusted according to standard NATURAL/USING join semantics.
mysql-test/r/ps_5merge.result:
  Adjusted according to standard NATURAL/USING join semantics.
mysql-test/r/ps_6bdb.result:
  Adjusted according to standard NATURAL/USING join semantics.
mysql-test/r/ps_7ndb.result:
  Adjusted according to standard NATURAL/USING join semantics.
mysql-test/r/select.result:
  Adjusted according to standard NATURAL/USING join semantics.
  
  NOTICE: there is one failing test case which is commented with
  WL#2486 in the test file.
mysql-test/r/subselect.result:
  Adjusted according to standard NATURAL/USING join semantics.
mysql-test/r/type_ranges.result:
  Adjusted according to standard NATURAL/USING join semantics.
mysql-test/r/union.result:
  More detailed error message.
mysql-test/t/bdb.test:
  Adjusted according to standard NATURAL/USING join semantics.
mysql-test/t/errors.test:
  Adjusted according to standard NATURAL/USING join semantics.
mysql-test/t/fulltext.test:
  Adjusted according to standard JOIN ... ON semantics =>
  the ON condition can refer only to the join operands.
mysql-test/t/fulltext_order_by.test:
  More detailed error message.
mysql-test/t/innodb.test:
  Adjusted according to standard NATURAL/USING join semantics.
  This test doesn't pass completetly yet!
mysql-test/t/insert_select.test:
  More detailed error message.
mysql-test/t/join.test:
  Adjusted according to standard NATURAL/USING join semantics.
  
  NOTICE: there is one test case that still fails, and it is
  commeted out and marked with WL#2486 in the test file.
mysql-test/t/join_crash.test:
  Adjusted according to standard NATURAL/USING join semantics.
mysql-test/t/join_nested.test:
  Adjusted according to standard NATURAL/USING join semantics.
mysql-test/t/join_outer.test:
  Adjusted according to standard NATURAL/USING join semantics.
mysql-test/t/null_key.test:
  Adjusted according to standard NATURAL/USING join semantics.
mysql-test/t/order_by.test:
  Adjusted according to standard NATURAL/USING join semantics.
mysql-test/t/select.test:
  Adjusted according to standard NATURAL/USING join semantics.
  
  NOTICE: there is one test case that still fails, and it is
  commeted out and marked with WL#2486 in the test file.
mysql-test/t/subselect.test:
  Adjusted according to standard NATURAL/USING join semantics.
mysql-test/t/type_ranges.test:
  Adjusted according to standard NATURAL/USING join semantics.
mysql-test/t/union.test:
  More detailed error message.
sql/item.cc:
  - extra parameter to find_field_in_tables
  - find_field_in_real_table renamed to find_field_in_table
  - fixed comments/typos
sql/item.h:
  - added [first | last]_name_resolution_table to class
    Name_resolution_context
  - commented old code
  - standardized formatting
sql/mysql_priv.h:
  - refactored the find_field_in_XXX procedures,
  - added a new procedure for natural join table references,
  - renamed the find_field_in_XXX procedures to clearer names
sql/sp.cc:
  - pass the top-most list of the FROM clause to setup_tables
  - extra parameter to find_field_in_tables
sql/sql_acl.cc:
  - renamed find_field_in_table => find_field_in_table_ref
  - extra parameter to find_field_in_table_ref
  - commented old code
sql/sql_base.cc:
  This file contains the core of the implementation of the processing
  of NATURAL/USING joins (WL#2486).
  - added many comments to old code
  - refactored the group of find_field_in_XXX procedures, and added a
    new procedure for natural joins. There is one find_field_in_XXX procedure
    per each type of table reference (stored table, merge view, or natural
    join); one meta-procedure that selects the correct one depeneding on the
    table reference; and one procedure that goes over a list of table
    referenes.
  - NATURAL/USING joins are processed through the procedures:
      mark_common_columns, store_natural_using_join_columns,
      store_top_level_join_columns, setup_natural_join_row_types.
    The entry point to processing NATURAL/USING joins is the
    procedure 'setup_natural_join_row_types'.
  - Replaced the specialized Field_iterator_XXX iterators with one
    generic iterator over the fields of a table reference.
  - Simplified 'insert_fields' and 'setup_conds' due to encapsulation of
    the processing of natural joins in a separate set of procedures.
sql/sql_class.h:
  - Commented old code.
sql/sql_delete.cc:
  - Pass the FROM clause to setup_tables.
sql/sql_help.cc:
  - pass the end name resolution table to find_field_in_tables
  - adjust the list of tables for name resolution
sql/sql_insert.cc:
  - Changed the code that saves and restores the current context to
    support the list of tables for name resolution -
    context->first_name_resolution_table, and
    table_list->next_name_resolution_table.
    Needed to support an ugly trick to resolve inserted columns only in
    the first table.
  - Added Name_resolution_context::[first | last]_name_resolution_table.
  - Commented old code
sql/sql_lex.cc:
  - set select_lex.parent_lex correctly
  - set correct state of the current name resolution context
sql/sql_lex.h:
  - Added a stack of name resolution contexts to support local
    contexts for JOIN ... ON conditions.
  - Commented old code.
sql/sql_load.cc:
  - Pass the FROM clause to setup_tables.
sql/sql_olap.cc:
  - Pass the FROM clause to setup_tables.
sql/sql_parse.cc:
  - correctly set SELECT_LEX::parent_lex
  - set the first table of the current name resoltion context
  - added support for NATURAL/USING joins
  - commented old code
sql/sql_select.cc:
  - Pass the FROM clause to setup_tables.
  - Pass the end table to find_field_in_tables
  - Improved comments
sql/sql_show.cc:
  - Set SELECT_LEX::parent_lex.
sql/sql_update.cc:
  - Pass the FROM clause to setup_tables.
sql/sql_yacc.yy:
  - Added support for a stack of name resolution contexts needed to
    implement name resolution for JOIN ... ON. A context is pushed
    for each new JOIN ... ON, and popped afterwards.
  - Added support for NATURAL/USING joins.
sql/table.cc:
  - Added new class Natural_join_column to hide the heterogeneous
    representation of column references for stored tables and for
    views.
  - Added a new list TABLE_LIST::next_name_resolution_table to
    support name resolution with NATURAL/USING joins. Also added
    other members to TABLE_LIST to support NATURAL/USING joins.
  - Added a generic iterator over the fields of table references
    of various types - class Field_iterator_table_ref
sql/table.h:
  - Added new class Natural_join_column to hide the heterogeneous
    representation of column references for stored tables and for
    views.
  - Added a new list TABLE_LIST::next_name_resolution_table to
    support name resolution with NATURAL/USING joins. Also added
    other members to TABLE_LIST to support NATURAL/USING joins.
  - Added a generic iterator over the fields of table references
    of various types - class Field_iterator_table_ref
tests/mysql_client_test.c:
  Adjusted according to standard NATURAL JOIN syntax.
2005-08-12 17:57:19 +03:00
unknown
aca6f88ebb Merge mronstrom@bk-internal.mysql.com:/home/bk/mysql-5.0
into  c-8b0ae253.1238-1-64736c10.cust.bredbandsbolaget.se:/home/pappa/mysql-5.1


BitKeeper/etc/config:
  Auto merged
mysql-test/mysql-test-run.pl:
  Auto merged
mysql-test/r/information_schema_db.result:
  Auto merged
mysql-test/t/disabled.def:
  Auto merged
mysys/default.c:
  Auto merged
scripts/Makefile.am:
  Auto merged
scripts/mysql_create_system_tables.sh:
  Auto merged
scripts/mysql_fix_privilege_tables.sql:
  Auto merged
sql/field.cc:
  Auto merged
sql/field.h:
  Auto merged
sql/ha_federated.cc:
  Auto merged
sql/ha_innodb.cc:
  Auto merged
sql/ha_innodb.h:
  Auto merged
sql/ha_ndbcluster.cc:
  Auto merged
sql/ha_ndbcluster.h:
  Auto merged
sql/handler.cc:
  Auto merged
sql/item.cc:
  Auto merged
sql/lock.cc:
  Auto merged
sql/log.cc:
  Auto merged
sql/mysql_priv.h:
  Auto merged
sql/mysqld.cc:
  Auto merged
sql/set_var.cc:
  Auto merged
sql/set_var.h:
  Auto merged
sql/slave.cc:
  Auto merged
sql/slave.h:
  Auto merged
sql/sp.cc:
  Auto merged
sql/sql_acl.cc:
  Auto merged
sql/sql_base.cc:
  Auto merged
sql/sql_cache.cc:
  Auto merged
sql/sql_class.h:
  Auto merged
sql/sql_insert.cc:
  Auto merged
sql/sql_lex.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/table.cc:
  Auto merged
sql/table.h:
  Auto merged
sql/tztime.cc:
  Auto merged
sql/unireg.cc:
  Auto merged
storage/innobase/buf/buf0buf.c:
  Auto merged
storage/innobase/include/os0file.h:
  Auto merged
storage/innobase/include/read0read.h:
  Auto merged
storage/innobase/include/read0types.h:
  Auto merged
storage/innobase/include/trx0trx.h:
  Auto merged
storage/innobase/os/os0file.c:
  Auto merged
storage/innobase/read/read0read.c:
  Auto merged
storage/innobase/row/row0sel.c:
  Auto merged
storage/innobase/srv/srv0srv.c:
  Auto merged
storage/innobase/srv/srv0start.c:
  Auto merged
storage/innobase/trx/trx0sys.c:
  Auto merged
storage/innobase/trx/trx0trx.c:
  Auto merged
storage/myisam/mi_create.c:
  Auto merged
storage/myisam/sort.c:
  Auto merged
storage/ndb/include/mgmapi/mgmapi.h:
  Auto merged
storage/ndb/include/mgmapi/mgmapi_config_parameters.h:
  Auto merged
storage/ndb/src/common/portlib/NdbMutex.c:
  Auto merged
storage/ndb/src/common/portlib/NdbThread.c:
  Auto merged
storage/ndb/src/kernel/blocks/dbacc/DbaccMain.cpp:
  Auto merged
storage/ndb/src/kernel/blocks/dbtup/DbtupGen.cpp:
  Auto merged
storage/ndb/src/mgmapi/mgmapi.cpp:
  Auto merged
storage/ndb/src/mgmsrv/ConfigInfo.cpp:
  Auto merged
storage/ndb/src/mgmsrv/ConfigInfo.hpp:
  Auto merged
strings/ctype-big5.c:
  Auto merged
strings/ctype-ucs2.c:
  Auto merged
support-files/mysql.spec.sh:
  Auto merged
configure.in:
  Manual merge 5.0 -> 5.1
mysql-test/t/alter_table.test:
  Manual merge 5.0 -> 5.1
sql/share/errmsg.txt:
  Manual merge 5.0 -> 5.1
storage/ndb/tools/Makefile.am:
  Manual merge 5.0 -> 5.1
2005-08-05 18:01:34 -04:00
unknown
e442059c0d Manual merge
mysql-test/r/sp.result:
  Auto merged
mysql-test/r/view.result:
  Auto merged
mysql-test/t/view.test:
  Auto merged
sql/item_func.cc:
  Auto merged
sql/sp.cc:
  Auto merged
sql/sp_head.cc:
  Auto merged
sql/sp_head.h:
  Auto merged
sql/sql_base.cc:
  Auto merged
sql/sql_class.cc:
  Auto merged
sql/sql_class.h:
  Auto merged
sql/sql_lex.cc:
  Auto merged
sql/sql_parse.cc:
  Auto merged
sql/sql_trigger.h:
  Auto merged
2005-08-03 03:47:07 +00:00
unknown
11abe15eab Added Non-prelocked SP execution: Now a PROCEDURE doesn't enter/leave prelocked mode for
its body, but lets each statement to get/release its own locks. This allows a broader set
of statements to be executed inside PROCEDUREs (but breaks replication)
This patch should fix BUG#8072, BUG#8766, BUG#9563, BUG#11126


mysql-test/r/sp-security.result:
  Drop tables this test attempts to create
mysql-test/r/sp-threads.result:
  Update test results
mysql-test/r/sp.result:
  Disabled a test that triggers BUG#11986, cleanup used tables when tests start.
mysql-test/r/view.result:
  Enabled a test case that now works with prelocking-free SPs
mysql-test/t/sp-security.test:
  Drop tables this test attempts to create
mysql-test/t/sp.test:
  Disabled a test that triggers BUG#11986, cleanup used tables when tests start.
mysql-test/t/view.test:
  Enabled a test case that now works with prelocking-free SPs
sql/handler.cc:
  Rename: thd->transaction.in_sub_stmt -> thd->in_sub_stmt
sql/item_func.cc:
  Rename: thd->transaction.in_sub_stmt -> thd->in_sub_stmt
sql/sp.cc:
  Non-prelocked SP execution: Added support for skipping prelocking of procedure body for
  "CALL proc(...)" statements.
sql/sp.h:
  Non-prelocked SP execution: Added support for skipping prelocking of procedure body for
  "CALL proc(...)" statements.
sql/sp_cache.h:
  Added comments
sql/sp_head.cc:
  Non-prelocked SP execution:
  * Try to unlock tables after PROCEDURE arguments have been evaluated.
  * Make sp_lex_keeper be able to execute in 2 modes: A) when already in prelocked mode
    B) when its statement enters/leaves prelocked mode itself.
sql/sp_head.h:
  Non-prelocked SP execution:  Make sp_lex_keeper to additionally keep list of tables it 
  needs to prelock when its statement enters/leaves prelocked mode on its own.
sql/sql_base.cc:
  Non-prelocked SP execution: Make open_tables() to
   * detect 'CALL proc(...)' and not to do prelocking for procedure body statements.
   * Make lex->query_tables_last to point precisely to a boundary in lex->query_tables 
     list where 'own' tables and views' tables end and added-for-prelocking tables begin.
     (it was not true before - view's tables could end up after query_tables_own_last)
sql/sql_class.cc:
  Rename: thd->transaction.in_sub_stmt -> thd->in_sub_stmt
sql/sql_class.h:
  Rename: thd->transaction.in_sub_stmt -> thd->in_sub_stmt
sql/sql_lex.cc:
  Non-prelocked SP execution: More rigourous cleanup in st_lex::cleanup_after_one_table_open()
sql/sql_parse.cc:
  Rename: thd->transaction.in_sub_stmt -> thd->in_sub_stmt, remove outdated comments
sql/sql_trigger.h:
  Rename: thd->transaction.in_sub_stmt -> thd->in_sub_stmt
2005-07-30 08:19:57 +00:00
unknown
36b6bf2ef3 Merge mysql.com:/home/my/mysql-4.1
into  mysql.com:/home/my/mysql-5.0


BitKeeper/etc/ignore:
  auto-union
BitKeeper/deleted/.del-ctype_cp932.test:
  Auto merged
BitKeeper/deleted/.del-isam.test~834fb0ee8196c445:
  Auto merged
include/thr_lock.h:
  Auto merged
mysql-test/t/alias.test:
  Auto merged
mysql-test/t/alter_table.test:
  Auto merged
mysql-test/t/archive.test:
  Auto merged
mysql-test/t/backup.test:
  Auto merged
mysql-test/t/bool.test:
  Auto merged
mysql-test/t/connect.test:
  Auto merged
mysql-test/t/count_distinct2.test:
  Auto merged
mysql-test/t/create.test:
  Auto merged
mysql-test/t/ctype_many.test:
  Auto merged
mysql-test/t/ctype_ucs_binlog.test:
  Auto merged
mysql-test/t/date_formats.test:
  Auto merged
mysql-test/t/delayed.test:
  Auto merged
mysql-test/t/derived.test:
  Auto merged
mysql-test/t/distinct.test:
  Auto merged
mysql-test/t/drop.test:
  Auto merged
mysql-test/t/endspace.test:
  Auto merged
mysql-test/t/flush.test:
  Auto merged
mysql-test/t/fulltext.test:
  Auto merged
mysql-test/t/fulltext_order_by.test:
  Auto merged
mysql-test/t/func_compress.test:
  Auto merged
mysql-test/t/func_concat.test:
  Auto merged
mysql-test/t/func_date_add.test:
  Auto merged
mysql-test/t/func_equal.test:
  Auto merged
mysql-test/t/func_if.test:
  Auto merged
mysql-test/t/func_sapdb.test:
  Auto merged
mysql-test/t/func_set.test:
  Auto merged
mysql-test/t/func_str.test:
  Auto merged
mysql-test/t/gis-rtree.test:
  Auto merged
mysql-test/t/gis.test:
  Auto merged
mysql-test/t/grant.test:
  Auto merged
mysql-test/t/grant2.test:
  Auto merged
mysql-test/t/grant_cache.test:
  Auto merged
mysql-test/t/heap.test:
  Auto merged
mysql-test/t/heap_btree.test:
  Auto merged
mysql-test/t/heap_hash.test:
  Auto merged
mysql-test/t/init_connect.test:
  Auto merged
mysql-test/t/insert_select.test:
  Auto merged
mysql-test/t/insert_update.test:
  Auto merged
mysql-test/t/key.test:
  Auto merged
mysql-test/t/keywords.test:
  Auto merged
mysql-test/t/limit.test:
  Auto merged
mysql-test/t/lock.test:
  Auto merged
mysql-test/t/lowercase_table.test:
  Auto merged
mysql-test/t/lowercase_table3.test:
  Auto merged
mysql-test/t/merge.test:
  Auto merged
mysql-test/t/mix_innodb_myisam_binlog.test:
  Auto merged
mysql-test/t/myisam.test:
  Auto merged
mysql-test/t/mysqlbinlog2.test:
  Auto merged
mysql-test/t/ndb_alter_table.test:
  Auto merged
mysql-test/t/ndb_autodiscover.test:
  Auto merged
mysql-test/t/ndb_charset.test:
  Auto merged
mysql-test/t/ndb_grant.later:
  Auto merged
mysql-test/t/ndb_index_ordered.test:
  Auto merged
mysql-test/t/ndb_index_unique.test:
  Auto merged
mysql-test/t/ndb_restore.test:
  Auto merged
mysql-test/t/ndb_types.test:
  Auto merged
mysql-test/t/ndb_update.test:
  Auto merged
mysql-test/t/null.test:
  Auto merged
mysql-test/t/null_key.test:
  Auto merged
mysql-test/t/olap.test:
  Auto merged
mysql-test/t/openssl_1.test:
  Auto merged
mysql-test/t/order_by.test:
  Auto merged
mysql-test/t/ps.test:
  Auto merged
mysql-test/t/ps_1general.test:
  Auto merged
mysql-test/t/ps_4heap.test:
  Auto merged
mysql-test/t/ps_5merge.test:
  Auto merged
mysql-test/t/query_cache.test:
  Auto merged
mysql-test/t/replace.test:
  Auto merged
mysql-test/t/row.test:
  Auto merged
mysql-test/t/rpl000001.test:
  Auto merged
mysql-test/t/rpl000015.test:
  Auto merged
mysql-test/t/rpl000017.test:
  Auto merged
mysql-test/t/rpl000018.test:
  Auto merged
mysql-test/t/rpl_EE_error.test:
  Auto merged
mysql-test/t/rpl_change_master.test:
  Auto merged
mysql-test/t/rpl_charset.test:
  Auto merged
mysql-test/t/rpl_create_database.test:
  Auto merged
mysql-test/t/rpl_ddl.test:
  Auto merged
mysql-test/t/rpl_deadlock.test:
  Auto merged
mysql-test/t/rpl_empty_master_crash.test:
  Auto merged
mysql-test/t/rpl_error_ignored_table.test:
  Auto merged
mysql-test/t/rpl_flush_log_loop.test:
  Auto merged
mysql-test/t/rpl_flush_tables.test:
  Auto merged
mysql-test/t/rpl_get_lock.test:
  Auto merged
mysql-test/t/rpl_heap.test:
  Auto merged
mysql-test/t/rpl_loaddata.test:
  Auto merged
mysql-test/t/rpl_loaddata_rule_m.test:
  Auto merged
mysql-test/t/rpl_log.test:
  Auto merged
mysql-test/t/rpl_log_pos.test:
  Auto merged
mysql-test/t/rpl_max_relay_size.test:
  Auto merged
mysql-test/t/rpl_multi_query.test:
  Auto merged
mysql-test/t/rpl_openssl.test:
  Auto merged
mysql-test/t/rpl_redirect.test:
  Auto merged
mysql-test/t/rpl_relayrotate.test:
  Auto merged
mysql-test/t/rpl_replicate_do.test:
  Auto merged
mysql-test/t/rpl_reset_slave.test:
  Auto merged
mysql-test/t/rpl_server_id2.test:
  Auto merged
mysql-test/t/rpl_temporary.test:
  Auto merged
mysql-test/t/rpl_timezone.test:
  Auto merged
mysql-test/t/rpl_user_variables.test:
  Auto merged
mysql-test/t/show_check.test:
  Auto merged
mysql-test/t/subselect.test:
  Auto merged
mysql-test/t/symlink.test:
  Auto merged
mysql-test/t/synchronization.test:
  Auto merged
mysql-test/t/system_mysql_db.test:
  Auto merged
mysql-test/t/system_mysql_db_fix.test:
  Auto merged
mysql-test/t/temp_table.test:
  Auto merged
mysql-test/t/timezone2.test:
  Auto merged
mysql-test/t/timezone_grant.test:
  Auto merged
mysql-test/t/type_float.test:
  Auto merged
mysql-test/t/type_ranges.test:
  Auto merged
mysql-test/t/type_timestamp.test:
  Auto merged
mysql-test/t/union.test:
  Auto merged
mysql-test/t/update.test:
  Auto merged
mysql-test/t/user_var-binlog.test:
  Auto merged
mysql-test/t/warnings.test:
  Auto merged
mysys/thr_lock.c:
  Auto merged
sql/slave.cc:
  Auto merged
sql/sql_base.cc:
  Auto merged
sql/sql_lex.cc:
  Auto merged
sql/sql_select.cc:
  Auto merged
support-files/mysql.spec.sh:
  Auto merged
BitKeeper/deleted/.del-rpl_trunc_binlog.test~961b1f6ac73d37c8:
  Simple merge
mysql-test/r/ps_grant.result:
  Simple merge
mysql-test/t/analyse.test:
  Simple merge
mysql-test/t/auto_increment.test:
  Simple merge
mysql-test/t/bdb.test:
  Simple merge
mysql-test/t/bigint.test:
  Simple merge
mysql-test/t/case.test:
  Simple merge
mysql-test/t/cast.test:
  Simple merge
mysql-test/t/check.test:
  Simple merge
mysql-test/t/count_distinct.test:
  Simple merge
mysql-test/t/ctype_latin1_de.test:
  Simple merge
mysql-test/t/ctype_uca.test:
  Simple merge
mysql-test/t/ctype_ucs.test:
  Simple merge
mysql-test/t/ctype_utf8.test:
  Simple merge
mysql-test/t/delete.test:
  Simple merge
mysql-test/t/flush_block_commit.test:
  Simple merge
mysql-test/t/func_default.test:
  Simple merge
mysql-test/t/func_gconcat.test:
  Simple merge
mysql-test/t/func_group.test:
  Aligned code with 4.1
mysql-test/t/func_in.test:
  Simple merge
mysql-test/t/func_math.test:
  Simple merge
mysql-test/t/func_misc.test:
  Simple merge
mysql-test/t/func_test.test:
  Simple merge
mysql-test/t/func_time.test:
  Simple merge
mysql-test/t/group_by.test:
  Simple merge
mysql-test/t/having.test:
  Simple merge
mysql-test/t/innodb.test:
  Simple merge
mysql-test/t/insert.test:
  Simple merge
mysql-test/t/join_outer.test:
  Simple merge
mysql-test/t/kill.test:
  Simple merge
mysql-test/t/loaddata.test:
  Simple merge
mysql-test/t/lock_multi.test:
  Simple merge
mysql-test/t/multi_update.test:
  Simple merge
mysql-test/t/mysqlbinlog.test:
  Simple merge
mysql-test/t/mysqldump.test:
  Aligned code with 4.1
mysql-test/t/mysqltest.test:
  Simple merge
mysql-test/t/ndb_basic.test:
  Simple merge
mysql-test/t/ndb_cache.test:
  Simple merge
mysql-test/t/ndb_subquery.test:
  Simple merge
mysql-test/t/ps_grant.test:
  Simple merge
mysql-test/t/range.test:
  Simple merge
mysql-test/t/rpl_drop_temp.test:
  Simple merge
mysql-test/t/rpl_loaddata_rule_s.test:
  Simple merge
mysql-test/t/rpl_loaddatalocal.test:
  Simple merge
mysql-test/t/rpl_rotate_logs.test:
  Simple merge
mysql-test/t/rpl_until.test:
  Simple merge
mysql-test/t/rpl_variables.test:
  Simple merge
mysql-test/t/select.test:
  Simple merge
mysql-test/t/sql_mode.test:
  Simple merge
mysql-test/t/type_blob.test:
  Simple merge
mysql-test/t/type_decimal.test:
  Simple merge
mysql-test/t/user_var.test:
  Simple merge
mysql-test/t/variables.test:
  Simple merge
sql/lock.cc:
  Simple optimization
sql/mysql_priv.h:
  Simple merge
sql/sql_table.cc:
  Simple merge
sql/table.cc:
  Simple merge
sql/unireg.cc:
  Simple merge
2005-07-28 17:09:54 +03:00
unknown
53f40f95f8 Moved test for 'show full processlist' to not_embedded_server.test becasue it could fail on a slow computer where previous connections has not yet disconnected
mysql-test/r/ps_grant.result:
  Deallocate prepare statements
  Moved test for 'show full processlist' to not_embedded_server.test becasue it's shouldn't be here and it could fail on a slow computer where previous connections has not yet disconnected
mysql-test/t/ps_grant.test:
  Deallocate prepare statements
  Moved test for 'show full processlist' to not_embedded_server.test becasue it's shouldn't be here and it could fail on a slow computer where previous connections has not yet disconnected
sql/sql_lex.cc:
  Fixed typo
mysql-test/r/not_embedded_server.result:
  New BitKeeper file ``mysql-test/r/not_embedded_server.result''
mysql-test/t/not_embedded_server.test:
  New BitKeeper file ``mysql-test/t/not_embedded_server.test''
BitKeeper/etc/ignore:
  added ndb/tools/ndb_config
2005-07-27 13:45:06 +03:00
unknown
cd483c5520 Patch for push of wl1354 Partitioning 2005-07-18 13:31:02 +02:00
unknown
ef09588661 Post-merge fixes. 2005-07-15 00:41:58 +04:00
unknown
b0641a3bdd Merge mysql.com:/opt/local/work/mysql-4.1-root
into  mysql.com:/opt/local/work/mysql-5.0-root


regex/regerror.c:
  Auto merged
sql/sql_lex.cc:
  Auto merged
mysql-test/r/ps.result:
  Manual merge
mysql-test/t/ps.test:
  Manual merge
sql/sql_yacc.yy:
  Manual merge
2005-07-15 00:31:09 +04:00
unknown
cb7a5b53cc A fix and a test case for Bug#11299 "prepared statement makes wrong SQL
syntax in binlog which stops replication":
disallow the use of parameter markers which can lead to generation
of malformed binlog queries. 


mysql-test/r/ps.result:
  Test results fixed: a test case for Bug#11299
mysql-test/t/ps.test:
  A test case for Bug#11299
sql/sql_lex.cc:
  Introduce a new parser token for a parameter marker. Make sure
  that a parameter marker can not be used in a query which, when
  transformed to a binlog query, becomes grammatically incorrect.
sql/sql_yacc.yy:
  The check for COM_PREPARE has been moved into the lexer.
mysql-test/var:
  New BitKeeper file ``mysql-test/var''
2005-07-15 00:01:49 +04:00
unknown
c0e325a35c valgrind error fix(uninitialiased variable)
removed unnecessary operation


sql/sql_lex.cc:
  valgrind error fix(uninitialiased variable)
sql/sql_parse.cc:
  removed unnecessary operation
2005-07-14 15:42:36 +05:00
unknown
9aa1504062 Merge bk-internal.mysql.com:/home/bk/mysql-5.0
into  mysql.com:/home/dlenev/src/mysql-5.0-mysqlproc


mysql-test/r/sp-error.result:
  Auto merged
mysql-test/t/sp-error.test:
  Auto merged
sql/mysql_priv.h:
  Auto merged
sql/sp.h:
  Auto merged
sql/sql_base.cc:
  Auto merged
sql/sql_lex.cc:
  Auto merged
sql/sql_lex.h:
  Auto merged
sql/share/errmsg.txt:
  Manual merge.
sql/sp.cc:
  Manual merge.
2005-07-13 15:08:13 +04:00
unknown
11f9e513d7 Implementation of Monty's idea: Now we can open mysql.proc table for lookup
of stored routines definitions even if we already have some tables open and
locked. To avoid deadlocks in this case we have to put certain restrictions
on locking of mysql.proc table.

This allows to use stored routines safely under LOCK TABLES without explicitly
mentioning mysql.proc in the list of locked tables. It also fixes bug #11554
"Server crashes on statement indirectly using non-cached function".


mysql-test/r/sp-error.result:
  Added test which checks that now we can read stored routines definitions
  under LOCK TABLES even if we have not locked mysql.proc explicitly. Also
  added check for restrictions which this ability puts on mysql.proc locking.
  Updated test for bug #9566 to correspond this new situation.
mysql-test/r/sp-threads.result:
  Added test for bug #11554 "Server crashes on statement indirectly using
  non-cached function".
mysql-test/t/sp-error.test:
  Added test which checks that now we can read stored routines definitions
  under LOCK TABLES even if we have not locked mysql.proc explicitly. Also
  added check for restrictions which this ability puts on mysql.proc locking.
  Updated test for bug #9566 to correspond this new situation.
mysql-test/t/sp-threads.test:
  Added test for bug #11554 "Server crashes on statement indirectly using
  non-cached function".
sql/lock.cc:
  get_lock_data():
   To be able to open and lock for reading system tables like 'mysql.proc',
   when we already have some tables opened and locked, and avoid deadlocks
   we have to disallow write-locking of these tables with any other tables.
sql/mysql_priv.h:
  open_table() has new parameter which allows to open table even if some-one
  has done a flush or holding namelock on it.
sql/share/errmsg.txt:
  Added error message saying that one cannot write-lock some of system tables
  with any other tables.
sql/sp.cc:
  open_proc_table_for_read()/close_proc_table():
    Added functions to be able open and close mysql.proc table when we already
    have some tables open and locked.
  open_proc_table_for_update():
    Added function to simplify opening of mysql.proc for updates.
  db_find_routine_aux()/db_find_routine()/db_update_routine()/...
    Moved responsibility for opening mysql.proc table from db_find_routine_aux()
    one level up, since this level knows better which type of table access for
    reading of for update it needs.
  sp_function_exists():
    Removed unused function.
sql/sp.h:
  sp_function_exists():
    Removed unused function.
sql/sql_base.cc:
  open_table():
    Added new parameter which allows to open table even if some-one has done a
    flush or holding namelock on it.
  open_unireg_entry():
    Mark 'mysql.proc' as a system table which has special restrictions on its
    locking, but thanks to them can be open and locked even if we already have
    some open and locked.
sql/sql_class.cc:
  Moved THD members holding information about open and locked tables to separate
  Open_tables_state class to be able to save/restore this state easier.
  Added THD::push_open_tables_state()/pop_open_tables_state() methods for
  saving/restoring this state.
sql/sql_class.h:
  Moved THD members holding information about open and locked tables to separate
  Open_tables_state class to be able to save/restore this state easier.
  Added THD::push_open_tables_state()/pop_open_tables_state() methods for
  saving/restoring this state.
sql/sql_lex.cc:
  Removed LEX::proc_table member which was not really used.
sql/sql_lex.h:
  Removed LEX::proc_table member which was not really used.
sql/sql_table.cc:
  open_table() has new parameter which allows to open table even if some-one
  has done a flush or holding namelock on it.
sql/table.h:
  Added TABLE_SHARE::system_table indicating that this table is system table
  like 'mysql.proc' and we want to be able to open and read-lock it even when
  we already have some tables open and locked (and because of this we have
  to put some restrictions on write locking it).
2005-07-13 13:48:13 +04:00
unknown
d0c69a8264 Manual fixes after merging patch for bug #8406 "Triggers crash if referencing
a table" with main tree.


mysql-test/r/trigger.result:
  Temporalily disable part of test which exposes bug #11554 (work on which is in
  progress).
mysql-test/t/sp-error.test:
  After merge fix.
    Fixed wrong delimiter command.
mysql-test/t/trigger.test:
  Temporalily disable part of test which exposes bug #11554 (work on which is in
  progress).
sql/sp.cc:
  After merge fix.
    Item_arena was renamed to Query_arena.
sql/sp.h:
  After merge fix.
    Item_arena was renamed to Query_arena.
sql/sql_lex.cc:
  After merge fix.
    LEX::spfuns/spprocs hashes were replaces with one LEX::sroutines hash.
2005-07-09 23:11:17 +04:00
unknown
eef5f17bde Merge bk-internal.mysql.com:/home/bk/mysql-5.0
into  mysql.com:/home/dlenev/src/mysql-5.0-bg8406


mysql-test/r/sp.result:
  Auto merged
mysql-test/r/trigger.result:
  Auto merged
mysql-test/t/sp.test:
  Auto merged
mysql-test/t/trigger.test:
  Auto merged
sql/item_func.cc:
  Auto merged
sql/sp.cc:
  Auto merged
sql/sp_head.h:
  Auto merged
sql/sql_base.cc:
  Auto merged
sql/sql_lex.cc:
  Auto merged
sql/sql_lex.h:
  Auto merged
sql/sql_parse.cc:
  Auto merged
sql/sql_trigger.cc:
  Auto merged
mysql-test/r/sp-error.result:
  Manual merge.
mysql-test/t/sp-error.test:
  Manual merge.
sql/sp_head.cc:
  Manual merge.
sql/sql_yacc.yy:
  Manual merge.
2005-07-09 22:04:18 +04:00
unknown
14b1f91ba4 Enable support of access to tables from triggers. Thus fix bug #8406 "Triggers
crash if referencing a table" and several other related bugs.
Fix for bug #11834 "Re-execution of prepared statement with dropped function
crashes server." which was spotted during work on previous bugs.

Also couple of nice cleanups:
- Replaced two separate hashes for stored routines used by statement with one.
- Now instead of doing one pass through all routines used in statement for
  caching them and then doing another pass for adding their tables to table
  list, we do only one pass during which do both things.


mysql-test/r/sp-error.result:
  Added test for bug #11834 "Re-execution of prepared statement with dropped
  function crashes server" also covering handling of prepared statements
  which use stored functions but does not require prelocking.
mysql-test/r/sp.result:
  Updated test for LOCK TABLES with views in table list.
  (Old version of statement used in this test will work ok now, since prelocking
   algorithm was tuned and will lock only one multi-set of tables for each routine
   even if this routine is used in several different views).
mysql-test/r/trigger.result:
  Added several tests for triggers using tables.
mysql-test/t/sp-error.test:
  Added test for bug #11834 "Re-execution of prepared statement with dropped
  function crashes server" also covering handling of prepared statements
  which use stored functions but does not require prelocking.
mysql-test/t/sp.test:
  Updated comment about recursive views to reflect current situation.
  Updated test for LOCK TABLES with views in table list.
  (Old version of statement used in this test will work ok now, since prelocking
   algorithm was tuned and will lock only one multi-set of tables for each routine
   even if this routine is used in several different views).
mysql-test/t/trigger.test:
  Added several tests for triggers using tables.
sql/item_func.cc:
  Item_func_sp::cleanup():
    By next statement execution stored function can be dropped or altered so
    we can't assume that sp_head object for it will be still valid.
sql/sp.cc:
  - Added Sroutine_hash_entry structure that represents element in the set of
    stored routines used by statement or routine. We can't as before use
    LEX_STRING for this purprose because we want link all elements of this set
    in list.
  - Replaced sp_add_to_hash() with sp_add_used_routine() which takes into account
    that now we use one hash for stored routines used by statement instead of two
    and which mantains list linking all elelemnts in this hash.
  - Renamed sp_merge_hash() to sp_update_sp_used_routines().
  - Introduced sp_update_stmt_used_routines() for adding elements to the set of
    routines used by statement from another similar set for statement or routine.
    This function will also mantain list linking elements of destination set.
  - Now instead of one sp_cache_routines() function we have family of 
    sp_cache_routines_and_add_tables() functions which are also responsible for
    adding tables used by routines being cached to statement table list. Nice
    optimization - thanks to list linking all elements in the hash of routines
    used by statement we don't need to perform several iterations over this hash
    (as it was before in cases when we have added new elements to it).
sql/sp.h:
  Added declarations of functions used for manipulations with set (hash) of stored
  routines used by statement.
sql/sp_head.cc:
  sp_name::init_qname():
    Now sp_name also holds key identifying routine in the set (hash) of
    stored routines used by statement. 
  sp_head:
    Instead of two separate hashes sp_funs/m_spprocs representing sets of stored
    routines used by this routine we use one hash - m_sroutines. 
  sp_instr_set_trigger_field:
    Added support for subqueries in assignments to row accessors in triggers.
  Removed definition of sp_add_sp_tables_to_table_list() and auxilary functions 
  since now we don't have separate stage on which we add tables used by routines
  used by statement to table list for prelocking. We do it on the same stage as
  we load those routines in SP cache. So all this functionality moved to
  sp_cache_routines_and_add_tables() family of functions.
sql/sp_head.h:
  sp_name:
    Now this class also holds key identifying routine in the set (hash) of stored
    routines used by statement. 
  sp_head:
    Instead of two separate hashes sp_funs/m_spprocs representing sets of stored
    routines used by this routine we use one hash - m_sroutines. 
  sp_instr_set_trigger_field:
    Added support for subqueries in assignments to row accessors in triggers.
  Removed declaration of sp_add_sp_tables_to_table_list() since now we don't have
  separate stage on which we add tables used by routines used by statement to
  table list for prelocking. We do it on the same stage as we load those routines
  in SP cache.
sql/sql_base.cc:
  open_tables():
  - LEX::spfuns/spprocs hashes were replaced with one LEX::sroutines hash.
  - Now instead of doing one pass through all routines used in statement for
    caching them and then doing another pass for adding their tables to table
    list, we do only one pass during which do both things. It is easy to do
    since all routines in the set of routines used by statement are linked in
    the list. This also allows us to calculate table list for prelocking more
    precisely.
  - Now triggers properly inform prelocking algorithm about tables they use.
sql/sql_lex.cc:
  lex_start():
    Replaced LEX::spfuns/spprocs with with one LEX::sroutines hash.
    Added LEX::sroutines_list list linking all elements in this hash.
  st_lex::st_lex():
    Moved definition of LEX constructor to sql_lex.cc file to be able
    use sp_sroutine_key declaration from sp.h in it.
sql/sql_lex.h:
  LEX:
    Replaced two separate hashes for stored routines used by statement with one.
    Added list linking all elements in this hash to be able to iterate through all
    elements and add new elements to this hash at the same time.
    Moved constructor definition to sql_lex.cc.
sql/sql_parse.cc:
  mysql_execute_command():
    Replaced LEX::spfuns/spprocs with one LEX::sroutines hash.
sql/sql_trigger.cc:
  Added missing GNU GPL notice.
  Table_triggers_list::check_n_load()
    Added initialization of sroutines_key which stores key representing
    triggers of this table in the set (hash) of routines used by this statement.
sql/sql_trigger.h:
  Added missing GNU GPL notice.
  Table_triggers_list:
    Added sroutines_key member to store key representing triggers of this
    table in the set (hash) of routines used by this statement.
    Declared sp_cache_routines_and_add_tables_for_triggers() as friend since
    it needs access to sroutines_key and trigger bodies.
sql/sql_yacc.yy:
  - Now we use sp_add_used_routine() instead of sp_add_to_hash() for adding
    elements to the set of stored routines used in statement.
  - Enabled support of subqueries as right sides in assignments to triggers' row
    accessors.
2005-07-09 21:51:59 +04:00
unknown
8a23dd8672 Merge jwinstead@production.mysql.com:my/mysql-5.0-11045
into  mysql.com:/home/jimw/my/mysql-5.0-clean


VC++Files/sql/mysqld.dsp:
  Auto merged
sql/ha_federated.cc:
  Auto merged
sql/sql_acl.cc:
  Auto merged
sql/sql_insert.cc:
  Auto merged
sql/sql_lex.cc:
  Auto merged
sql/sql_lex.h:
  Auto merged
sql/sql_union.cc:
  Auto merged
sql/sql_yacc.yy:
  Auto merged
sql/table.cc:
  Auto merged
sql/item_strfunc.cc:
  SCCS merged
2005-07-06 16:49:04 -07:00
unknown
323652f4dc Merge
sql/sql_lex.cc:
  Auto merged
sql/sql_lex.h:
  Auto merged
sql/sql_table.cc:
  Auto merged
mysql-test/r/view.result:
  SCCS merged
mysql-test/t/view.test:
  SCCS merged
2005-07-05 13:42:19 +03:00
unknown
836f5a5a1e fixed environment creation and cleaning up for processing view one by one during checking (BUG#11337)
mysql-test/r/view.result:
  checking views after some view with error (BUG#11337)
mysql-test/t/view.test:
  checking views after some view with error (BUG#11337)
sql/sql_lex.cc:
  environment cleaning up for processing view one by one
sql/sql_lex.h:
  methods for lex cleunup during view processing one by one
sql/sql_table.cc:
  fixed environment creation and cleaning up for processing view one by one (BUG#11337)
2005-07-05 13:37:02 +03:00
unknown
497b88652b fix bugs found by gcc 3.4 compiler
sql/sp_head.h:
  removed unused parameter
sql/sql_lex.cc:
  make correct operation order
sql/sql_yacc.yy:
  removed unused parameter
2005-07-01 13:27:23 +03: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
94d1d88658 Clean up warnings and build problems on Windows. (Bug #11045)
VC++Files/sql/mysqld.dsp:
  Link debug server against debug yassl
sql/examples/ha_archive.cc:
  Fix type for variables used to store number of rows
  Add cast when reading current position
sql/examples/ha_archive.h:
  Fix variables used to store rows to ha_rows
sql/ha_federated.cc:
  Remove unused variables, fix type of variable used to store query id
sql/item_strfunc.cc:
  Remove unused variables
sql/sql_acl.cc:
  Remove unused variables
sql/sql_lex.cc:
  Add casts to fix type used for counting number of rows
sql/sql_lex.h:
  Fix size of options to be ulong again
sql/sql_insert.cc:
  Fix type of query id value
sql/sql_union.cc:
  Cast value for number of rows to ha_rows
sql/sql_yacc.yy:
  Remove unused variable
sql/table.cc:
  Add casts for handling key_part lengths
2005-06-18 01:55:42 +02:00
unknown
c0918af2c7 Merge bk-internal.mysql.com:/home/bk/mysql-5.0
into mysql.com:/opt/local/work/mysql-5.0-10736


sql/sql_class.h:
  Auto merged
sql/sql_lex.cc:
  Auto merged
sql/sql_prepare.cc:
  Auto merged
sql/sql_yacc.yy:
  Auto merged
2005-06-17 23:27:23 +04:00
unknown
63c21c07fc Rename all prepared statements COM_ commands to prefix with COM_STMT_
libmysql/libmysql.c:
  Rename.
libmysqld/lib_sql.cc:
  Rename.
sql/item_cmpfunc.cc:
  Use proper method to check for stmt prepare, only_prepare is removed.
sql/mysql_priv.h:
  Remove an obsolete define. Rename mysql_stmt_free to mysql_stmt_close.
sql/sql_class.h:
  Remove THD::only_prepare.
  Rename.
sql/sql_lex.cc:
  Rename COM_PREPARE -> COM_STMT_PREPARE
sql/sql_parse.cc:
  Rename.
sql/sql_prepare.cc:
  Rename.
sql/sql_yacc.yy:
  Rename.
tests/mysql_client_test.c:
  Rename.
2005-06-17 23:26:25 +04:00
unknown
f1e42a0b35 renamed:
Item_buff -> Cached_item
  Item_arena -> Query_arena
  TEST_ASSERT -> YYERROR_UNLESS


sql/item.h:
  renamed:
    Item_buff -> Cached_item
sql/item_buff.cc:
  renamed:
    Item_buff -> Cached_item
sql/item_func.cc:
  renamed:
    Item_arena -> Query_arena
sql/item_subselect.cc:
  renamed:
    Item_arena -> Query_arena
sql/sp_head.cc:
  renamed:
    Item_arena -> Query_arena
sql/sp_head.h:
  renamed:
    Item_arena -> Query_arena
sql/sql_base.cc:
  renamed:
    Item_arena -> Query_arena
sql/sql_class.cc:
  renamed:
    Item_arena -> Query_arena
sql/sql_class.h:
  renamed:
    Item_arena -> Query_arena
sql/sql_lex.cc:
  renamed:
    Item_arena -> Query_arena
sql/sql_prepare.cc:
  renamed:
    Item_arena -> Query_arena
sql/sql_select.cc:
  renamed:
    Item_arena -> Query_arena
sql/sql_select.h:
  renamed:
    Item_buff -> Cached_item
    Item_arena -> Query_arena
sql/sql_union.cc:
  renamed:
    Item_arena -> Query_arena
sql/sql_view.cc:
  renamed:
    Item_arena -> Query_arena
sql/sql_yacc.yy:
  renamed:
    TEST_ASSERT -> YYERROR_UNLESS
sql/table.cc:
  renamed:
    Item_arena -> Query_arena
2005-06-15 19:58:35 +02:00
unknown
936688feb5 A followup patch for Bug#7306 (limit in prepared statements):
don't evaluate subqueries during statement prepare, even if they
are not correlated.
With post-review fixes.


sql/mysql_priv.h:
  Add UNCACHEABLE_PREPARE to mark subqueries as non-constant in 
  mysql_stmt_prepare
sql/sql_lex.cc:
  Add a missing assert: noone can call unit::set_limit from 
  mysql_stmt_prepare.
sql/sql_lex.h:
  Comment fixed.
sql/sql_parse.cc:
  Mark new SELECT_LEXes as uncacheable if they created during 
  statement prepare.
sql/sql_prepare.cc:
  Switch off the uncacheable flag when prepare is done.
2005-06-08 00:34:53 +04: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
5cdac99069 Merge bk-internal.mysql.com:/home/bk/mysql-5.0
into mysql.com:/opt/local/work/mysql-5.0-7306-new


sql/item_subselect.cc:
  Auto merged
sql/mysql_priv.h:
  Auto merged
sql/opt_range.cc:
  Auto merged
sql/sql_base.cc:
  Auto merged
sql/sql_insert.cc:
  Auto merged
sql/sql_lex.cc:
  Auto merged
sql/sql_lex.h:
  Auto merged
sql/sql_olap.cc:
  Auto merged
sql/sql_parse.cc:
  Auto merged
sql/sql_select.cc:
  Auto merged
2005-05-30 20:56:11 +04:00
unknown
78422442df Preparatory (and the most problematic) patch for Bug#7306
"the server side preparedStatement error for LIMIT placeholder",
which moves all uses of LIMIT clause from PREPARE to OPTIMIZE
and later steps.
After-review fixes.


mysql-test/r/group_min_max.result:
  Test results fixed for EXPLAINs when using GROUP_MIN_MAX access plan.
sql/item_subselect.cc:
  Move setting of the internal LIMIT used for IN/ALL/ANY/EXISTS 
  subqueries to one place: Item_exists_subselect::fix_length_and_dec().
  This implies that unit->select_limit_cnt is not set until the item is 
  fixed. This is OK, as now LIMIT values are not used until JOIN::optimize.
sql/mysql_priv.h:
  setup_tables no longer needs a special flag for the case when
  it's called from JOIN::reinit() (we don't need to call setup_tables
  between two executions of a correlated subquery).
sql/opt_range.cc:
  Fix a glitch in GROUP_MIN_MAX access plan: we should use table metadata,
  not field data, to evaluate max_used_key_length, which is then
  used for explain.
sql/sp.cc:
  - setup_tables signature changed.
sql/sql_base.cc:
  - setup_tables no longer needs a special mode for subqueries.
    Unused checks were removed.
sql/sql_delete.cc:
  - setup_tables signature changed
sql/sql_help.cc:
  - setup_tables signature changed
sql/sql_insert.cc:
  - setup_tables signature changed
sql/sql_lex.cc:
  Consolidate setting of internal LIMIT for IN/ALL/ANY/EXISTS subqeries
  in one place, and hence remove it from st_select_lex::test_limit().
sql/sql_lex.h:
  Cleanup signature of st_select_lex_unit::init_prepare_fake_select_lex().
sql/sql_load.cc:
  - setup_tables signature changed
sql/sql_olap.cc:
  - setup_tables signature changed
sql/sql_parse.cc:
  - st_select_lex_unit::set_limit() signature changed
sql/sql_select.cc:
  Move setting of JOIN::select_limit from JOIN::prepare
  to JOIN::optimize. At prepare, limit is unknown yet.
  Remove excessive cleanups from JOIN::reinit which were overwriting
  join->join_tab[i]->table->used_keys. This fixes the bug which was triggered
  by the change in item_subselect.cc.
sql/sql_union.cc:
  Class st_select_lex_unit was changed to avoid calls to 
   st_select_lex_unit::set_limit from places where it may be unknown.
  Now unit->select_limit_cnt is set at ::exec(). 
  st_select_lex_unit::init_prepare_fake_select_lex(): 
   - move out set_limit functionality
   - remove a few lines of dead code.
  st_select_lex_unit::prepare():
    - now we don't call set_limit at the time of prepare, so the value  
      of unit->select_limit_cnt may be unknown here. Use sl->select_limit
      instead.
  st_select_lex_unit::exec():
    - cleanup
    - call set_limit explicitly as it has been moved out of 
     init_prepare_fake_select_lex.
sql/sql_update.cc:
  - setup_tables signature changed
2005-05-30 20:54:37 +04:00
unknown
6e79678dee Merge from 4.1
BitKeeper/deleted/.del-ha_isam.cc~4dce65904db2675e:
  Auto merged
BitKeeper/deleted/.del-ha_isammrg.cc~dc682e4755d77a2e:
  Auto merged
client/sql_string.cc:
  Auto merged
client/sql_string.h:
  Auto merged
include/my_global.h:
  Auto merged
include/my_sys.h:
  Auto merged
mysql-test/mysql-test-run.sh:
  Auto merged
mysys/my_open.c:
  Auto merged
mysys/raid.cc:
  Auto merged
ndb/src/kernel/blocks/dbtux/Dbtux.hpp:
  Auto merged
sql/field.cc:
  Auto merged
sql/ha_berkeley.cc:
  Auto merged
sql/ha_blackhole.cc:
  Auto merged
sql/ha_heap.cc:
  Auto merged
sql/ha_innodb.cc:
  Auto merged
sql/ha_myisam.cc:
  Auto merged
sql/ha_myisammrg.cc:
  Auto merged
sql/ha_ndbcluster.cc:
  Auto merged
sql/handler.cc:
  Auto merged
sql/item.cc:
  Auto merged
sql/item_cmpfunc.cc:
  Auto merged
sql/item_func.cc:
  Auto merged
sql/item_geofunc.cc:
  Auto merged
sql/item_strfunc.cc:
  Auto merged
sql/item_subselect.cc:
  Auto merged
sql/item_sum.cc:
  Auto merged
sql/item_timefunc.cc:
  Auto merged
sql/item_uniq.cc:
  Auto merged
sql/item_uniq.h:
  Auto merged
sql/log_event.cc:
  Auto merged
sql/log_event.h:
  Auto merged
sql/procedure.cc:
  Auto merged
sql/protocol.cc:
  Auto merged
sql/protocol_cursor.cc:
  Auto merged
sql/set_var.cc:
  Auto merged
sql/sql_analyse.cc:
  Auto merged
sql/sql_analyse.h:
  Auto merged
sql/sql_lex.cc:
  Auto merged
sql/sql_map.cc:
  Auto merged
sql/sql_olap.cc:
  Auto merged
sql/sql_string.cc:
  Auto merged
sql/sql_udf.cc:
  Auto merged
sql/tztime.cc:
  Auto merged
sql/opt_range.cc:
  Manual merge
sql/sql_parse.cc:
  Use select_lex pointer instead of lex->select_lex
sql/sql_repl.cc:
  Function moved to log.cc, fix made there instead
sql/sql_class.cc:
  Auto merged
sql/sql_select.cc:
  Auto merged
2005-05-26 21:01:55 +02:00
unknown
549f56dc3d Cleanup during code review
Faster detection of wrong table names (like PRN) on windows


include/my_sys.h:
  Added check_if_legal_filename()
mysys/my_access.c:
  Added check_if_legal_filename()
  Set errno if my_access() fails
mysys/my_fopen.c:
  USe check_if_legal_filename() instead of my_access() to detect wrong file names on windows
mysys/my_open.c:
  USe check_if_legal_filename() instead of my_access() to detect wrong file names on windows
sql/sql_lex.cc:
  Portability fix
sql/sql_parse.cc:
  Simple cleanup
sql/sql_repl.cc:
  Cleanup during code review
2005-05-25 12:56:47 +03:00
unknown
5082d2d0b4 Fixed references to uninitialized memory
sql/sp.cc:
  Simpe fix to avoid reference to unallocated memory (only opened was needed, but I reset both to make things safer and simpler)
2005-05-19 04:48:22 +03:00
unknown
d93806ef7d Fix warnings from icc
Added BUILD scripts for icc
Fixed (one time) memory leak in grant handling


config/ac-macros/misc.m4:
  Remove warnings flags from icc when compiling with -Werror
configure.in:
  Remove warnings flags from icc when compiling with -Werror
extra/replace.c:
  Fix warnings from icc
include/my_dbug.h:
  Fix warnings from icc
sql/gen_lex_hash.cc:
  Fix warnings from icc
sql/mysql_priv.h:
  Add missing variables
sql/mysqld.cc:
  Fix warnings from icc:
  - made a lot of variables static
  - Removing some not used variables
  - Fixed wrong printf()
  - removed extern "C" from some functions
sql/spatial.h:
  Fix warnings from icc
sql/sql_acl.cc:
  Fixed memory leak
sql/sql_lex.cc:
  Fix warnings from icc
sql/sql_lex.h:
  Fix warnings from icc
2005-05-18 19:00:21 +03:00
unknown
e2d9929d2c BUG#9922 - INSERT SELECT with UNIONs allows concurrent INSERTs
don't set lex->lock_option=TL_READ in the parser for SELECT
2005-04-15 19:20:15 +02:00
unknown
daddf263e5 fixed mechanism of detection selection from table wich we update
(BUG##9398, BUG#8703)
fixed wrong join view detection in multi-delete which lead to server crash


mysql-test/r/lowercase_view.result:
  added new tests of updation and selection from the same table
mysql-test/r/view.result:
  added new tests of updation and selection from the same table
  added test of multidelete command over join view which lead to server crash
  test suite from bugs #9398 and #8703
mysql-test/t/lowercase_view.test:
  added new tests of updation and selection from the same table
mysql-test/t/view.test:
  added new tests of updation and selection from the same table
  added test of multidelete command over join view which lead to server crash
  test suite from bugs #9398 and #8703
sql/sql_base.cc:
  changed procedure of finding tables
sql/sql_class.cc:
  added derived table procession detection
sql/sql_class.h:
  added derived table procession detection
sql/sql_delete.cc:
  fixed detection of selection from table which update for multidelete
sql/sql_derived.cc:
  added derived table procession detection
sql/sql_lex.cc:
  added detection os SELECTs processed inside derived tables
  removed old mechanism of multidelete/multiupdate table duplication detection (which can't work with views)
sql/sql_lex.h:
  added detection os SELECTs processed inside derived tables
  removed old mechanism of multidelete/multiupdate table duplication detection (which can't work with views)
sql/sql_parse.cc:
  removed wrong test of join view (for multidelete in can be not only first table)
sql/sql_prepare.cc:
  added detection os SELECTs processed inside derived tables (reset it for reusing in PS/SP)
sql/sql_select.cc:
  added detection os SELECTs processed inside derived tables
sql/sql_update.cc:
  fixed detection of selection from table which update for multiupdate
2005-03-28 15:13:31 +03:00
unknown
b1095fb0cd Manual merge SP-locking improvements patch with current tree.
mysql-test/r/mysqldump.result:
  Auto merged
mysql-test/r/sp.result:
  Auto merged
mysql-test/t/mysqldump.test:
  Auto merged
mysql-test/t/sp.test:
  Auto merged
sql/item_func.cc:
  Auto merged
sql/mysql_priv.h:
  Auto merged
sql/sp.cc:
  Auto merged
sql/sp_rcontext.cc:
  Auto merged
sql/sql_acl.cc:
  Auto merged
sql/sql_base.cc:
  Auto merged
sql/sql_class.h:
  Auto merged
sql/sql_lex.cc:
  Auto merged
sql/sql_lex.h:
  Auto merged
sql/sql_prepare.cc:
  Auto merged
sql/sql_update.cc:
  Auto merged
sql/sql_view.cc:
  Auto merged
sql/table.h:
  Auto merged
sql/sp_head.cc:
  Manual merge.
sql/sql_class.cc:
  Manual merge.
sql/sql_parse.cc:
  Manual merge.
sql/sql_yacc.yy:
  Manual merge.
2005-03-04 17:46:45 +03: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
0c88d48d50 After merge fix.
sql/sql_lex.cc:
  No need to change options here.
2005-03-03 15:37:14 +04:00
unknown
61a88ff0a1 Merge serg.mylan:/usr/home/serg/Abk/mysql-5.0
into serg.mylan:/usr/home/serg/Abk/mysql-5.0-xa


configure.in:
  Auto merged
mysql-test/r/drop_temp_table.result:
  Auto merged
mysql-test/r/innodb.result:
  Auto merged
mysql-test/t/innodb.test:
  Auto merged
sql/ha_innodb.cc:
  Auto merged
sql/item_func.h:
  Auto merged
sql/log.cc:
  Auto merged
sql/mysql_priv.h:
  Auto merged
sql/mysqld.cc:
  Auto merged
sql/set_var.h:
  Auto merged
sql/sql_base.cc:
  Auto merged
sql/sql_delete.cc:
  Auto merged
sql/sql_insert.cc:
  Auto merged
sql/sql_lex.cc:
  Auto merged
sql/sql_parse.cc:
  Auto merged
2005-02-18 12:02:46 +01:00
unknown
90cc9c6bb6 Merge
BitKeeper/triggers/post-commit:
  Auto merged
mysql-test/r/lowercase_table2.result:
  Auto merged
mysql-test/r/variables.result:
  Auto merged
mysql-test/t/variables.test:
  Auto merged
sql/mysql_priv.h:
  Auto merged
sql/set_var.cc:
  Auto merged
sql/set_var.h:
  Auto merged
sql/sql_base.cc:
  Auto merged
sql/sql_parse.cc:
  Auto merged
tests/mysql_client_test.c:
  Auto merged
mysql-test/r/system_mysql_db.result:
  Update results
scripts/mysql_create_system_tables.sh:
  Merge fix for Bug #7617, making enum fields in grant tables
  case-insensitive.
scripts/mysql_fix_privilege_tables.sql:
  Merge fix for Bug #7617, and fix additional enum/set columns.
sql/sql_acl.cc:
  Hand-merge due to whitespace change
sql/sql_lex.cc:
  Hand-merge bug fix.
2005-02-17 16:16:58 -08:00
unknown
7aa1d93fd4 Merge serg.mylan:/usr/home/serg/Abk/mysql-5.0
into serg.mylan:/usr/home/serg/Abk/mysql-5.0-xa


mysql-test/r/ctype_ucs.result:
  Auto merged
mysql-test/t/ctype_ucs.test:
  Auto merged
mysql-test/t/strict.test:
  Auto merged
sql/ha_innodb.cc:
  Auto merged
sql/sql_class.cc:
  Auto merged
sql/sql_class.h:
  Auto merged
sql/sql_lex.cc:
  Auto merged
sql/sql_lex.h:
  Auto merged
sql/sql_parse.cc:
  Auto merged
sql/sql_update.cc:
  Auto merged
sql/examples/ha_archive.cc:
  Auto merged
sql/sql_yacc.yy:
  Auto merged
2005-02-17 14:00:44 +01:00
unknown
53944e1c22 Fix for bug#7915: crash,JOIN VIEW, subquery, SELECT .. FROM INFORMATION_SCHEMA.COLUMNS 2005-02-16 13:00:03 +03:00
unknown
2d8b51991c manually merged
client/mysqlbinlog.cc:
  Auto merged
configure.in:
  Auto merged
include/my_global.h:
  Auto merged
include/my_pthread.h:
  Auto merged
innobase/trx/trx0trx.c:
  Auto merged
mysql-test/include/varchar.inc:
  Auto merged
mysql-test/r/bdb.result:
  Auto merged
mysql-test/r/myisam.result:
  Auto merged
mysql-test/r/mysqlbinlog2.result:
  Auto merged
mysql-test/t/ctype_ucs.test:
  Auto merged
mysql-test/t/user_var.test:
  Auto merged
mysys/hash.c:
  Auto merged
sql/item_func.cc:
  Auto merged
sql/log_event.cc:
  Auto merged
sql/log_event.h:
  Auto merged
sql/set_var.h:
  Auto merged
sql/slave.cc:
  Auto merged
sql/slave.h:
  Auto merged
sql/sp_head.cc:
  Auto merged
sql/sql_base.cc:
  Auto merged
sql/sql_class.cc:
  Auto merged
sql/sql_lex.h:
  Auto merged
sql/sql_repl.cc:
  Auto merged
sql/sql_repl.h:
  Auto merged
sql/sql_table.cc:
  Auto merged
sql/sql_trigger.cc:
  Auto merged
mysql-test/r/ctype_ucs.result:
  ul
mysql-test/r/drop_temp_table.result:
  ul
mysql-test/r/innodb.result:
  ul
mysql-test/r/insert_select.result:
  ul
mysql-test/r/mix_innodb_myisam_binlog.result:
  ul
mysql-test/r/rpl_change_master.result:
  ul
mysql-test/r/rpl_charset.result:
  ul
mysql-test/r/rpl_error_ignored_table.result:
  ul
mysql-test/r/rpl_flush_log_loop.result:
  ul
mysql-test/r/rpl_flush_tables.result:
  ul
mysql-test/r/rpl_loaddata.result:
  ul
mysql-test/r/rpl_loaddata_rule_m.result:
  ul
mysql-test/r/rpl_log.result:
  ul
mysql-test/r/rpl_max_relay_size.result:
  ul
mysql-test/r/rpl_relayrotate.result:
  ul
mysql-test/r/rpl_replicate_do.result:
  ul
mysql-test/r/rpl_rotate_logs.result:
  ul
mysql-test/r/rpl_temporary.result:
  ul
mysql-test/r/rpl_timezone.result:
  ul
mysql-test/r/rpl_until.result:
  ul
mysql-test/r/rpl_user_variables.result:
  ul
mysql-test/r/user_var.result:
  ul
2005-02-14 21:50:09 +01:00
unknown
f4eef98e6e Merge abotchkov@bk-internal.mysql.com:/home/bk/mysql-5.0
into deer.(none):/home/hf/work/mysql-5.0.clean


mysql-test/r/view.result:
  Auto merged
sql/item_func.cc:
  Auto merged
sql/sp_head.cc:
  Auto merged
sql/sql_base.cc:
  Auto merged
sql/sql_class.h:
  Auto merged
sql/sql_lex.cc:
  Auto merged
sql/sql_parse.cc:
  Auto merged
sql/sql_prepare.cc:
  Auto merged
sql/sql_show.cc:
  Auto merged
sql/sql_yacc.yy:
  Auto merged
2005-02-09 02:54:08 +04: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
3f24932124 WL#2130: Table locking for stored FUNCTIONs
Collect all tables and SPs refered by a statement, and open all tables
with an implicit LOCK TABLES. Do find things refered by triggers and views,
we open them first (and then repeat this until nothing new is found), before
doing the actual lock tables.


mysql-test/r/information_schema.result:
  Updated result for WL#2130.
mysql-test/r/lock.result:
  Updated result for WL#2130.
mysql-test/r/sp-error.result:
  Updated result for WL#2130.
mysql-test/r/sp.result:
  Updated result for WL#2130.
mysql-test/r/view.result:
  Updated result for WL#2130.
mysql-test/t/information_schema.test:
  Disabled one test case due to a bug involving LOCK TABLES,
  which shows up with WL#2130.
mysql-test/t/lock.test:
  New error message with WL#2130. This change is under debate and might change
  in the future, but will do for now.
mysql-test/t/sp-error.test:
  Updated for WL#2130. Some tests are voided when table access does work from
  functions.
mysql-test/t/sp.test:
  Updated for WL#2130.
mysql-test/t/view.test:
  Updated for WL#2130.
sql/item_func.cc:
  We now have to set net.no_send_ok for functions too, with WL#2130.
sql/share/errmsg.txt:
  Reused an error code since the old use was voided by WL#2130, but a new
  one was needed instead (similar, but more specific restriction).
sql/sp.cc:
  Fixed error handling and collection of used tables for WL#2130.
sql/sp.h:
  Fixed error handling and collection of used tables for WL#2130.
sql/sp_head.cc:
  Added support functions for collecting and merging hash tables and lists
  of used tables from SPs and substatements, for WL#2130.
sql/sp_head.h:
  Added support functions for collecting and merging hash tables and lists
  of used tables from SPs and substatements, for WL#2130.
sql/sql_base.cc:
  Changed the way table->query_id is tested and set during with locked tables
  in effect. This makes some SP test cases work with WL#2130, but has a side
  effect on some error cases with explicit LOCK TABLES. It's still debated if
  this is the correct way, so it might change.
sql/sql_class.h:
  Added flags for circumventing some interference between WL#2130 and mysql_make_view().
sql/sql_derived.cc:
  Added some missing initializations. (Potential bugs.)
sql/sql_lex.cc:
  Clear the new hash tables for WL#2130.
sql/sql_lex.h:
  Added hash tables for procedures and tables too (as for functions), for WL#2130.
sql/sql_parse.cc:
  WL#2130: Make table accesses from stored functions work by adding an implicit
  LOCK TABLES around (most) executed statements. To do this, we have to go through
  a loop where we collect all SPs and tables in mysql_execute_statement.
sql/sql_prepare.cc:
  Cache both functions and procedures for WL#2130.
sql/sql_show.cc:
  Added some missing initializations. (Potential bugs.)
sql/sql_view.cc:
  Shortcut mysql_make_view() if thd->shortcut_make_view is true during
  the pre-open phase for collecting tables in WL#2130. Otherwise, the
  similar mechanism here causes interference.
sql/sql_yacc.yy:
  For WL#2130, added caching of procedures and disallowed LOCK/UNLOCK TABLES in SPs.
2005-02-08 20:52:50 +01:00
unknown
7814366660 Merge mysql.com:/home/jimw/my/mysql-5.0-6368
into mysql.com:/home/jimw/my/mysql-5.0-clean


sql/sql_lex.cc:
  Auto merged
2005-02-07 12:20:08 -08:00
unknown
5cf29b3b60 Fixed bug detected by sp-tests
Cleanup during reviews of new pushed code


BUILD/compile-pentium-debug-max:
  Use --debug=full as default
BUILD/compile-pentium-debug:
  Use --debug=full as default
mysys/my_alloc.c:
  More debugging
sql/item_func.cc:
  Cleanup new code
  Don't call insert_id() for last_insert_id(value) to avoid side effects
sql/item_subselect.cc:
  Fixed DBUG output
sql/sp_head.cc:
  Simple cleanup
sql/sql_lex.cc:
  Moved usage of arguments first in lex_start to make their usage clearer
  Remove sl->expr_list.deleete_elements() becasue:
  - It didn't do anything (delete_elements on a list of list is a no-op operation)
  - The deleted for loop used SELECT_LEX elements that was allocated in mysql_new_select() in sp-head, but freed
  when sphead->mem_root was freed. (delete sphead doesn't remove used SELECT_LEX elements from the global all_selects_list)
sql/sql_parse.cc:
  More DBUG entries
2005-02-05 16:05:46 +02:00
unknown
3443fdf954 Handle backslashes correctly in strings that also have doubled quotes when
we are using the NO_BACKSLASH_ESCAPES SQL mode. (Bug #6368)


mysql-test/t/sql_mode.test:
  Add regression test for Bug #6368
mysql-test/r/sql_mode.result:
  Add new results
sql/sql_lex.cc:
  Handle NO_BACKSLASH_ESCAPES mode when copying string that
  also has escapes due to doubled quotes
2005-02-03 16:14:02 -08:00
unknown
d41473f3c6 Fix error in parsing string literals containing a backslash followed
by a multi-byte character with a second byte of 0x5c (\). (Bug #8903)


sql/sql_lex.cc:
  Fix lex error when multi-byte character containing 0x5c (\) follows a
  backslash
mysql-test/t/ctype_sjis.test:
  Add regression test for Bug #8303
mysql-test/r/ctype_sjis.result:
  Add test results
2005-02-03 16:07:32 -08:00
unknown
4f1cbb6031 4.1 -> 5.0 merge
BitKeeper/etc/logging_ok:
  auto-union
Build-tools/Do-compile:
  Auto merged
client/mysqladmin.cc:
  Auto merged
client/mysqldump.c:
  Auto merged
configure.in:
  Auto merged
extra/perror.c:
  Auto merged
innobase/buf/buf0rea.c:
  Auto merged
innobase/fil/fil0fil.c:
  Auto merged
innobase/include/rem0rec.ic:
  Auto merged
innobase/include/univ.i:
  Auto merged
innobase/os/os0file.c:
  Auto merged
innobase/ut/ut0ut.c:
  Auto merged
mysql-test/r/derived.result:
  Auto merged
mysql-test/r/func_str.result:
  Simple merge
mysql-test/r/subselect.result:
  Automatic merge
mysql-test/t/derived.test:
  Automatic merge
mysql-test/t/func_str.test:
  Simple merge
mysql-test/t/subselect.test:
  Automatic merge
mysys/my_handler.c:
  Automatic merge
ndb/src/kernel/blocks/backup/Backup.cpp:
  Automatic merge
scripts/make_binary_distribution.sh:
  Automatic merge
scripts/mysql_install_db.sh:
  Automatic merge
sql/examples/ha_archive.cc:
  Simple merge
sql/ha_innodb.cc:
  Automatic merge
sql/item.cc:
  Merge
sql/item_cmpfunc.h:
  Automatic merge
sql/item_func.cc:
  Simple merge
sql/item_func.h:
  Automatic merge
sql/item_strfunc.cc:
  Automatic merge
sql/item_strfunc.h:
  Automatic merge
sql/item_subselect.cc:
  Automatic merge
sql/mysqld.cc:
  Automatic merge
sql/set_var.cc:
  Automatic merge
sql/sql_base.cc:
  Automatic merge
sql/sql_class.cc:
  Automatic merge
sql/sql_class.h:
  Automatic merge
sql/sql_lex.cc:
  Automatic merge
sql/sql_lex.h:
  Automatic merge
sql/sql_parse.cc:
  Automatic merge
sql/sql_select.cc:
  Automatic merge
sql/sql_table.cc:
  Automatic merge
sql/sql_update.cc:
  Simple merge
strings/ctype-big5.c:
  Automatic merge
strings/ctype-bin.c:
  Automatic merge
strings/ctype-gbk.c:
  Automatic merge
strings/ctype-latin1.c:
  Automatic merge
strings/ctype-mb.c:
  Automatic merge
strings/ctype-simple.c:
  Automatic merge
strings/ctype-sjis.c:
  Automatic merge
strings/ctype-tis620.c:
  Automatic merge
strings/ctype-ucs2.c:
  Automatic merge
strings/ctype-utf8.c:
  Automatic merge
vio/viosocket.c:
  Automatic merge
vio/viossl.c:
  Automatic merge
2005-02-03 13:18:30 +02:00
unknown
9fe76ad98b Merge sanja.is.com.ua:/home/bell/mysql/bk/mysql-4.1
into sanja.is.com.ua:/home/bell/mysql/bk/work-4.1


sql/item.cc:
  Auto merged
sql/sql_base.cc:
  Auto merged
sql/sql_lex.cc:
  Auto merged
sql/sql_select.cc:
  Auto merged
2005-02-01 11:05:29 +02:00
unknown
bf89dc063a Merge bk-internal.mysql.com:/home/bk/mysql-4.1
into mysql.com:/home/dlenev/src/mysql-4.1-tzbug


sql/item_timefunc.cc:
  Auto merged
sql/set_var.cc:
  Auto merged
sql/sql_lex.cc:
  Auto merged
sql/tztime.cc:
  Auto merged
2005-01-28 09:32:43 +03:00
unknown
20bd0bd6fd Fix for bug #7899 "CREATE TABLE .. SELECT .. and CONVERT_TZ() function
does not work well together". Now using simplier and more correct
implementation of st_lex::unlink_first_table()/link_first_table_back() 
(It also nicely handles case when global table list is created because
of implictly used time zone tables). (2nd attempt)

Fix for bug #7705 "CONVERT_TZ() crashes with subquery/WHERE on index
column". Implemented new approach for caching objects for constant
time zone arguments. Now instead of determining whenever these arguments
are constants and performing time zone lookup at fix_fields() stage, we
do it on first get_date() invocation.

Cleanup of global @@time_zone variable handling.


mysql-test/r/timezone2.result:
  Added test for bugs #7705 "CONVERT_TZ() crashes with subquery/WHERE on
  index column" and #7899 "CREATE TABLE .. SELECT .. and CONVERT_TZ()
  function does not work well together".
mysql-test/t/timezone2.test:
  Added test for bugs #7705 "CONVERT_TZ() crashes with subquery/WHERE on
  index column" and #7899 "CREATE TABLE .. SELECT .. and CONVERT_TZ()
  function does not work well together".
sql/item_timefunc.cc:
  Item_func_convert_tz():
    New approach for caching objects for constant time zone arguments.
    Now instead of determining whenever these arguments are constants
    and performing time zone lookup at fix_fields() stage, we do it
    on first get_date() invocation. This works better in cases when 
    const_item() for these arguments returns true only on get_date()
    stage but not on fix_fields() stage (e.g. this happens in quries
    with joins or derived tables).
sql/item_timefunc.h:
  Item_func_convert_tz():
    Added from_tz_cached/to_tz_cached members indicating whenever we
    already have Time_zone object representing one of constant time zone
    arguments.
sql/set_var.cc:
  Cleaned up global @@time_zone variable handling. Now we use proper
  locking when we are setting or reading its value.
sql/set_var.h:
  Removed declaration of sys_var_thd_time_zone::get_tz_ptr() method, which
  no longer used.
sql/sql_lex.cc:
  st_lex::unlink_first_table(), st_lex::link_first_table_back():
   Simplify implementation according to Monty's suggestion.
   Instead doing something special if global and local table lists
   are the same, we simply save/restore pointers to first elements
   of both global and local lists (which works even when this lists
   are the same!). This handles nicely the case when we have separate
   global table list becuase time zone tables are implicitly used.
sql/tztime.cc:
  Backport of Monty's fixes from 5.0, which give us nicer error messages
  if we haven't found time zone with such name or its description.
2005-01-26 22:25:02 +03:00
unknown
a82fd1eaec merged
BitKeeper/deleted/.del-sort.c~e2e56b5a37ce86f4:
  Auto merged
client/mysql.cc:
  Auto merged
client/mysqlbinlog.cc:
  Auto merged
client/mysqldump.c:
  Auto merged
client/mysqltest.c:
  Auto merged
myisam/ft_boolean_search.c:
  Auto merged
myisam/mi_packrec.c:
  Auto merged
myisam/sort.c:
  Auto merged
mysql-test/r/fulltext.result:
  Auto merged
sql/item_create.cc:
  Auto merged
sql/item_strfunc.cc:
  Auto merged
sql/item_timefunc.cc:
  Auto merged
sql/log.cc:
  Auto merged
sql/set_var.cc:
  Auto merged
sql/slave.cc:
  Auto merged
sql/sql_acl.h:
  Auto merged
sql/sql_analyse.cc:
  Auto merged
sql/sql_cache.cc:
  Auto merged
sql/sql_db.cc:
  Auto merged
sql/tztime.cc:
  Auto merged
tests/client_test.c:
  Auto merged
2005-01-24 19:41:42 +01:00
unknown
8bdb500105 fixes/cleanups according to Coverity report 2005-01-24 15:48:25 +01:00
unknown
7aecbab85c Merge with global tree
BitKeeper/etc/logging_ok:
  auto-union
client/mysql.cc:
  Auto merged
client/mysqldump.c:
  Auto merged
libmysql/libmysql.c:
  Auto merged
myisam/mi_open.c:
  Auto merged
mysql-test/r/order_by.result:
  Auto merged
sql/filesort.cc:
  Auto merged
sql/sql_select.cc:
  Auto merged
mysql-test/t/order_by.test:
  Merge
sql/sql_lex.cc:
  Merge
sql/sql_yacc.yy:
  Use local copy
2005-01-18 04:03:26 +02:00
unknown
1aa2d73da5 Merge sanja.is.com.ua:/home/bell/mysql/bk/mysql-4.1
into sanja.is.com.ua:/home/bell/mysql/bk/work-4.1


sql/sql_lex.cc:
  Auto merged
2005-01-18 01:15:02 +02:00
unknown
f6f90e7dc1 Bug #7966 query cache doesn't work properly with batch statements
sql_lex.cc:
  Set query to not cacheable if we are using multistatements and there are multiple statements in this query


sql/sql_lex.cc:
  Set query to not cacheable if we are using multistatements and there are multiple statements in this query
2005-01-17 13:40:36 -06:00
unknown
3c9170ed17 Merge sanja.is.com.ua:/home/bell/mysql/bk/mysql-4.1
into sanja.is.com.ua:/home/bell/mysql/bk/work-4.1


sql/sql_lex.cc:
  Auto merged
2005-01-16 18:36:50 +02:00
unknown
7f586778f3 postreview changes
sql/sql_lex.cc:
  layout fixed
2005-01-16 18:36:13 +02:00
unknown
88bd301d36 XA (not completely polished out yet)
include/my_pthread.h:
  cleanup. don't use gcc extensions
innobase/include/trx0sys.ic:
  Jan's fix for innobase_xa_prepare
innobase/read/read0read.c:
  Jan's fix for innobase_xa_prepare
innobase/trx/trx0trx.c:
  Jan's fix for innobase_xa_prepare
mysql-test/include/varchar.inc:
  test fix
mysql-test/r/ctype_ucs.result:
  new log event - all binlog positions are changed :(
mysql-test/r/drop_temp_table.result:
  new log event - all binlog positions are changed :(
mysql-test/r/insert_select.result:
  new log event - all binlog positions are changed :(
mysql-test/r/mix_innodb_myisam_binlog.result:
  new log event - all binlog positions are changed :(
mysql-test/r/myisam.result:
  test fix
mysql-test/r/rpl000015.result:
  new log event - all binlog positions are changed :(
mysql-test/r/rpl_change_master.result:
  new log event - all binlog positions are changed :(
mysql-test/r/rpl_charset.result:
  new log event - all binlog positions are changed :(
mysql-test/r/rpl_error_ignored_table.result:
  new log event - all binlog positions are changed :(
mysql-test/r/rpl_flush_log_loop.result:
  new log event - all binlog positions are changed :(
mysql-test/r/rpl_flush_tables.result:
  new log event - all binlog positions are changed :(
mysql-test/r/rpl_loaddata.result:
  new log event - all binlog positions are changed :(
mysql-test/r/rpl_loaddata_rule_m.result:
  new log event - all binlog positions are changed :(
mysql-test/r/rpl_loaddata_rule_s.result:
  new log event - all binlog positions are changed :(
mysql-test/r/rpl_log.result:
  new log event - all binlog positions are changed :(
mysql-test/r/rpl_log_pos.result:
  new log event - all binlog positions are changed :(
mysql-test/r/rpl_max_relay_size.result:
  new log event - all binlog positions are changed :(
mysql-test/r/rpl_relayrotate.result:
  new log event - all binlog positions are changed :(
mysql-test/r/rpl_replicate_do.result:
  new log event - all binlog positions are changed :(
mysql-test/r/rpl_reset_slave.result:
  new log event - all binlog positions are changed :(
mysql-test/r/rpl_rotate_logs.result:
  new log event - all binlog positions are changed :(
mysql-test/r/rpl_server_id1.result:
  new log event - all binlog positions are changed :(
mysql-test/r/rpl_server_id2.result:
  new log event - all binlog positions are changed :(
mysql-test/r/rpl_temporary.result:
  new log event - all binlog positions are changed :(
mysql-test/r/rpl_timezone.result:
  new log event - all binlog positions are changed :(
mysql-test/r/rpl_until.result:
  new log event - all binlog positions are changed :(
mysql-test/r/rpl_user_variables.result:
  new log event - all binlog positions are changed :(
mysql-test/r/user_var.result:
  new log event - all binlog positions are changed :(
mysql-test/t/ctype_ucs.test:
  new log event - all binlog positions are changed :(
mysql-test/t/mix_innodb_myisam_binlog.test:
  new log event - all binlog positions are changed :(
mysql-test/t/mysqlbinlog.test:
  new log event - all binlog positions are changed :(
mysql-test/t/mysqlbinlog2.test:
  new log event - all binlog positions are changed :(
mysql-test/t/rpl_charset.test:
  new log event - all binlog positions are changed :(
mysql-test/t/rpl_error_ignored_table.test:
  new log event - all binlog positions are changed :(
mysql-test/t/rpl_loaddata_rule_m.test:
  new log event - all binlog positions are changed :(
mysql-test/t/rpl_loaddata_rule_s.test:
  new log event - all binlog positions are changed :(
mysql-test/t/rpl_log.test:
  new log event - all binlog positions are changed :(
mysql-test/t/rpl_log_pos.test:
  new log event - all binlog positions are changed :(
mysql-test/t/rpl_user_variables.test:
  new log event - all binlog positions are changed :(
mysql-test/t/user_var.test:
  new log event - all binlog positions are changed :(
mysys/hash.c:
  typo fixed
sql/ha_berkeley.cc:
  handlerton framework
sql/ha_berkeley.h:
  handlerton framework
sql/ha_innodb.cc:
  handlerton framework
sql/ha_innodb.h:
  handlerton framework
sql/handler.cc:
  new transaction handling, handlerton framework, two-phase commit, XA support
sql/handler.h:
  new transaction handling, handlerton framework, two-phase commit, XA support
sql/lex.h:
  XA commands
sql/log.cc:
  new transaction handling, handlerton framework, two-phase commit,
  XA support, tc-logging, TC_LOG_MMAP class
sql/log_event.cc:
  Xid_log_event
sql/log_event.h:
  Xid_log_event, LOG_EVENT_BINLOG_CLOSED_F flag
sql/mysql_priv.h:
  wrapper for query_id++
sql/mysqld.cc:
  new command-line options --log-tc, --log-tc-size, --tc-heuristic-recover,
  new status variables Tc_log_page_size, Tc_log_max_pages_used, Tc_log_page_waits.
  init/stop tc logging
sql/set_var.h:
  warning fixed
sql/share/errmsg.txt:
  XA error messages
sql/sp_head.cc:
  s/query_id++/next_query_id()/
sql/sql_base.cc:
  typo fixed. new transaction handling.
sql/sql_class.cc:
  cleanup of THD.transaction
sql/sql_class.h:
  TC_LOG classes, new status variables, new savepoint handling, XA support
sql/sql_insert.cc:
  comments
sql/sql_lex.cc:
  s/found_colon/found_semicolon/
sql/sql_lex.h:
  SQLCOM_XA_xxx, XA related changes in Lex
sql/sql_parse.cc:
  cleanup, XA commands, new savepoint handling
sql/sql_repl.cc:
  two functions moved to log.cc
sql/sql_repl.h:
  two functions moved to log.cc
sql/sql_trigger.cc:
  s/lex.name_and_length/lex.ident/
sql/sql_yacc.yy:
  XA commands, cleanup
2005-01-16 13:16:23 +01:00
unknown
e7b38aa7bd Fixes for two compile-time failures.
ndb/src/common/transporter/TransporterRegistry.cpp:
  make it compile with -ansi -pedantic
sql/sql_lex.cc:
  a fix for compile-time failure
2005-01-11 15:32:23 +03:00
unknown
489bd55741 error of parsing can occur in any SELECT, so all SELECTs have to be checked 2005-01-11 11:53:39 +02:00
unknown
73c9909750 Merge with 4.1 tree to get fix for INSERT IGNORE ... ON DUPLICATE KEY
BitKeeper/etc/ignore:
  auto-union
BitKeeper/etc/logging_ok:
  auto-union
Makefile.am:
  Auto merged
client/mysqltest.c:
  Auto merged
configure.in:
  Auto merged
innobase/log/log0recv.c:
  Auto merged
myisam/mi_check.c:
  Auto merged
mysql-test/r/cast.result:
  Auto merged
mysql-test/r/drop.result:
  Auto merged
mysql-test/r/func_time.result:
  Auto merged
mysql-test/r/ps_2myisam.result:
  Auto merged
mysql-test/r/ps_3innodb.result:
  Auto merged
mysql-test/r/ps_4heap.result:
  Auto merged
mysql-test/r/ps_5merge.result:
  Auto merged
mysql-test/r/ps_6bdb.result:
  Auto merged
mysql-test/r/ps_7ndb.result:
  Auto merged
mysql-test/r/type_datetime.result:
  Auto merged
mysql-test/t/drop.test:
  Auto merged
mysql-test/t/func_time.test:
  Auto merged
ndb/include/ndb_global.h.in:
  Auto merged
ndb/src/kernel/blocks/suma/Suma.cpp:
  Auto merged
sql/ha_ndbcluster.h:
  Auto merged
sql/item_timefunc.h:
  Auto merged
sql/log_event.cc:
  Auto merged
sql/log_event.h:
  Auto merged
sql/set_var.cc:
  Auto merged
sql/sql_repl.cc:
  Auto merged
sql/sql_repl.h:
  Auto merged
sql/sql_select.cc:
  Auto merged
sql-common/my_time.c:
  Auto merged
sql/sql_union.cc:
  Auto merged
sql/sql_yacc.yy:
  Auto merged
sql/time.cc:
  Auto merged
innobase/row/row0upd.c:
  Trivial merge
mysql-test/t/func_concat.test:
  Keep local code
mysql-test/t/multi_update.test:
  auto merge
sql/ha_ndbcluster.cc:
  manual merge
sql/item_timefunc.cc:
  manual merge
sql/mysql_priv.h:
  manual merge
sql/sql_class.h:
  manual merge
sql/sql_delete.cc:
  manual merge
sql/sql_insert.cc:
  manual merge
sql/sql_lex.cc:
  manual merge
sql/sql_lex.h:
  manual merge
sql/sql_load.cc:
  manual merge
sql/sql_parse.cc:
  manual merge
sql/sql_table.cc:
  manual merge
sql/sql_update.cc:
  manual merge
2005-01-03 23:04:52 +02:00
unknown
2419fa2684 Remove DUP_IGNORE from enum_duplicates and instead use a separate ignore flag
This allows use to use INSERT IGNORE ... ON DUPLICATE ...


mysql-test/r/drop.result:
  safety fix
mysql-test/t/drop.test:
  safety fix
mysql-test/t/multi_update.test:
  ensure we cover all possible errors
sql/log_event.cc:
  Remove DUP_IGNORE from enum_duplicates and instead use a separate ignore flag
sql/log_event.h:
  Remove DUP_IGNORE from enum_duplicates and instead use a separate ignore flag
sql/mysql_priv.h:
  Remove DUP_IGNORE from enum_duplicates and instead use a separate ignore flag
sql/sql_class.h:
  Remove DUP_IGNORE from enum_duplicates and instead use a separate ignore flag
sql/sql_delete.cc:
  Remove DUP_IGNORE from enum_duplicates and instead use a separate ignore flag
sql/sql_insert.cc:
  Remove DUP_IGNORE from enum_duplicates and instead use a separate ignore flag
sql/sql_lex.cc:
  Remove DUP_IGNORE from enum_duplicates and instead use a separate ignore flag
sql/sql_lex.h:
  Remove DUP_IGNORE from enum_duplicates and instead use a separate ignore flag
sql/sql_load.cc:
  Remove DUP_IGNORE from enum_duplicates and instead use a separate ignore flag
sql/sql_parse.cc:
  Remove DUP_IGNORE from enum_duplicates and instead use a separate ignore flag
sql/sql_repl.cc:
  Remove DUP_IGNORE from enum_duplicates and instead use a separate ignore flag
sql/sql_repl.h:
  Remove DUP_IGNORE from enum_duplicates and instead use a separate ignore flag
sql/sql_select.cc:
  Remove DUP_IGNORE from enum_duplicates and instead use a separate ignore flag
sql/sql_table.cc:
  Remove DUP_IGNORE from enum_duplicates and instead use a separate ignore flag
sql/sql_union.cc:
  Remove DUP_IGNORE from enum_duplicates and instead use a separate ignore flag
sql/sql_update.cc:
  Remove DUP_IGNORE from enum_duplicates and instead use a separate ignore flag
sql/sql_yacc.yy:
  Remove DUP_IGNORE from enum_duplicates and instead use a separate ignore flag
2004-12-31 12:04:35 +02:00
unknown
12a215b083 Merge with global tree
BitKeeper/etc/logging_ok:
  auto-union
client/mysqltest.c:
  Auto merged
innobase/dict/dict0dict.c:
  Auto merged
innobase/include/dict0dict.h:
  Auto merged
libmysql/errmsg.c:
  Auto merged
myisam/mi_open.c:
  Auto merged
myisam/mi_write.c:
  Auto merged
mysql-test/r/grant.result:
  Auto merged
mysql-test/r/merge.result:
  Auto merged
mysql-test/r/show_check.result:
  Auto merged
mysql-test/t/derived.test:
  Auto merged
mysql-test/t/merge.test:
  Auto merged
mysql-test/t/show_check.test:
  Auto merged
mysql-test/t/system_mysql_db_fix.test:
  Auto merged
scripts/mysql_install_db.sh:
  Auto merged
sql/ha_innodb.cc:
  Auto merged
sql/handler.cc:
  Auto merged
sql/item.cc:
  Auto merged
sql/item_func.cc:
  Auto merged
sql/mysql_priv.h:
  Auto merged
sql/mysqld.cc:
  Auto merged
sql/set_var.cc:
  Auto merged
sql/sp.cc:
  Auto merged
sql/sql_acl.cc:
  Auto merged
sql/sql_base.cc:
  Auto merged
sql/sql_class.h:
  Auto merged
sql/sql_lex.cc:
  Auto merged
sql/sql_lex.h:
  Auto merged
sql/sql_parse.cc:
  Auto merged
sql/sql_select.cc:
  Auto merged
sql/sql_show.cc:
  Auto merged
sql/sql_yacc.yy:
  Auto merged
sql/table.cc:
  Auto merged
sql/table.h:
  Auto merged
sql/tztime.h:
  Auto merged
2004-12-31 00:50:30 +02:00
unknown
2e8d13c73e After merge fixes
config/ac-macros/character_sets.m4:
  Added latin1_spanish_ci
dbug/dbug_analyze.c:
  Remove compiler warnings
include/my_handler.h:
  Reorder structure arguments to be more optimal
innobase/dict/dict0load.c:
  Fixed wrong define tag (for MySQL 5.0)
innobase/fil/fil0fil.c:
  Fixed compiler warning
innobase/os/os0file.c:
  Fixed compiler warning
myisam/ft_boolean_search.c:
  Fixed compiler warning
myisam/ft_static.c:
  Update to use new HA_KEYSEG structure
myisam/mi_open.c:
  Simple optimization
myisammrg/myrg_static.c:
  Removed compiler warning
mysql-test/r/grant.result:
  Update results after merge
mysql-test/r/index_merge.result:
  Update results after merge
mysql-test/r/information_schema_inno.result:
  Add missing drop table
mysql-test/r/lowercase_table.result:
  safety fix
mysql-test/r/multi_update.result:
  safety fix
mysql-test/r/ps_1general.result:
  safety fix
mysql-test/r/ps_2myisam.result:
  Update results after merge
  (set is not anymore of binary type)
mysql-test/r/ps_3innodb.result:
  Update results after merge
mysql-test/r/ps_4heap.result:
  Update results after merge
mysql-test/r/ps_5merge.result:
  Update results after merge
mysql-test/r/ps_6bdb.result:
  Update results after merge
mysql-test/r/show_check.result:
  Update results after merge
mysql-test/r/subselect.result:
  Update results after merge
  (added missing quotes)
mysql-test/r/timezone2.result:
  Update results after merge
mysql-test/r/view.result:
  Update results after merge
  (note that INSERT IGNORE will work again after next merge from 4.1)
mysql-test/t/derived.test:
  Removed empty line
mysql-test/t/grant.test:
  Update results after merge
mysql-test/t/information_schema_inno.test:
  added missing drop table
mysql-test/t/lowercase_table.test:
  safety fix
mysql-test/t/multi_update.test:
  safety fix
mysql-test/t/ps_1general.test:
  safety fix
mysql-test/t/view.test:
  update error codes after merge
ndb/src/mgmsrv/main.cpp:
  after merge fix
ndb/tools/ndb_test_platform.cpp:
  removed compiler warnings
regex/main.c:
  remove compiler warnings
sql/field.cc:
  Remove compiler warning
sql/gen_lex_hash.cc:
  Added DBUG support
sql/ha_myisam.cc:
  Removed warning from valgrind
sql/ha_ndbcluster.cc:
  Remove compiler warning
sql/item_cmpfunc.cc:
  Better to use val_int() instead of val_real() as we don't want Item_func_nop_all to return different value than the original ref element
sql/mysqld.cc:
  Remove compiler warning
sql/sql_acl.cc:
  More debugging
sql/sql_lex.cc:
  Remove unnecessary 'else'
sql/sql_parse.cc:
  After merge fixes
  Simplify reset of thd->server_status for SQLCOM_CALL
sql/sql_prepare.cc:
  After merge fixes
  Removed possible core dump in mysql_stmt_fetch()
sql/sql_update.cc:
  After merge fixes (together with Sanja)
strings/ctype-czech.c:
  Remove compiler warning
strings/ctype-ucs2.c:
  Remove compiler warning
strings/ctype-win1250ch.c:
  Remove compiler warning
strings/xml.c:
  Remove compiler warning
tests/client_test.c:
  Fix test to work with 5.0
vio/test-sslserver.c:
  Portability fix
2004-12-31 00:44:00 +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
52793e03c0 Merge bk-internal.mysql.com:/home/bk/mysql-5.0
into mysql.com:/home/dlenev/src/mysql-5.0-tzbug


sql/sql_lex.cc:
  Auto merged
sql/sql_parse.cc:
  Auto merged
sql/sql_yacc.yy:
  Auto merged
2004-12-19 11:32:21 +03:00
unknown
d7285006cf bit type 2004-12-17 18:06:05 +04:00
unknown
bc152db579 Fix for bug #6849 "Crash while preparing query containing const expr with
IN and CONVERT_TZ()" (with after review changes).

Now we add implicitly used time zone tables to global table list right
at the parsing stage instead of doing it later in mysql_execute_command()
or in check_prepared_statement().

No special test-case needed since this bug also manifests itself as
timezone2.test failure if one runs it with --ps-protocol option.


sql/sql_base.cc:
  relink_tables_for_multidelete(): 
   presence of implicitly used time zone tables is no longer condition for
   propagation of TABLE pointers from global table list to local table
   lists (since now global list is always created...)
sql/sql_lex.cc:
  - Added LEX::add_time_zone_tables_to_query_tables() function which adds
    implicitly used time zone tables to global table list.
  - Definition of fake_time_zone_tables_list moved to tztime.cc, since
    it is no longer used in parser.
sql/sql_lex.h:
  - Since now we add implicitly used time zone tables right at parsing
    stage, LEX::time_zone_tables_used is either zero or points to valid
    time zone tables list. Updated its description to reflect that.
  - Added LEX::add_time_zone_tables_to_query_tables() function which adds
    implicitly used time zone tables to global table list.
  - Declaration of fake_time_zone_tables_list moved to tztime.h,
    since it is no longer used in parser.
sql/sql_parse.cc:
  mysql_execute_command():
    Removed adding list of implicitly used time zone tables to global table
    list, since now we do this right at the parsing stage.
sql/sql_yacc.yy:
  Let us add implicitly used time zone tables to global table list
  right at the parsing stage instead of doing it later in
  mysql_execute_command() or in check_prepared_statement().
sql/tztime.cc:
  Moved fake_time_zone_tables_list definition from sql_lex.cc to
  tztime.cc since now it is used only for error reporting from
  my_tz_get_table_list() function.
sql/tztime.h:
  Moved fake_time_zone_tables_list declaration from sql_lex.h to
  tztime.h since now it is used only for error reporting from
  my_tz_get_table_list() function.
2004-12-17 15:34:48 +03:00
unknown
46364ddb19 WL#2274 - INSERT..SELECT..UPDATE
UPDATE clause conflicts with SELECT for use of item_list field.
  Alter UPDATE clause to use new lex field update_list
  Tests included


mysql-test/r/insert_update.result:
  WL#2274
    New tests for INSERT..SELECT..UPDATE
mysql-test/t/insert_update.test:
  WL#2274
    New tests for INSERT..SELECT..UPDATE
sql/mysql_priv.h:
  Remove function - insert_select_precheck()
sql/sql_class.h:
  WL#2274
    New constructor for class select_insert
sql/sql_insert.cc:
  WL#2274
    Move code into mysql_prepare_insert
    Add checks as param values may be NULL
sql/sql_lex.cc:
  WL#2274
    initialize lex->update_list
sql/sql_lex.h:
  WL#2274
    New field in LEX: update_list
sql/sql_parse.cc:
  WL#2274
    INSERT..UPDATE clause now populates lex->update_list
    Remove redundant function: insert_select_precheck()
sql/sql_prepare.cc:
  WL#2274
    invoke insert_precheck() instead of insert_select_precheck()
sql/sql_yacc.yy:
  WL#2274
    Enable INSERT..SELECT..UPDATE syntax
    New rule - insert_update_list, to populate lex->update_list
2004-12-13 12:26:28 +00:00
unknown
a1fba2dacc After merge fixes
Fixed compiler warnings
Fix core dump when sending SIGHUP to mysqld


mysql-test/r/drop_temp_table.result:
  After merge fixes
mysql-test/r/grant.result:
  After merge fixes
mysql-test/r/group_min_max.result:
  After merge fixes
mysql-test/r/innodb.result:
  After merge fixes
mysql-test/r/insert_select.result:
  After merge fixes
mysql-test/r/rpl_charset.result:
  After merge fixes
mysql-test/r/rpl_create_database.result:
  After merge fixes
mysql-test/r/rpl_loaddata_rule_m.result:
  After merge fixes
mysql-test/t/rpl_charset.test:
  After merge fixes
mysql-test/t/rpl_create_database.test:
  After merge fixes
sql-common/client.c:
  After merge fixes
sql/item.cc:
  After merge fixes
sql/mysqld.cc:
  Fix core dump when sending SIGHUP to mysqld
sql/sql_acl.cc:
  Better comment
sql/sql_derived.cc:
  Fixed comment
  Added missing DBUG_RETURN
sql/sql_insert.cc:
  Fixed compiler warnings
  After merge fixes
sql/sql_lex.cc:
  After merge fixes
  Removed compiler warnings
sql/sql_parse.cc:
  After merge fixes
sql/sql_select.cc:
  More debugging
sql/sql_table.cc:
  Added missing DBUG_VOID_RETURN
sql/sql_update.cc:
  Fixed compiler warning
sql/sql_view.cc:
  Added missing DBUG_RETURN
  Fixed compiler warnings
  Added flag to signal that the view is a derived table
2004-12-06 17:15:54 +02:00
unknown
796bd7de96 Merge with 4.1
BitKeeper/etc/ignore:
  auto-union
BitKeeper/etc/logging_ok:
  auto-union
BUILD/SETUP.sh:
  Auto merged
Build-tools/Do-compile:
  Auto merged
client/mysqladmin.cc:
  Auto merged
configure.in:
  Auto merged
innobase/include/lock0lock.h:
  Auto merged
innobase/os/os0file.c:
  Auto merged
libmysqld/Makefile.am:
  Auto merged
mysql-test/mysql-test-run.sh:
  Auto merged
mysql-test/r/ctype_ucs.result:
  Auto merged
mysql-test/r/heap.result:
  Auto merged
mysql-test/r/insert_select.result:
  Auto merged
mysql-test/r/lowercase_table3.result:
  Auto merged
mysql-test/r/rpl_start_stop_slave.result:
  Auto merged
mysql-test/r/subselect.result:
  Auto merged
mysql-test/t/ctype_ucs.test:
  Auto merged
mysql-test/t/rpl_until.test:
  Auto merged
mysql-test/t/subselect.test:
  Auto merged
ndb/src/kernel/blocks/dblqh/DblqhMain.cpp:
  Auto merged
sql/field.cc:
  Auto merged
sql/field.h:
  Auto merged
sql/ha_myisam.h:
  Auto merged
sql/handler.cc:
  Auto merged
sql/handler.h:
  Auto merged
sql/item.h:
  Auto merged
sql/item_cmpfunc.cc:
  Auto merged
sql/item_func.cc:
  Auto merged
sql/lock.cc:
  Auto merged
sql/log_event.h:
  Auto merged
sql/mysql_priv.h:
  Auto merged
sql/mysqld.cc:
  Auto merged
sql/set_var.cc:
  Auto merged
sql/slave.cc:
  Auto merged
sql/slave.h:
  Auto merged
sql/sql_acl.cc:
  Auto merged
sql/sql_base.cc:
  Auto merged
sql/sql_class.h:
  Auto merged
sql/sql_db.cc:
  Auto merged
sql/sql_delete.cc:
  Auto merged
sql/sql_prepare.cc:
  Auto merged
sql/sql_rename.cc:
  Auto merged
sql/sql_select.cc:
  Auto merged
sql/sql_show.cc:
  Auto merged
sql/sql_update.cc:
  Auto merged
sql/sql_yacc.yy:
  Auto merged
sql/log_event.cc:
  Merge with 4.1
  Trivial cleanup
2004-12-06 11:38:56 +02:00
unknown
a49025d2c8 now we create temporary join for all queries with subqueries to make correct cleunup of tables and avoid too early unlock (BUG#6841)
mysql-test/t/subselect_innodb.test:
  possible early unlock
sql/sql_lex.cc:
  subqueries presence flag
sql/sql_lex.h:
  subqueries presence flag
sql/sql_parse.cc:
  subqueries presence flag
sql/sql_select.cc:
  removed some too optimistic optimisation, now we create temporary join for all queries with subqueries to make correct cleunup of tables and avoid too early unlock
2004-11-30 21:41:12 +02:00
unknown
d777a9aa6a Change sql_mode BROKEN_NOT to HIGH_NOT_PRECEDENCE 2004-11-27 19:26:46 +00:00
unknown
a352372170 Merge sanja.is.com.ua:/home/bell/mysql/bk/mysql-5.0
into sanja.is.com.ua:/home/bell/mysql/bk/work-join-5.0


sql/item.cc:
  Auto merged
sql/item.h:
  Auto merged
sql/mysql_priv.h:
  Auto merged
sql/sp.cc:
  Auto merged
sql/sql_base.cc:
  Auto merged
sql/sql_lex.cc:
  Auto merged
sql/sql_lex.h:
  Auto merged
sql/sql_parse.cc:
  Auto merged
sql/sql_select.cc:
  Auto merged
sql/sql_yacc.yy:
  Auto merged
sql/table.h:
  Auto merged
2004-11-25 02:27:02 +02:00
unknown
239cdc27dc 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


sql/item.cc:
  Auto merged
sql/item.h:
  Auto merged
sql/sql_lex.cc:
  Auto merged
sql/sql_lex.h:
  Auto merged
sql/table.h:
  Auto merged
2004-11-24 20:01:34 +02:00
unknown
c774eb0e6d fixed problem in MacOS
correct printing of aliases


mysql-test/r/lowercase_view.result:
  aliases in VIEWs
mysql-test/t/lowercase_view.test:
  aliases in VIEWs
sql/item.cc:
  tracking using aliases in indentifiers
sql/item.h:
  tracking using aliases in indentifiers
sql/sql_base.cc:
  tracking using aliases in indentifiers
sql/sql_lex.cc:
  tracking using aliases in indentifiers
sql/sql_lex.h:
  tracking using aliases in indentifiers
sql/table.h:
  tracking using aliases in indentifiers
2004-11-24 19:48:30 +02:00
unknown
c3da2d12f7 Fix for bug #5888 "Triggers with nonexistent columns cause packets
out of order". (final version)

Now instead of binding Item_trigger_field to TABLE objects during
trigger definition parsing at table open, we perform pass through
special list of all such objects in trigger. This allows easily check
all references to fields in old/new version of row in trigger during
execution of CREATE TRIGGER statement (this is more courtesy for users
since we can't check everything anyway).
We also report that such reference is bad by returning error from
Item_trigger_field::fix_fields() method (instead of setup_field())
This means that if trigger is broken we will bark during trigger
execution instead of trigger definition parsing at table open.
(i.e. now we allow to open tables with broken triggers).


mysql-test/r/trigger.result:
  Added test which attempts to create trigger for table referencing to
  field which does not exist in this table.
mysql-test/t/trigger.test:
  Added test which attempts to create trigger for table referencing to
  field which does not exist in this table.
sql/item.cc:
  Item_trigger_field::setup_field() now returns void. If any error
  will occur we will report it at fix_fields() stage.
sql/item.h:
  Item_trigger_field:
  - Added next_trg_field member for linking all such objects in trigger
    in one list.
  - Also setup_field() now returns void. If any error will occur we will
    report it at fix_fields() stage.
sql/mysql_priv.h:
  Added SQL_LIST::push_back() method which allows to add another SQL_LIST
  to the end of this SQL_LIST.
sql/sp_head.cc:
  sp_head::init()/reset_lex()/restore_lex():
   In order to fill global LEX::trg_table_fields (list of all 
   Item_trigger_field objects for trigger) we should init the same list
   in LEX of substatement before its parsing and merge it to global list
   after parsing.
sql/sp_head.h:
  sp_instr_trigger_field:
    Made trigger_field member public to be able to add it more easily to
    global list of all Item_trigger_field objects in trigger.
sql/sql_lex.cc:
  LEX::trg_table was removed.
sql/sql_lex.h:
  Now we are binding Item_trigger_field's to TABLE object by passing
  through specially constructed list of all such objects in this trigger
  instead of doing this during trigger definition parsing at table open.
  So we no longer need LEX::trg_table, we use LEX::trg_table_fields list
  instead.
sql/sql_parse.cc:
  mysql_execute_command():
    Since now we use trigger body for some checks in
    mysql_create_or_drop_trigger() we should destroy it only
    after calling this function.
sql/sql_trigger.cc:
  Now instead of binding Item_trigger_field to TABLE objects during
  trigger definition parsing at table open, we perform pass through
  special list of all such objects in trigger. This allows easily check
  all references to fields in old/new version of row in trigger during
  execution of CREATE TRIGGER statement (this is more courtesy for users
  since we can't check everything anyway).
  We also report that such reference is bad by returning error from
  Item_trigger_field::fix_fields() method (instead of setup_field())
  This means that if trigger is broken we will bark during trigger
  execution instead of trigger definition parsing at table open.
  (i.e. now we allow to open tables with broken triggers).
  
  Table_triggers_list::prepare_old_row_accessors() method was added to be
  able to reuse code creating Field objects referencing TABLE::record[1]
  buffer instead of TABLE::record[0].
sql/sql_trigger.h:
  Added Table_triggers_list::prepare_old_row_accessors() method to be
  able to reuse code creating Field objects referencing to TABLE::record[1]
  instead of record[0].
sql/sql_yacc.yy:
  Now instead of performing binding of Item_trigger_field objects
  to TABLE object during trigger definition parsing at table open,
  we perform this binding by passing through specially constructed
  list of all such items in trigger.
  We also check value returned from memory allocation functions.
2004-11-24 12:24:02 +03:00
unknown
5a00a868b7 merge
sql/item.cc:
  Auto merged
sql/item.h:
  Auto merged
sql/item_cmpfunc.h:
  Auto merged
sql/item_subselect.cc:
  Auto merged
sql/mysql_priv.h:
  Auto merged
sql/opt_sum.cc:
  Auto merged
sql/sp.cc:
  Auto merged
sql/sql_acl.cc:
  Auto merged
sql/sql_class.h:
  Auto merged
sql/sql_delete.cc:
  Auto merged
sql/sql_help.cc:
  Auto merged
sql/sql_lex.cc:
  Auto merged
sql/sql_load.cc:
  Auto merged
sql/sql_parse.cc:
  Auto merged
sql/sql_select.cc:
  Auto merged
sql/sql_view.h:
  Auto merged
sql/sql_yacc.yy:
  Auto merged
2004-11-21 20:08:12 +02:00
unknown
c9497e2365 post merge 2004-11-21 19:33:49 +02:00
unknown
191fa29932 WL#638 - Fix precedence for parsing NOT ... LIKE expression s
Rework parser expression rules
  Rework handling for "||" concat/or
  Eliminate some shift/reduce conflicts
  Add support for "xxx IS [ NOT ] truth_value"


mysql-test/r/ansi.result:
  Fix test for new BROKEN_NOT mode bit
mysql-test/r/bool.result:
  WL#638
    New test for BROKEN_NOT mode
    New test for "expr IS [NOT] truth_value" syntax
mysql-test/r/sql_mode.result:
  Fix test for new BROKEN_NOT mode bit
mysql-test/t/bool.test:
  WL#638
    New test for BROKEN_NOT mode
    New test for "expr IS [NOT] truth_value" syntax
sql/lex.h:
  WL#638
    "&&" and "AND" return different tokens,
    NOT token changed to NOT_SYM
    OR_OR_CONCAT token changed to OR_OR_SYM
    New token "UNKNOWN"
sql/mysql_priv.h:
  WL#638
    New mode: BROKEN_NOT
sql/mysqld.cc:
  WL#638
    New mode: BROKEN_NOT
sql/set_var.cc:
  WL#638
    New mode: BROKEN_NOT
    BROKEN_NOT is set in MYSQL323 and MYSQL40 modes
sql/sql_lex.cc:
  Bug#638
    Alter tokens returned by lexer depending upon sql_mode:
    Return NOT2_SYM token instead of NOT_SYM when in BROKEN_NOT mode
    Return OR2_SYM token instead of OR_OR_SYM when not in PIPES_AS_CONCAT mode
sql/sql_yacc.yy:
  WL#638
    Change grammar to respect proper SQL syntax for NOT
    Clean up grammar, eliminate >100 shift/reduce conflicts
    New support for "expr IS [NOT] truth_value" SQL syntax
    Remove or_or_concat() support func. New support func is_truth_value()
2004-11-17 15:49:10 +00:00
unknown
b685909d6a moved procedure list initialization (BUG#6517)
mysql-test/r/subselect.result:
  Subselect in non-select command just after connection
mysql-test/t/subselect.test:
  Subselect in non-select command just after connection
sql/sql_lex.cc:
  moved procedure initialization
sql/sql_parse.cc:
  moved procedure initialization
2004-11-15 14:37:40 +02:00
unknown
ac0cd2d3ac marge
sql/ha_innodb.cc:
  Auto merged
sql/ha_innodb.h:
  Auto merged
sql/item_strfunc.cc:
  Auto merged
sql/log.cc:
  Auto merged
sql/mysqld.cc:
  Auto merged
sql/sql_acl.cc:
  Auto merged
sql/sql_base.cc:
  Auto merged
sql/sql_delete.cc:
  Auto merged
sql/sql_lex.cc:
  Auto merged
sql/share/french/errmsg.txt:
  Auto merged
sql/share/greek/errmsg.txt:
  Auto merged
sql/sql_lex.h:
  Auto merged
sql/sql_select.cc:
  Auto merged
sql/sql_table.cc:
  Auto merged
sql/sql_view.cc:
  Auto merged
sql/sql_yacc.yy:
  Auto merged
sql/table.cc:
  Auto merged
sql/share/portuguese/errmsg.txt:
  Auto merged
sql/share/romanian/errmsg.txt:
  Auto merged
sql/share/serbian/errmsg.txt:
  Auto merged
sql/share/spanish/errmsg.txt:
  Auto merged
sql/share/swedish/errmsg.txt:
  Auto merged
sql/mysql_priv.h:
  merge
sql/sql_parse.cc:
  merge
sql/sql_show.cc:
  merge
2004-11-13 19:45:36 +02:00
unknown
7281d2e3ae WL#1629: SHOW with WHERE(partially) &
WL#173:  Create Data Dictionary Tables for SHOW Commands
2004-11-13 13:56:39 +03: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
3bc1fcd409 merge
sql/item_cmpfunc.h:
  Auto merged
sql/item_subselect.cc:
  Auto merged
sql/mysql_priv.h:
  Auto merged
sql/opt_sum.cc:
  Auto merged
sql/sp.cc:
  Auto merged
sql/sql_class.h:
  Auto merged
sql/sql_delete.cc:
  Auto merged
sql/sql_help.cc:
  Auto merged
sql/sql_lex.cc:
  Auto merged
sql/sql_lex.h:
  Auto merged
sql/sql_load.cc:
  Auto merged
sql/sql_prepare.cc:
  Auto merged
sql/sql_select.cc:
  Auto merged
sql/sql_view.h:
  Auto merged
sql/sql_yacc.yy:
  Auto merged
2004-11-11 21:18:10 +02:00
unknown
cd16e4c9c7 Simple optimization to avoid a malloc for each query 2004-11-09 15:50:33 +02:00
unknown
8b0ece5e88 new lock for multiupdate:
- open and create derived tables
- detect which tables should be locked for write
- lock and fill derived tables
some unitialized variables fixed


mysql-test/r/lock_multi.result:
  correct results returned
mysql-test/r/multi_update.result:
  correct results returned
mysql-test/r/view.result:
  correct results returned
mysql-test/t/multi_update.test:
  correct results returned
mysql-test/t/view.test:
  correct results returned
sql/mysql_priv.h:
  derived tables processing splited on table creation and table filling
sql/sql_base.cc:
  derived tables processing splited on table creation and table filling
sql/sql_class.h:
  function to detect when we need fill derived tables
sql/sql_derived.cc:
  derived tables processing splited on table creation and table filling
sql/sql_lex.cc:
  fixed uninitialized value
sql/sql_load.cc:
  fixed uninitialized value
sql/sql_parse.cc:
  initialization muved (will be done for all queries)
sql/sql_prepare.cc:
  preparation of multiupdate changed a bit because new locking procedure
sql/sql_update.cc:
  new lock for multiupdate:
  - open and create derived tables
  - detect which tables should be locked for write
  - lock and fill derived tables
sql/table.h:
  place to store select_result between creation and filling tables
2004-11-05 17:29:47 +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
4d204f4303 added support of view and CHECK OPTION of view to LOAD DATA (BUG#5996)
mysql-test/r/view.result:
  LOAD DATA with view and CHECK OPTION
mysql-test/t/view.test:
  LOAD DATA with view and CHECK OPTION
sql/log_event.cc:
  new parameter for load data
sql/mysql_priv.h:
  new parameter for load data
sql/sql_lex.cc:
  LOAD DATA supported by view
sql/sql_load.cc:
  added support of view and CHECK OPTION of view to LOAD DATA
sql/sql_parse.cc:
  new parameter for CHECK OPTION
2004-10-21 21:53:27 +03:00
unknown
46b10a307f Merge bk-internal.mysql.com:/home/bk/mysql-4.1
into mishka.local:/home/my/mysql-4.1


sql/item_cmpfunc.h:
  Auto merged
sql/item_strfunc.cc:
  Auto merged
sql/sql_lex.cc:
  Auto merged
sql/sql_parse.cc:
  Auto merged
sql/sql_prepare.cc:
  Auto merged
sql/sql_table.cc:
  Auto merged
sql/sql_yacc.yy:
  Auto merged
2004-10-14 18:06:38 +03:00
unknown
3307318917 true,false -> TRUE, FALSE
Simple fixes/optimization of things discovered during review of new pushed code


include/my_sys.h:
  Ensure that clear_alloc_root() interacts correctly with alloc_root_inited()
mysys/hash.c:
  More comments
  Simple optimization (merge identical code)
mysys/my_bitmap.c:
  Change inline -> static inline
sql/examples/ha_archive.cc:
  Fixed compiler warning
sql/ha_ndbcluster.cc:
  true,false -> TRUE, FALSE
  Change if (false) -> #ifdef NOT_USED
sql/ha_ndbcluster.h:
  true,false -> TRUE, FALSE
sql/handler.cc:
  More comments
  Remove not needed initializations.
  #ifdef not used code
sql/item_cmpfunc.h:
  true,false -> TRUE, FALSE
sql/item_strfunc.cc:
  Move local variables to function beginning
  Remove wrong comments
sql/log_event.h:
  true,false -> TRUE, FALSE
sql/sql_base.cc:
  true,false -> TRUE, FALSE
  More comments
sql/sql_help.cc:
  true,false -> TRUE, FALSE
sql/sql_lex.cc:
  Simple optimization of new code
sql/sql_parse.cc:
  true,false -> TRUE, FALSE
sql/sql_prepare.cc:
  true,false -> TRUE, FALSE
sql/sql_table.cc:
  true,false -> TRUE, FALSE
sql/sql_yacc.yy:
  true,false -> TRUE, FALSE
2004-10-14 18:03:46 +03:00
unknown
54b00f5453 A fix and test case for Bug#5985 ""prepare stmt from "select rand(?)"
crashes server." The fix makes Item_func_rand prepared-statements
aware plus it fixes the case when RAND is used in prepared
statements and replication is on (as well as several similar issues).
Until now we did not reset THD before every execution of a prepared
statement, so if some execution had set thd->time_zone_used
or thd->rand_used they would not be reset until next mysql_parse.
Some of post-review fixes done.


mysql-test/r/ps.result:
  A test case for Bug#5985: test results fixed.
mysql-test/t/ps.test:
  A test case for Bug#5985 "prepare stmt from "select rand(?)" crashes
  server."
sql/item_func.cc:
  Actual fix for Bug#5985: Item_func_rand rewritten to be 
  prepared statements aware.
sql/item_func.h:
  Actual fix for Bug#5985: Item_func_rand rewritten to be 
  prepared statements aware.
sql/mysql_priv.h:
  We need a separate call to reset THD state before every execute of
  a prepared statement. Otherwise things like THD->user_var_events
  are never cleaned up and bloat binary log (as the list of events
  grows from execution to execution).
sql/sql_class.cc:
  Statement::end_statement -> THD::end_statement()
  (a leftover from some design change which is not to pushed now, but the
  leftover is to be pushed).
sql/sql_class.h:
  Statement::end_statement -> THD::end_statement()
  (a leftover from some design change which is not to pushed now, but the
  leftover is to be pushed).
sql/sql_lex.cc:
  Move the part responsible for initializing LEX from mysql_init_query
  to lex_start.
sql/sql_lex.h:
  All lex-related initialization is now in lex_start.
  Move thd->select_number to lex->select_number to be able to use it
  easily in lex_start.
sql/sql_parse.cc:
  Split mysql_init_query into two functions: mysql_reset_thd_for_next_query,
  which is used in PS and conventional execution, and lex_start, used only
  when we want to parse something.
  Fix init_connect to use initialized THD.
sql/sql_prepare.cc:
  Deploy mysql_reset_thd_for_next_query to reset THD state before
  execution of a prepared statement.
  Normally this should have been added to just one place, but
  we have to reset thd before assigning placeholders from variables,
  thus we can't do that in execute_stmt (yuck).
2004-10-14 02:53:59 +04:00
unknown
1e623bb9c3 allow merging views with subqueries in WHERE clause (BUG#5504)
mysql-test/r/view.result:
  test of subqueries in merged views
mysql-test/t/view.test:
  test of subqueries in merged views
sql/item_subselect.h:
  new method tu return place of subquery
sql/sql_lex.cc:
  allow merging views with subqueries in WHERE clause
sql/sql_view.cc:
  allow merging views with subqueries in WHERE clause
2004-10-07 22:54:31 +03:00
unknown
5b82bc6644 merge
sql/sql_lex.cc:
  Auto merged
sql/sql_parse.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
2004-10-07 11:36:46 +03:00
unknown
640fefffa7 fixed & added comments (according to Igor's review and a bit more)
sql/item_strfunc.h:
  spelling fixed
sql/parse_file.cc:
  spelling fixed
sql/parse_file.h:
  spelling fixed
sql/password.c:
  spelling fixed
sql/sql_acl.cc:
  spelling fixed
sql/sql_lex.cc:
  comments added and fixed
sql/sql_parse.cc:
  spelling fixed
sql/sql_show.cc:
  spelling fixed
sql/sql_update.cc:
  comments fixed
sql/sql_view.cc:
  comments added
  spelling and comments fixed
  // comments changed with /* */ ones
sql/sql_yacc.yy:
  comments fixed
sql/table.cc:
  spelling fixed
  comments added and fixed
sql/table.h:
  spelling fixed
  comments fixed
2004-10-07 01:45:06 +03:00
unknown
1bd580aa68 wording fixed 2004-09-16 18:37:26 +03:00
unknown
e754501a12 Merge sanja.is.com.ua:/home/bell/mysql/bk/mysql-4.1
into sanja.is.com.ua:/home/bell/mysql/bk/work-update-4.1


sql/sql_lex.cc:
  Auto merged
sql/sql_parse.cc:
  Auto merged
2004-09-16 17:47:53 +03:00
unknown
55a8c28c27 fixed merged view fields names (BUG#5147)
support of merged VIEW over several tables added (WL#1809)


mysql-test/r/view.result:
  merge of VIEW with several tables
mysql-test/t/view.test:
  merge of VIEW with several tables
sql/item.cc:
  renaming Item and restoring item name on cleunup()
sql/item.h:
  renaming Item and restoring item name on cleunup()
  debug output added
sql/item_cmpfunc.h:
  setup_conds() changed to support two tables lists
sql/item_subselect.cc:
  list of table leaves used instead of local table list for name resolving
sql/mysql_priv.h:
  setup_conds() and setup_tables() changed to support two tables lists
sql/opt_sum.cc:
  list of table leaves used instead of local table list for name resolving
sql/sp.cc:
  setup_tables() changed to support two tables lists
sql/sql_base.cc:
  skip temporary tables in table finding
  fixed merged view fields names (BUG#5147)
sql/sql_delete.cc:
  setup_conds() and setup_tables() changed to support two tables lists
sql/sql_help.cc:
  setup_tables() changed to support two tables lists
sql/sql_insert.cc:
  setup_tables() changed to support two tables lists
  name handling support
sql/sql_lex.cc:
  allow view with several tables for MERGE
sql/sql_lex.h:
  new table list
sql/sql_load.cc:
  setup_tables() changed to support two tables lists
sql/sql_olap.cc:
  setup_tables() changed to support two tables lists
sql/sql_parse.cc:
  new list support
sql/sql_prepare.cc:
  new list support
sql/sql_select.cc:
  list of table leaves used instead of local table list for name resolving
sql/sql_update.cc:
  setup_conds() and setup_tables() changed to support two tables lists
sql/sql_view.cc:
  support of MERGED VIEWS with several tables
sql/sql_yacc.yy:
  removed blanks in new code
sql/table.cc:
  fixed setup view code
  support of merged VIEW over several tables added
sql/table.h:
  fixed merged view fields names (BUG#5147)
2004-09-14 19:28:29 +03:00
unknown
b4e557fdd6 BUG#5318 - failure: 'IGNORE_SPACE' affects numeric values after DEFAULT.
Added a check to recover from IGNORE_SPACE in this situation: 
<ident-character(s)><space><dot><ident-character(s)>
The ignored space led to the false identification of the dot
as an ident separator (like "db.table").


mysql-test/r/sql_mode.result:
  BUG#5318 - failure: 'IGNORE_SPACE' affects numeric values after DEFAULT.
  Added the test results.
mysql-test/t/sql_mode.test:
  BUG#5318 - failure: 'IGNORE_SPACE' affects numeric values after DEFAULT.
  Added new tests for the bug.
sql/sql_lex.cc:
  BUG#5318 - failure: 'IGNORE_SPACE' affects numeric values after DEFAULT.
  Added code to recover from skipped spaces in mode IGNORE_SPACES,
  when testing for an ident separator (which happens to be a dot).
2004-09-14 13:49:08 +02:00
unknown
f3d4db99c3 Merge sanja.is.com.ua:/home/bell/mysql/bk/mysql-5.0
into sanja.is.com.ua:/home/bell/mysql/bk/work-show-5.0


sql/item.cc:
  Auto merged
sql/item.h:
  Auto merged
sql/mysql_priv.h:
  Auto merged
sql/sql_base.cc:
  Auto merged
sql/sql_delete.cc:
  Auto merged
sql/sql_insert.cc:
  Auto merged
sql/sql_lex.cc:
  Auto merged
sql/sql_parse.cc:
  Auto merged
sql/sql_update.cc:
  Auto merged
sql/table.h:
  Auto merged
2004-09-10 02:26:09 +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
eb75a9fd8d Yet another manual merge with main tree for patch for WL#1218 "Triggers"
sql/item.cc:
  Auto merged
sql/item.h:
  Auto merged
sql/item_func.cc:
  Auto merged
sql/item_func.h:
  Auto merged
sql/lex.h:
  Auto merged
sql/sql_base.cc:
  Auto merged
sql/sql_delete.cc:
  Auto merged
sql/sql_insert.cc:
  Auto merged
sql/sql_lex.h:
  Auto merged
sql/sql_parse.cc:
  Auto merged
sql/sql_table.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/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
include/mysqld_error.h:
  Manual merge.
sql/Makefile.am:
  Manual merge.
sql/mysql_priv.h:
  Manual merge.
sql/sp_head.cc:
  Manual merge.
sql/sql_lex.cc:
  Manual merge.
sql/sql_yacc.yy:
  Manual merge.
2004-09-09 19:52:10 +04:00
unknown
e18b7ea959 Merge on pull
BitKeeper/etc/logging_ok:
  auto-union
include/my_sys.h:
  Auto merged
mysql-test/r/func_in.result:
  Auto merged
2004-09-09 07:26:28 +03:00
unknown
33efc9677d After merge fixes of merge with 4.1 that included the new arena code.
Fixed (together with Guilhem) bugs in mysqlbinlog regarding --offset
Prefix addresses with 0x for easier comparisons of debug logs
Fixed problem where MySQL choosed index-read even if there would be a much better range on the same index
This fix changed some 'index' queries to 'range' queries in the test suite
Don't create 'dummy' WHERE clause for trivial WHERE clauses where we can remove the WHERE clause.
This fix removed of a lot of 'Using where' notes in the test suite.
Give NOTE instead of WARNING if table/function doesn't exists when using DROP IF EXISTS
Give NOTE instead of WARNING for safe field-type conversions


Makefile.am:
  Don't automaticly update files from bk
client/mysqlbinlog.cc:
  Merge with 4.1 (+ apply bug fixes for --offset and --start-position)
include/my_sys.h:
  Faster clear_alloc_root()
mysql-test/r/bdb.result:
  Updated results after merge
mysql-test/r/create.result:
  Updated results after merge
mysql-test/r/func_group.result:
  Updated results after merge
mysql-test/r/func_if.result:
  Updated results after merge
mysql-test/r/heap_btree.result:
  Updated results after merge
mysql-test/r/index_merge.result:
  Updated results after merge
mysql-test/r/index_merge_ror.result:
  Updated results after merge
mysql-test/r/innodb.result:
  Updated results after merge
mysql-test/r/join_outer.result:
  Updated results after merge
mysql-test/r/mysqlbinlog2.result:
  Updated results after merge
mysql-test/r/negation_elimination.result:
  Updated results after merge
mysql-test/r/null.result:
  Updated results after merge
  Added more tests
mysql-test/r/null_key.result:
  Updated results after merge
  Added more tests
mysql-test/r/order_by.result:
  Updated results after merge
mysql-test/r/range.result:
  Updated results after merge
  Added more tests
mysql-test/r/rpl_charset.result:
  Updated results after merge
mysql-test/r/sp-error.result:
  Updated results after merge
mysql-test/r/sp.result:
  Updated results after merge
  Added delete of some stored procedures in an attempt to be able to re-run test even if it aborts in the middle
mysql-test/r/type_blob.result:
  Updated results after merge
  (Some warnings are now notes)
mysql-test/r/user_var.result:
  Updated results after merge
  Added more tests
mysql-test/r/variables.result:
  Updated results after merge
mysql-test/r/view.result:
  Updated results after merge
mysql-test/t/mysqlbinlog2.test:
  Updated tests to use new positions
mysql-test/t/null.test:
  More tests
mysql-test/t/null_key.test:
  More tests
mysql-test/t/range.test:
  More tests
mysql-test/t/rpl_charset.test:
  Avoid big diffs in the future if tests changes
mysql-test/t/sp-error.test:
  Updated error numbers
mysql-test/t/sp-security.test:
  Updated error numbers
mysql-test/t/sp.test:
  Updated results after merge
  Added delete of some stored procedures in an attempt to be able to re-run test even if it aborts in the middle
mysql-test/t/user_var.test:
  More tests
mysql-test/t/view.test:
  Updated error numbers
mysys/my_alloc.c:
  Write into debug log the address of the allocated area
sql/ha_isam.cc:
  Prefix addresses with 0x for easier comparisons of debug logs
sql/ha_myisam.cc:
  Prefix addresses with 0x for easier comparisons of debug logs
sql/ha_ndbcluster.cc:
  Add missing enum to switch
sql/handler.cc:
  remove compiler warning
sql/item.cc:
  More debugging
  Simple cleanup
sql/item.h:
  Move Item::cleanup() to item.cc
sql/item_cmpfunc.cc:
  Fix arena code
sql/item_subselect.cc:
  After merge fixes
sql/item_subselect.h:
  After merge fixes
sql/item_sum.cc:
  Updated comment
sql/log_event.cc:
  Remove wrong test
sql/mysql_priv.h:
  Indentation fixes
sql/mysqld.cc:
  After merge fixes
  Added 0x to pointers in debug log
sql/opt_range.cc:
  Fixed problem where MySQL choosed index-read even if there would be a much better range on the same index
  This fix changed some 'index' queries to 'range' queries in the test suite
sql/set_var.cc:
  Indentation fixes
sql/sp_head.cc:
  Set state to INITIALIZED to make SP work with new arena code
sql/sql_base.cc:
  After merge fixes
sql/sql_class.cc:
  More debugging
  Use clear_alloc_root() instead of init_alloc_root() as the former is faster
sql/sql_class.h:
  New method 'only_prepare()'
sql/sql_lex.cc:
  After merge fixes
sql/sql_lex.h:
  After merge fixes
sql/sql_parse.cc:
  Fix for timezone tables. (The old way to add timezone tables to global list in 'create_total_list' doesn't work anymore)
  Give NOTE instead of WARNING if table/function doesn't exists when using DROP IF EXISTS
sql/sql_prepare.cc:
  After merge fixes
sql/sql_select.cc:
  Don't create 'dummy' WHERE clause for trivial WHERE clauses where we can remove the WHERE clause.
  This fix removed of a lot of 'Using where' notes in the test suite
sql/sql_table.cc:
  Give NOTE instead of WARNING if table/function doesn't exists when using DROP IF EXISTS
sql/sql_union.cc:
  After merge fix
sql/sql_view.cc:
  After merge fix
sql/table.cc:
  After merge fix
sql/tztime.cc:
  Update timezone table handling to use new table lists structure
sql/tztime.h:
  Update timezone table handling to use new table lists structure
sql/unireg.cc:
  Use 0x before pointers
2004-09-09 06:59:26 +03:00
unknown
6c2330407f check that table used in multi-update is unique added (BUG#5455)
mysql-test/r/multi_update.result:
  multi* unique updating table check
mysql-test/t/multi_update.test:
  multi* unique updating table check
sql/sql_lex.cc:
  new method to check table only in subqueries
sql/sql_lex.h:
  new method to check table only in subqueries
sql/sql_parse.cc:
  used new method to check table only in subqueries
sql/sql_update.cc:
  check that table is unique added
2004-09-08 13:39:15 +03:00
unknown
cab6f8df6d Merge of changes from the main tree to tree for WL#1218 "Triggers".
sql/item.cc:
  Auto merged
sql/item.h:
  Auto merged
sql/item_func.cc:
  Auto merged
sql/lex.h:
  Auto merged
sql/parse_file.cc:
  Auto merged
sql/sp_head.h:
  Auto merged
sql/sql_base.cc:
  Auto merged
sql/sql_delete.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_table.cc:
  Auto merged
sql/sql_update.cc:
  Auto merged
sql/sql_yacc.yy:
  Auto merged
sql/table.h:
  Auto merged
include/mysqld_error.h:
  Manual merge.
sql/mysql_priv.h:
  Manual merge.
sql/share/czech/errmsg.txt:
  Manual merge.
sql/share/danish/errmsg.txt:
  Manual merge.
sql/share/dutch/errmsg.txt:
  Manual merge.
sql/share/english/errmsg.txt:
  Manual merge.
sql/share/estonian/errmsg.txt:
  Manual merge.
sql/share/french/errmsg.txt:
  Manual merge.
sql/share/german/errmsg.txt:
  Manual merge.
sql/share/greek/errmsg.txt:
  Manual merge.
sql/share/hungarian/errmsg.txt:
  Manual merge.
sql/share/italian/errmsg.txt:
  Manual merge.
sql/share/japanese/errmsg.txt:
  Manual merge.
sql/share/korean/errmsg.txt:
  Manual merge.
sql/share/norwegian-ny/errmsg.txt:
  Manual merge.
sql/share/norwegian/errmsg.txt:
  Manual merge.
sql/share/polish/errmsg.txt:
  Manual merge.
sql/share/portuguese/errmsg.txt:
  Manual merge.
sql/share/romanian/errmsg.txt:
  Manual merge.
sql/share/russian/errmsg.txt:
  Manual merge.
sql/share/serbian/errmsg.txt:
  Manual merge.
sql/share/slovak/errmsg.txt:
  Manual merge.
sql/share/spanish/errmsg.txt:
  Manual merge.
sql/share/swedish/errmsg.txt:
  Manual merge.
sql/share/ukrainian/errmsg.txt:
  Manual merge.
sql/sp_head.cc:
  Manual merge.
2004-09-08 13:29:21 +04:00
unknown
52ac4935e7 WL#1218 "Triggers". Some very preliminary version of patch.
Mostly needed for Monty for him getting notion what needed for triggers 
from new .FRM format. 

Things to be done:
- Right placement of trigger's invocations
- Right handling of errors in triggers (including transaction rollback)
- Support for priviliges
- Right handling of DROP/RENAME table (hope that it will be handled automatically
  with merging of .TRG into .FRM file)
- Saving/restoring some information critical for trigger creation and replication
  with their definitions (e.g. sql_mode, creator, ...)
- Replication

Already has some known bugs so probably not for general review.


include/mysqld_error.h:
  Added trigger related error codes.
sql/Makefile.am:
  Added sql_trigger.* files to list of sources from which mysqld is built.
sql/item.cc:
  Added Item_trigger_field class representing field of new/old version of row which is 
  inserted/updated/deleted and for which trigger is invoked.
sql/item.h:
  Added enums for describing trigger properties. (Here because of dependencies).
  Added Item_trigger_field class representing field of new/old version of row which is 
  inserted/updated/deleted and for which trigger is invoked.
sql/item_func.cc:
  Added Item_func_set_user_var::print_as_stmt() for printing of assignment to ser variable
  from stored procedures.
  Added comment clarifying why we don't need set no_send_ok when calling stored functions.
sql/item_func.h:
  Added Item_func_set_user_var::print_as_stmt() for printing of assignment to ser variable
  from stored procedures.
sql/lex.h:
  Symbols used in statements defining triggers were added.
sql/mysql_priv.h:
  Exported some functions needed for triggers implementation.
sql/parse_file.cc:
  Cleaned up FILE_OPTIONS_STRLIST handling (needed for triggers).
sql/parse_file.h:
  Cleaned up FILE_OPTIONS_STRLIST handling (needed for triggers).
sql/share/czech/errmsg.txt:
  Added trigger related error messages.
sql/share/danish/errmsg.txt:
  Added trigger related error messages.
sql/share/dutch/errmsg.txt:
  Added trigger related error messages.
sql/share/english/errmsg.txt:
  Added trigger related error messages.
sql/share/estonian/errmsg.txt:
  Added trigger related error messages.
sql/share/french/errmsg.txt:
  Added trigger related error messages.
sql/share/german/errmsg.txt:
  Added trigger related error messages.
sql/share/greek/errmsg.txt:
  Added trigger related error messages.
sql/share/hungarian/errmsg.txt:
  Added trigger related error messages.
sql/share/italian/errmsg.txt:
  Added trigger related error messages.
sql/share/japanese/errmsg.txt:
  Added trigger related error messages.
sql/share/korean/errmsg.txt:
  Added trigger related error messages.
sql/share/norwegian-ny/errmsg.txt:
  Added trigger related error messages.
sql/share/norwegian/errmsg.txt:
  Added trigger related error messages.
sql/share/polish/errmsg.txt:
  Added trigger related error messages.
sql/share/portuguese/errmsg.txt:
  Added trigger related error messages.
sql/share/romanian/errmsg.txt:
  Added trigger related error messages.
sql/share/russian/errmsg.txt:
  Added trigger related error messages.
sql/share/serbian/errmsg.txt:
  Added trigger related error messages.
sql/share/slovak/errmsg.txt:
  Added trigger related error messages.
sql/share/spanish/errmsg.txt:
  Added trigger related error messages.
sql/share/swedish/errmsg.txt:
  Added trigger related error messages.
sql/share/ukrainian/errmsg.txt:
  Added trigger related error messages.
sql/sp_head.cc:
  sp_head::init_strings(): added support for triggers 
    (we don't have most of strings for them)
  sp_head::execute_function(): triggers don't require RETURN
  sp_head::reset_lex(): added propagation of trigger properties to LEX used for 
   parsing of statements composing trigger body.
  Added two more SP instructions:
  - sp_instr_set_user_var for setting user variables in stored functions and triggers
    (we can't use sp_instr_stmt and "SET @a:=..." statement since it will close open 
    tables and thus break execution of calling statement.
  - sp_instr_set_trigger_field for assignment to fields of row being updated/inserted in
    triggers
sql/sp_head.h:
  Added new type of sp_head object - TYPE_ENUM_TRIGGER
  Added two more SP instructions:
  - sp_instr_set_user_var for setting user variables in stored functions and triggers
    (we can't use sp_instr_stmt and "SET @a:=..." statement since it will close open 
    tables and thus break execution of calling statement.
  - sp_instr_set_trigger_field for assignment to fields of row being updated/inserted in
    triggers
sql/sql_base.cc:
  Now freeing memory occupied by trigger related structures when closing tables.
  open_unireg_entry(): added loading of triggers for table.
  find_field_in_real_table() is now public since it required by Item_trigger_field in item.cc
sql/sql_delete.cc:
  Added triggers invocation for DELETE (should be fixed for sure :))
sql/sql_insert.cc:
  Added triggers invocation for INSERT (should be fixed for sure :))
sql/sql_lex.cc:
  Added trg_new_row_fake_var variable pointer to which is used for distinguishing between
  assignment to NEW row field (when parsing trigger definition) and structured variable.
  Added initialization of LEX->trg_table to lex_start(). (When triggers are parsed during
  opening of table it points to table object.)
sql/sql_lex.h:
  Added trigger related commands.
  Added st_trg_chistics structure describing properties of trigger being created
  (as struct and as LEX member).
  Added trg_new_row_fake_var variable pointer to which is used for
  distinguishing between assignment to NEW row field (when parsing trigger definition)
  and structured variable.
  Added LEX::trg_table which points to table being opened when we are parsing trigger
  definition while opening table.
sql/sql_parse.cc:
  Added support for CREATE/DROP TRIGGER commands.
sql/sql_table.cc:
  Cleanup. close_cached_table() always returns 0 and its result is not analyzed in most
  places so chenged its return type to void.
sql/sql_update.cc:
  Added triggers invocation for UPDATE (should be fixed for sure :))
sql/sql_yacc.yy:
  Added support for CREATE/DROP TRIGGER statements.
  Added support for OLD/NEW row identifiers in trigger.
  Made assignment to user variables not to break execution of stored function or trigger.
sql/table.h:
  Added TABLE::triggers member representing triggers for this table.
2004-09-07 16:29:46 +04:00
unknown
4ad51359c1 Merge with 4.1
(Includes merge of arena code in 4.1 and 5.0)



BitKeeper/etc/ignore:
  auto-union
BitKeeper/etc/logging_ok:
  auto-union
VC++Files/sql/mysqld.dsp:
  Auto merged
client/mysql.cc:
  Auto merged
client/mysqltest.c:
  Auto merged
include/my_global.h:
  Auto merged
include/my_sys.h:
  Auto merged
include/mysql.h:
  Auto merged
include/mysql_com.h:
  Auto merged
innobase/row/row0sel.c:
  Auto merged
libmysql/client_settings.h:
  Auto merged
libmysql/libmysql.c:
  Auto merged
libmysqld/Makefile.am:
  Auto merged
libmysqld/examples/Makefile.am:
  Auto merged
libmysqld/lib_sql.cc:
  Auto merged
myisam/mi_check.c:
  Auto merged
myisam/myisamchk.c:
  Auto merged
myisam/sort.c:
  Auto merged
mysql-test/r/connect.result:
  Auto merged
mysql-test/r/ctype_recoding.result:
  Auto merged
mysql-test/r/ctype_ucs.result:
  Auto merged
mysql-test/r/func_in.result:
  Auto merged
mysql-test/r/func_like.result:
  Auto merged
mysql-test/r/gis.result:
  Auto merged
mysql-test/r/having.result:
  Auto merged
mysql-test/r/heap.result:
  Auto merged
mysql-test/r/join.result:
  Auto merged
mysql-test/r/key.result:
  Auto merged
mysql-test/r/lowercase_table.result:
  Auto merged
mysql-test/r/ndb_autodiscover.result:
  Auto merged
mysql-test/r/null.result:
  Auto merged
mysql-test/r/olap.result:
  Auto merged
mysql-test/r/order_by.result:
  Auto merged
mysql-test/r/ps_1general.result:
  Auto merged
mysql-test/r/ps_2myisam.result:
  Auto merged
mysql-test/r/ps_3innodb.result:
  Auto merged
mysql-test/r/ps_4heap.result:
  Auto merged
mysql-test/r/ps_5merge.result:
  Auto merged
mysql-test/r/ps_6bdb.result:
  Auto merged
mysql-test/r/range.result:
  Auto merged
mysql-test/r/rename.result:
  Auto merged
mysql-test/r/show_check.result:
  Auto merged
mysql-test/r/subselect.result:
  Auto merged
mysql-test/r/union.result:
  Auto merged
mysql-test/r/variables.result:
  Auto merged
mysql-test/t/alter_table.test:
  Auto merged
mysql-test/t/null.test:
  Auto merged
mysql-test/t/ps_1general.test:
  Auto merged
mysql-test/t/rpl_charset.test:
  Auto merged
mysql-test/t/rpl_heap.test:
  Auto merged
mysql-test/t/rpl_relayrotate.test:
  Auto merged
mysql-test/t/subselect.test:
  Auto merged
mysql-test/t/variables.test:
  Auto merged
netware/mysql_test_run.c:
  Auto merged
scripts/make_binary_distribution.sh:
  Auto merged
scripts/mysql_create_system_tables.sh:
  Auto merged
scripts/mysql_fix_privilege_tables.sql:
  Auto merged
scripts/mysql_install_db.sh:
  Auto merged
sql/ha_berkeley.cc:
  Auto merged
sql/ha_innodb.cc:
  Auto merged
sql/ha_innodb.h:
  Auto merged
sql/ha_myisam.cc:
  Auto merged
sql/handler.cc:
  Auto merged
sql/handler.h:
  Auto merged
sql/item.h:
  Auto merged
sql/item_cmpfunc.h:
  Auto merged
sql/item_create.cc:
  Auto merged
sql/item_create.h:
  Auto merged
sql/item_func.cc:
  Auto merged
sql/item_func.h:
  Auto merged
sql/item_timefunc.cc:
  Auto merged
sql/item_timefunc.h:
  Auto merged
sql/lex.h:
  Auto merged
sql/lock.cc:
  Auto merged
sql/log_event.cc:
  Auto merged
sql/mysql_priv.h:
  Auto merged
sql/opt_sum.cc:
  Auto merged
sql/protocol.cc:
  Auto merged
sql/records.cc:
  Auto merged
sql/repl_failsafe.cc:
  Auto merged
sql/set_var.cc:
  Auto merged
sql/set_var.h:
  Auto merged
sql/slave.cc:
  Auto merged
sql/sql_acl.cc:
  Auto merged
sql/sql_acl.h:
  Auto merged
sql/sql_db.cc:
  Auto merged
sql/sql_delete.cc:
  Auto merged
sql/sql_insert.cc:
  Auto merged
sql/sql_list.h:
  Auto merged
sql/sql_load.cc:
  Auto merged
sql/sql_rename.cc:
  Auto merged
sql/sql_select.h:
  Auto merged
sql/sql_show.cc:
  Auto merged
sql/sql_string.h:
  Auto merged
sql/table.cc:
  Auto merged
sql-common/client.c:
  Auto merged
client/mysqlbinlog.cc:
  Merge with 4.1
configure.in:
  Merge with 4.1
include/mysqld_error.h:
  Add new error message (1) from 4.1
mysql-test/mysql-test-run.sh:
  Merge with 4.1
mysql-test/r/func_gconcat.result:
  Merge with 4.1
mysql-test/r/func_if.result:
  Merge with 4.1
mysql-test/r/grant.result:
  Merge with 4.1
mysql-test/r/join_outer.result:
  Merge with 4.1
mysql-test/r/rpl_charset.result:
  Merge with 4.1 (This has to be fixed before pushing)
mysql-test/r/system_mysql_db.result:
  Merge with 4.1.
  Added collation to new privileges
mysql-test/t/grant.test:
  Merge with 4.1
mysql-test/t/grant_cache.test:
  Merge with 4.1
mysql-test/t/show_check.test:
  Merge with 4.1
sql/Makefile.am:
  Merge with 4.1
sql/item.cc:
  Merge with 4.1
sql/item_cmpfunc.cc:
  Merge with 4.1 (arena code)
sql/item_subselect.cc:
  Merge with 4.1
sql/item_subselect.h:
  Merge with 4.1
sql/item_sum.cc:
  Merge with 4.1
sql/item_sum.h:
  Merge with 4.1
sql/log.cc:
  Merge with 4.1 (Remove code that is not relevant for 5.0)
sql/mysqld.cc:
  Merge with 4.1
sql/opt_range.cc:
  Merge with 4.1
sql/share/czech/errmsg.txt:
  Merge with 4.1
sql/share/danish/errmsg.txt:
  Merge with 4.1
sql/share/dutch/errmsg.txt:
  Merge with 4.1
sql/share/english/errmsg.txt:
  Merge with 4.1
sql/share/estonian/errmsg.txt:
  Merge with 4.1
sql/share/french/errmsg.txt:
  Merge with 4.1
sql/share/german/errmsg.txt:
  Merge with 4.1
sql/share/greek/errmsg.txt:
  Merge with 4.1
sql/share/hungarian/errmsg.txt:
  Merge with 4.1
sql/share/italian/errmsg.txt:
  Merge with 4.1
sql/share/japanese/errmsg.txt:
  Merge with 4.1
sql/share/korean/errmsg.txt:
  Merge with 4.1
sql/share/norwegian-ny/errmsg.txt:
  Merge with 4.1
sql/share/norwegian/errmsg.txt:
  Merge with 4.1
sql/share/polish/errmsg.txt:
  Merge with 4.1
sql/share/portuguese/errmsg.txt:
  Merge with 4.1
sql/share/romanian/errmsg.txt:
  Merge with 4.1
sql/share/russian/errmsg.txt:
  Merge with 4.1
sql/share/serbian/errmsg.txt:
  Merge with 4.1
sql/share/slovak/errmsg.txt:
  Merge with 4.1
sql/share/spanish/errmsg.txt:
  Merge with 4.1
sql/share/swedish/errmsg.txt:
  Merge with 4.1
sql/share/ukrainian/errmsg.txt:
  Merge with 4.1
sql/sql_base.cc:
  Merge with 4.1
sql/sql_class.cc:
  Merge with 4.1
  Use arena code from 4.1
sql/sql_class.h:
  Merge with 4.1
  Use arena code from 4.1
sql/sql_derived.cc:
  Merge with 4.1
sql/sql_lex.cc:
  Merge with 4.1
sql/sql_lex.h:
  Merge with 4.1
sql/sql_parse.cc:
  Merge with 4.1
sql/sql_prepare.cc:
  Merge with 4.1
sql/sql_select.cc:
  Merge with 4.1
sql/sql_table.cc:
  Merge with 4.1
sql/sql_union.cc:
  Merge with 4.1
sql/sql_yacc.yy:
  Merge with 4.1
sql/tztime.cc:
  Merge with 4.1
tests/client_test.c:
  Merge with 4.1
2004-09-06 15:14:10 +03:00
unknown
d75ea9bcd6 Merge sanja.is.com.ua:/home/bell/mysql/bk/mysql-5.0
into sanja.is.com.ua:/home/bell/mysql/bk/work-5.0


mysql-test/r/view.result:
  Auto merged
sql/item.cc:
  Auto merged
sql/item.h:
  Auto merged
sql/sp_head.cc:
  Auto merged
sql/sql_base.cc:
  Auto merged
sql/sql_delete.cc:
  Auto merged
sql/sql_lex.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_update.cc:
  Auto merged
sql/sql_view.cc:
  Auto merged
sql/table.h:
  Auto merged
2004-09-04 15:32:13 +03:00
unknown
99be6d3060 Merge with pulled code
mysql-test/r/view.result:
  Auto merged
sql/item_subselect.cc:
  Auto merged
sql/item_subselect.h:
  Auto merged
sql/mysql_priv.h:
  Auto merged
sql/sql_acl.cc:
  Auto merged
sql/sql_lex.cc:
  Auto merged
sql/sql_parse.cc:
  Auto merged
sql/sql_prepare.cc:
  Auto merged
sql/sql_show.cc:
  Auto merged
sql/sql_update.cc:
  Auto merged
sql/table.h:
  Auto merged
tests/client_test.c:
  Auto merged
sql/sql_base.cc:
  Merge
sql/sql_insert.cc:
  Merge
sql/sql_select.cc:
  Merge
sql/sql_view.cc:
  Merge
sql/table.cc:
  Merge
2004-09-03 22:38:45 +03:00
unknown
d0211cf5be Cleanup of new code pushed into 5.0 since last pull
Merged the different find_xxxx_table_in_list functions to one + some inline functions


mysql-test/r/view.result:
  Fix result (remove not used view from show tables)
sql/item_subselect.cc:
  Remove not used functions
sql/item_subselect.h:
  Remove not used functions
sql/mysql_priv.h:
  Merged the different find_xxxx_table_in_list functions to one + some inline functions
sql/sql_acl.cc:
  More debugging + simple cleanups
sql/sql_base.cc:
  Merged the different find_xxxx_table_in_list functions to one + some inline functions
  Indentation cleanups & more comments
sql/sql_delete.cc:
  Namechange
sql/sql_insert.cc:
  Simple optimizations & Style cleanups
  Merged common code (in mysql_prepare_insert_check_table)
sql/sql_lex.cc:
  function name changes
  More comments
sql/sql_parse.cc:
  Function name changes
  Made check_one_table_access returning bool
  More debugging in 'check_access'
  Added function 'check_some_access', which is used when creating a view
sql/sql_prepare.cc:
  Resetting flag directly after test makes code easier to read
sql/sql_select.cc:
  Code simplifications
sql/sql_show.cc:
  Indentation cleanups.
  Fixed typo in name
sql/sql_update.cc:
  Function name change
sql/sql_view.cc:
  Simple optimizations.
  Style fixes.
  Remove view_field_names[]
  Simplified 'check_key_in_view()'
sql/table.cc:
  Simplified new code in openfrm()
  variable name change i -> item
  Indentation changes
sql/table.h:
  Fixed typo in variable name
  Method name change in field iterator: end() -> end_of_fields()
tests/client_test.c:
  Changed number to macro
2004-09-03 21:43:04 +03:00
unknown
d3423ca699 ORDER clause printing fixed (BUG#5156)
mysql-test/r/subselect.result:
  ORDER clause printing fixed
mysql-test/r/view.result:
  order by refers on integer field
mysql-test/t/view.test:
  order by refers on integer field
sql/sql_lex.cc:
  ORDER clause printing fixed
sql/sql_parse.cc:
  fields for correct ORDER printing added
sql/sql_select.cc:
  fields for correct ORDER printing added
sql/table.h:
  fields for correct ORDER printing added
2004-08-31 11:58:45 +03:00
unknown
3b8c2da84e fixed updateability VIEW detection (Bug#5146)
fixed other Item_ref methods where result_field involved


mysql-test/r/view.result:
  statements added to distinct in temporary table with a VIEW test
  test of agggregate over aggregate with view
mysql-test/t/view.test:
  statements added to distinct in temporary table with a VIEW test
  test of agggregate over aggregate with view
sql/item.cc:
  fixed other Item_ref methods where result_field involved
sql/item.h:
  fixed other Item_ref methods where result_field involved
sql/sql_lex.cc:
  fixed updateability VIEW detection
2004-08-26 14:34:56 +03:00
unknown
b8785595b9 new method to detect commands where all VIEWs should be temporary tables (BUG#4803)
mysql-test/r/view.result:
  Showing VIEW with VIEWs in subquery
mysql-test/t/view.test:
  Showing VIEW with VIEWs in subquery
sql/sql_lex.cc:
  new method to detect commands where all VIEWs should be temporary tables
sql/sql_lex.h:
  new method to detect commands where all VIEWs should be temporary tables
sql/sql_view.cc:
  new method to detect commands where all VIEWs should be temporary tables
  debug output added
2004-08-24 22:51:23 +03:00
unknown
205cf8044b Merge: manual resolve
sql/sql_class.h:
  Auto merged
sql/sql_lex.cc:
  Auto merged
sql/sql_lex.h:
  Auto merged
sql/sql_prepare.cc:
  Auto merged
sql/sql_select.cc:
  Auto merged
sql/sql_class.cc:
  Manual resolve of the merge
2004-08-24 23:07:08 +04:00
unknown
49bd559eb8 Fix for Bug#5034 "prepared "select 1 into @arg15", second
execute crashes server": we were deleting lex->result
after each execute, but prepared statements assumed that
it's left intact.
The fix adds cleanup() method to select_result hierarchy,
so that result objects can be reused.
Plus we now need to delete result objects more wisely.


mysql-test/r/ps.result:
  Test results fixed: test case for bug#5034
mysql-test/t/ps.test:
  A test case for bug#5034, few followups
sql/sql_class.cc:
  - fix warning in THD::THD
  - implementation of cleanup() for select_result hierarchy
  - select_export::send_eof was identical to 
    select_dump::send_eof: moved to the base class select_to_file.
  - Statement::end_statement() to end lex, free items, and
    delete possible select_result
sql/sql_class.h:
  - select_result::cleanup() declaration
  -
sql/sql_insert.cc:
  - implementation of select_insert::cleanup(): currently
    we always create a new instance of select_insert/
    select_create on each execute.
sql/sql_lex.cc:
  - with more complicated logic of freeing lex->result it's 
    easier to have it non-zero only if it points to a valid
    result.
sql/sql_lex.h:
  Now st_lex::st_lex is not empty.
sql/sql_parse.cc:
  mysql_execute_command():
  - delete select_result *result only if it was created in
    this function.
  - use end_statement() to cleanup lex and thd in the end of
    each statement.
  - no need to save THD::lock if this is explain. This save
    apparently left from times when derived tables were 
    materialized here, not in open_and_lock_tables.
sql/sql_prepare.cc:
  - call result->cleanup() in reset_stmt_for_execute
  - now Statement is responsible for freeing its lex->result.
sql/sql_select.cc:
  handle_select():
  - don't delete result, it might be needed
    for next executions
  - result is never null
2004-08-24 20:17:11 +04:00
unknown
e275e347e3 merge
sql/item_subselect.cc:
  Auto merged
sql/item_subselect.h:
  Auto merged
sql/mysql_priv.h:
  Auto merged
sql/sql_lex.cc:
  Auto merged
sql/sql_yacc.yy:
  Auto merged
2004-08-23 15:50:59 +03:00
unknown
248d7108c9 fixed LIMIT clause printing (BUG#4839)
mysql-test/r/view.result:
  EXISTS with UNION VIEW creation test
mysql-test/t/view.test:
  EXISTS with UNION VIEW creation test
sql/sql_lex.cc:
  fixed LIMIT clause printing
2004-08-23 13:19:59 +03:00
unknown
095b686c09 Fix for bug#4912 "mysqld crashs in case a statement is executed
a second time". The bug was caused by incompatibility of
negations elimination algorithm and PS: during first statement 
execute a subtree with negation was replaced with equivalent 
subtree without NOTs.
The problem was that although this transformation was permanent, 
items of the new subtree were created in execute-local memory.
The patch adds means to check if it is the first execute of a
prepared statement, and if this is the case, to allocate items
in memory of the prepared statement.
The implementation:
- backports Item_arena from 5.0
- adds Item_arena::is_stmt_prepare(), 
  Item_arena::is_first_stmt_execute().
- deletes THD::allocate_temporary_pool_for_ps_preparing(),
  THD::free_temporary_pool_for_ps_preparing(); they
  were redundant.
and adds a few invariants:
- thd->free_list never contains junk (= freed items)
- thd->current_arena is never null. If there is no
  prepared statement, it points at the thd. 
The rest of the patch contains mainly mechanical changes and
cleanups.


mysql-test/r/ps.result:
  Test results updated (test case for Bug#4912)
mysql-test/t/ps.test:
  A test case for Bug#4912 "mysqld crashs in case a statement is 
  executed a second time"
sql/item_cmpfunc.cc:
  current_statement -> current_arena
sql/item_subselect.cc:
  Statement -> Item_arena, current_statement -> current_arena
sql/item_subselect.h:
  Item_subselect does not need to save thd->current_statement.
sql/item_sum.cc:
  Statement -> Item_arena
sql/item_sum.h:
  Statement -> Item_arena
sql/mysql_priv.h:
  Statement -> Item_arena
sql/sql_base.cc:
  current_statement -> current_arena
sql/sql_class.cc:
  - Item_arena
  - convenient set_n_backup_statement, restore_backup_statement
  (nice idea, Sanja)
sql/sql_class.h:
  - Item_arena: backport from 5.0
  - allocate_temporary_pool_for_ps_preparing,
    free_temporary_pool_for_ps_preparing removed.
sql/sql_derived.cc:
  current_statement -> current_arena
sql/sql_lex.cc:
  current_statement -> current_arena
sql/sql_parse.cc:
  Deploy invariant that thd->free_list never contains junk items
  (backport from 5.0).
sql/sql_prepare.cc:
  - backporting Item_arena
  - no need to allocate_temporary_pool_for_ps_preparing().
sql/sql_select.cc:
  Fix for bug#4912 "mysqld crashs in case a statement is 
  executed a second time": if this is the first execute of
  a prepared statement, negation elimination is
  done in memory of the prepared statement.
sql/sql_union.cc:
  Backporting Item_arena from 5.0.
2004-08-21 02:02:46 +04:00
unknown
d0c87702f7 skip resolving field in table list if table list is not accessable due to groupping (BUG#4814)
mysql-test/r/func_gconcat.result:
  fix of test queries
mysql-test/r/subselect.result:
  resolving fields of grouped outer SELECT
mysql-test/t/func_gconcat.test:
  fix of test queries
mysql-test/t/subselect.test:
  resolving fields of grouped outer SELECT
sql/item.cc:
  skip resolving field in table list if table list is not accessable due to groupping
  layout fixed
sql/item_subselect.cc:
  detection of place of subquery
sql/item_subselect.h:
  detection of place of subquery
sql/mysql_priv.h:
  enum_parsing_place made global type
sql/sql_lex.cc:
  enum_parsing_place made global type
sql/sql_lex.h:
  enum_parsing_place made global type
sql/sql_yacc.yy:
  enum_parsing_place made global type
2004-08-13 10:01:30 +03:00
unknown
68d7b26698 Fix for bug #4508 "CONVERT_TZ() function with new time zone as param crashes server".
Instead of trying to open time zone tables during calculation of CONVERT_TZ() function
or setting of @@time_zone variable we should open and lock them with the rest of 
statement's table (so we should add them to global table list) and after that use such 
pre-opened tables for loading info about time zones.


mysql-test/r/timezone2.result:
  Added test for bug #4508
mysql-test/t/timezone2.test:
  Added test for bug #4508
scripts/mysql_create_system_tables.sh:
  Added one more test time zone to time zone tables which is needed for test for bug #4508.
sql/item_create.cc:
  CONVERT_TZ() now is treated as special function.
sql/item_create.h:
  CONVERT_TZ() now is treated as special function.
sql/item_timefunc.cc:
  Item_func_convert_tz now uses list of pre-opened time zone tables instead of trying to
  open them ad-hoc. Also it avoid calling of current_thd.
sql/item_timefunc.h:
  Added comment describing special nature of CONVERT_TZ() function.
  Optimization: Added own fix_fields() method and tz_tables member for caching pointer
  to list of open time zone tables to Item_func_convert_tz class.
sql/lex.h:
  CONVERT_TZ() now is treated as special function.
sql/mysql_priv.h:
  Removed function which is no longer used.
sql/set_var.cc:
  Now my_tz_find() accepts list of pre-opened time zone tables as last argument 
  and no longer needs pointer to current THD.
sql/set_var.h:
  Exported sys_time_zone, which is now used in sql_yacc.yy for quick finding out if we are
  setting @@time_zone variable.
sql/sql_base.cc:
  Moved propagation of pointers to open tables from global list to local select lists to
  open_and_lock_tables(), also added implicit usage of time zone tables as condition for
  such propagation.
sql/sql_lex.cc:
  Added fake_time_zone_tables_list which is used to indicate that time zone tables are
  implicitly used in statement.
  st_select_lex_unit::create_total_list(): if time zone tables are implicitly used in
  statement add them to global tables list.
sql/sql_lex.h:
  Added LEX::time_zone_tables_used member which is used to indicate that time zone tables 
  are implicitly used in this statement (by pointing to fake_time_zone_table_list) and 
  for holding pointer to those tables after they've been opened.
sql/sql_parse.cc:
  We should also create global table list if statement uses time zone tables implicitly.
  Added initialization of LEX::time_zone_tables_used to mysql_query_init().
sql/sql_prepare.cc:
  We should also create global table list if statement uses time zone tables implicitly.
sql/sql_select.cc:
  Removed functions which are no longer used.
sql/sql_yacc.yy:
  CONVERT_TZ() and @@time_zone variable are handled in special way since they implicitly 
  use time zone tables.
sql/tztime.cc:
  Fix for bug #4508 "CONVERT_TZ() function with new time zone as param crashes server".
  If statement uses CONVERT_TZ() function or @@time_zone variable is set then it implicitly
  uses time zone tables. We need to open and lock such tables with all other tables of 
  such statement.
  
  All code responsible for opening table was removed from tz_load_from_db() and function was 
  renamed to tz_load_from_open_tables() (which uses list of pre-opened tables).
  We also have new functions for construction and initialization of table list of time
  zone tables.
  my_tz_find() now always require list of pre-opened time zone tables and no longer needs
  current THD. So we have to pre-open them in my_tz_init().
  Also now we try to open time zone tables only if they were found during startup.
sql/tztime.h:
  New function for construction of table list of time zone tables my_tz_get_table_list().
  Now my_tz_find() requires list of pre-pened time zone tables instead of current thread.
2004-08-10 12:42:31 +04:00
unknown
1b98202be7 fixed using VIEW fields (BUG#4617)
mysql-test/r/view.result:
  using VIEW fields several times in query resolved via temporary tables
mysql-test/t/view.test:
  using VIEW fields several times in query resolved via temporary tables
sql/item.h:
  fixed using of result_field by Item_ref
sql/sql_base.cc:
  Create Item_ref as reference on VIEW fields expression reference
sql/sql_insert.cc:
  privent creating Item_ref in insert list (where Item_fields should be)
sql/sql_lex.cc:
  Item_ref creation control
sql/sql_lex.h:
  Item_ref creation control
sql/sql_update.cc:
  privent creating Item_ref in insert list (where Item_fields should be) and creation Item_fields for UPDATE list
sql/table.cc:
  Do not create Item_ref for internal view of view processing
2004-07-23 09:20:58 +03:00
unknown
1d29e6b0d4 after merge fixes
sql/opt_range.h:
  compatibility fix
sql/sql_lex.cc:
  cleanup
2004-07-22 00:26:33 +02:00
unknown
a9856042bc merged
mysql-test/r/ps_1general.result:
  Auto merged
mysql-test/r/ps_2myisam.result:
  Auto merged
mysql-test/r/ps_3innodb.result:
  Auto merged
mysql-test/r/ps_4heap.result:
  Auto merged
mysql-test/r/ps_5merge.result:
  Auto merged
mysql-test/r/ps_6bdb.result:
  Auto merged
sql/sql_prepare.cc:
  Auto merged
sql/sql_select.cc:
  Auto merged
2004-07-21 23:32:11 +02:00
unknown
ff4aa03dc5 LEX initialization fixed 2004-07-21 22:44:12 +03: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
a96bb92f4a Merge
sql/mysql_priv.h:
  Auto merged
sql/mysqld.cc:
  Auto merged
sql/sql_lex.cc:
  Auto merged
sql/sql_lex.h:
  Auto merged
sql/sql_select.cc:
  Auto merged
sql/table.h:
  Auto merged
2004-07-15 04:28:42 +03:00
unknown
a772701340 patch for task WL 1941 "NO_C_ESCAPE sql_mode"
mysql-test/r/sql_mode.result:
  added test for WL 1941 "NO_C_ESCAPE sql_mode"
mysql-test/t/sql_mode.test:
  added test for WL 1941 "NO_C_ESCAPE sql_mode"
sql/mysql_priv.h:
  added MODE_NO_BACKSLASH_ESCAPES
sql/mysqld.cc:
  added mode NO_BACKSLASH_ESCAPES
sql/sql_lex.cc:
  added test for MODE_NO_BACKSLASH_ESCAPES when testing escaped character
sql/sql_yacc.yy:
  added using of "" as escape by default
   in LIKE function if MODE_NO_BACKSLASH_ESCAPES
2004-07-07 17:26:43 +05:00
unknown
11b8987313 Merge with 4.1.3-beta
BitKeeper/etc/ignore:
  auto-union
BitKeeper/etc/logging_ok:
  auto-union
VC++Files/libmysqld/libmysqld.dsp:
  Auto merged
VC++Files/sql/mysqld.dsp:
  Auto merged
client/mysql.cc:
  Auto merged
client/mysqlbinlog.cc:
  Auto merged
client/mysqltest.c:
  Auto merged
include/config-netware.h:
  Auto merged
include/my_base.h:
  Auto merged
include/my_global.h:
  Auto merged
include/my_sys.h:
  Auto merged
include/mysql_com.h:
  Auto merged
include/sql_state.h:
  Auto merged
innobase/include/row0mysql.h:
  Auto merged
innobase/row/row0sel.c:
  Auto merged
libmysql/libmysql.c:
  Auto merged
libmysqld/lib_sql.cc:
  Auto merged
myisam/mi_check.c:
  Auto merged
mysql-test/r/bdb.result:
  Auto merged
mysql-test/r/connect.result:
  Auto merged
mysql-test/r/ctype_ucs.result:
  Auto merged
mysql-test/r/derived.result:
  Auto merged
mysql-test/r/func_group.result:
  Auto merged
mysql-test/r/func_like.result:
  Auto merged
mysql-test/r/func_sapdb.result:
  Auto merged
mysql-test/r/func_time.result:
  Auto merged
mysql-test/r/insert.result:
  Auto merged
mysql-test/r/insert_select.result:
  Auto merged
mysql-test/r/join_outer.result:
  Auto merged
mysql-test/r/key.result:
  Auto merged
mysql-test/r/multi_update.result:
  Auto merged
mysql-test/r/mysqldump.result:
  Auto merged
mysql-test/r/null.result:
  Auto merged
mysql-test/r/null_key.result:
  Auto merged
mysql-test/r/query_cache.result:
  Auto merged
mysql-test/r/rpl_rotate_logs.result:
  Auto merged
mysql-test/r/rpl_server_id1.result:
  Auto merged
mysql-test/r/rpl_until.result:
  Auto merged
mysql-test/r/select.result:
  Auto merged
mysql-test/r/show_check.result:
  Auto merged
mysql-test/r/subselect.result:
  Auto merged
mysql-test/r/system_mysql_db.result:
  Auto merged
mysql-test/r/union.result:
  Auto merged
mysql-test/r/variables.result:
  Auto merged
mysql-test/t/multi_update.test:
  Auto merged
mysql-test/t/mysqlbinlog.test:
  Auto merged
mysql-test/t/rpl000015.test:
  Auto merged
mysql-test/t/subselect.test:
  Auto merged
mysql-test/t/variables.test:
  Auto merged
mysys/mf_iocache2.c:
  Auto merged
mysys/my_bitmap.c:
  Auto merged
mysys/my_pthread.c:
  Auto merged
netware/Makefile.am:
  Auto merged
netware/my_manage.c:
  Auto merged
netware/mysql_test_run.c:
  Auto merged
netware/BUILD/compile-linux-tools:
  Auto merged
netware/BUILD/compile-netware-standard:
  Auto merged
netware/BUILD/mwenv:
  Auto merged
netware/BUILD/nwbootstrap:
  Auto merged
scripts/make_binary_distribution.sh:
  Auto merged
scripts/mysql_install_db.sh:
  Auto merged
sql/ha_berkeley.cc:
  Auto merged
sql/ha_berkeley.h:
  Auto merged
sql/ha_heap.h:
  Auto merged
sql/item.cc:
  Auto merged
sql/item.h:
  Auto merged
sql/item_cmpfunc.cc:
  Auto merged
sql/item_cmpfunc.h:
  Auto merged
sql/item_create.cc:
  Auto merged
sql/item_create.h:
  Auto merged
sql/item_func.h:
  Auto merged
sql/item_subselect.cc:
  Auto merged
sql/item_sum.cc:
  Auto merged
sql/item_sum.h:
  Auto merged
sql/item_timefunc.h:
  Auto merged
sql/lex.h:
  Auto merged
sql/mysql_priv.h:
  Auto merged
sql/net_serv.cc:
  Auto merged
sql/protocol.cc:
  Auto merged
sql/protocol.h:
  Auto merged
sql/records.cc:
  Auto merged
sql/repl_failsafe.cc:
  Auto merged
sql/set_var.cc:
  Auto merged
sql/sql_acl.cc:
  Auto merged
sql/sql_acl.h:
  Auto merged
sql/sql_base.cc:
  Auto merged
sql/sql_cache.cc:
  Auto merged
sql/sql_delete.cc:
  Auto merged
sql/sql_derived.cc:
  Auto merged
sql/sql_load.cc:
  Auto merged
sql/sql_show.cc:
  Auto merged
sql/sql_string.cc:
  Auto merged
sql/sql_update.cc:
  Auto merged
sql/structs.h:
  Auto merged
sql-common/client.c:
  Auto merged
configure.in:
  Merge with 4.1
include/mysqld_error.h:
  New errors from 4.1
libmysqld/Makefile.am:
  Merge with 4.1
myisam/myisamchk.c:
  Merge with 4.1
myisam/myisamdef.h:
  Merge with 4.1
myisam/sort.c:
  Merge with 4.1
mysql-test/r/mysqlbinlog.result:
  Merge with 4.1
mysql-test/r/range.result:
  Merge with 4.1
mysql-test/r/rpl_flush_log_loop.result:
  Merge with 4.1
mysql-test/r/rpl_replicate_do.result:
  Merge with 4.1
mysql-test/r/rpl_temporary.result:
  Merge with 4.1
mysql-test/r/rpl_user_variables.result:
  Merge with 4.1
mysql-test/t/func_time.test:
  Merge with 4.1
scripts/mysql_create_system_tables.sh:
  Merge with 4.1
scripts/mysql_fix_privilege_tables.sql:
  Merge with 4.1
sql/Makefile.am:
  Merge with 4.1
sql/filesort.cc:
  Merge with 4.1
sql/ha_innodb.cc:
  Merge with 4.1
sql/ha_innodb.h:
  Merge with 4.1
sql/ha_myisam.cc:
  Merge with 4.1
sql/handler.cc:
  Merge with 4.1
sql/handler.h:
  Merge with 4.1
sql/item_func.cc:
  Merge with 4.1
sql/item_timefunc.cc:
  Merge with 4.1
sql/log.cc:
  Merge with 4.1
sql/log_event.cc:
  Merge with 4.1
sql/mysqld.cc:
  Merge with 4.1
sql/opt_range.cc:
  Merge with 4.1
sql/opt_range.h:
  Merge with 4.1
sql/share/czech/errmsg.txt:
  Merge with 4.1
  Updated english error messages
sql/share/danish/errmsg.txt:
  Merge with 4.1
sql/share/dutch/errmsg.txt:
  Merge with 4.1
sql/share/english/errmsg.txt:
  Merge with 4.1
sql/share/estonian/errmsg.txt:
  Merge with 4.1
sql/share/french/errmsg.txt:
  Merge with 4.1
sql/share/german/errmsg.txt:
  Merge with 4.1
sql/share/greek/errmsg.txt:
  Merge with 4.1
sql/share/hungarian/errmsg.txt:
  Merge with 4.1
sql/share/italian/errmsg.txt:
  Merge with 4.1
sql/share/japanese/errmsg.txt:
  Merge with 4.1
sql/share/korean/errmsg.txt:
  Merge with 4.1
sql/share/norwegian-ny/errmsg.txt:
  Merge with 4.1
sql/share/norwegian/errmsg.txt:
  Merge with 4.1
sql/share/polish/errmsg.txt:
  Merge with 4.1
sql/share/portuguese/errmsg.txt:
  Merge with 4.1
sql/share/romanian/errmsg.txt:
  Merge with 4.1
sql/share/russian/errmsg.txt:
  Merge with 4.1
sql/share/serbian/errmsg.txt:
  Merge with 4.1
sql/share/slovak/errmsg.txt:
  Merge with 4.1
sql/share/spanish/errmsg.txt:
  Merge with 4.1
sql/share/swedish/errmsg.txt:
  Merge with 4.1
sql/share/ukrainian/errmsg.txt:
  Merge with 4.1
sql/slave.cc:
  Merge with 4.1
sql/sql_class.cc:
  Merge with 4.1
sql/sql_class.h:
  Merge with 4.1
sql/sql_db.cc:
  Merge with 4.1
sql/sql_insert.cc:
  Merge with 4.1
sql/sql_lex.cc:
  Merge with 4.1
sql/sql_lex.h:
  Merge with 4.1
sql/sql_parse.cc:
  Merge with 4.1 tree
  Changed // comments to /* */
sql/sql_prepare.cc:
  Merge with 4.1
sql/sql_select.cc:
  Merge with 4.1
sql/sql_table.cc:
  Merge with 4.1
sql/sql_yacc.yy:
  Merge with 4.1
sql/table.h:
  Merge with 4.1
tests/client_test.c:
  Merge with 4.1
2004-07-07 11:29:39 +03:00
unknown
defef7eec6 subselect2.result, select.result:
Post-merge fixes for nested joins.
  The join_tab_cmp function in sql_select has been changed.
join_nested.result:
  Post-merge fixes for nested joins. 
  The join_tab_cmp function in sql_select has been changed
sql_select.cc:
  Post-merge fixes for nested joins.
  Avoided re-execution of eliminate_not_funcs and simplify_joins
  in optimize_cond.
  Changed the join_tab_cmp function to take into account
  the dependent relation.
sql_lex.cc, sql_lex.h:
  Added the first_cond_optimization flag to st_select_lex to avoid
  re-execution of some optimizations in optimize_cond.
sql_base.cc:
  Post-merge fixes for nested joins. 
  Fixed problems with a proper column list substituted for '*' in
  queries with natural joins.


sql/sql_base.cc:
  Post-merge fixes for nested joins. 
  Fixed problems with a proper column list substituted for '*' in
  queries with natural joins.
sql/sql_lex.h:
  Added the first_cond_optimization flag to st_select_lex to avoid
  re-execution of some optimizations in optimize_cond.
sql/sql_lex.cc:
  Added the first_cond_optimization flag to st_select_lex to avoid
  re-execution of some optimizations in optimize_cond.
sql/sql_select.cc:
  Post-merge fixes for nested joins.
  Avoided re-execution of eliminate_not_funcs and simplify_joins
  in optimize_cond.
  Changed the join_tab_cmp function to take into account
  the dependent relation.
mysql-test/r/join_nested.result:
  Post-merge fixes for nested joins. 
  The join_tab_cmp function in sql_select has been changed
mysql-test/r/select.result:
  Post-merge fixes for nested joins.
  The join_tab_cmp function in sql_select has been changed.
mysql-test/r/subselect2.result:
  Post-merge fixes for nested joins.
  The join_tab_cmp function in sql_select has been changed.
2004-06-30 05:54:32 -07:00
unknown
ad93564321 After merge fix
mysql-test/r/join_outer.result:
  Auto merged
mysql-test/r/select.result:
  Auto merged
sql/item_cmpfunc.h:
  Auto merged
sql/sql_lex.cc:
  Auto merged
sql/sql_lex.h:
  Auto merged
sql/sql_parse.cc:
  Auto merged
sql/sql_select.h:
  Auto merged
2004-06-25 06:48:10 -07:00
unknown
4b370d3d9a Merge sanja.is.com.ua:/home/bell/mysql/bk/mysql-4.1
into sanja.is.com.ua:/home/bell/mysql/bk/work-innodb-4.1


sql/item_subselect.cc:
  Auto merged
sql/sql_lex.cc:
  Auto merged
sql/sql_lex.h:
  Auto merged
sql/sql_select.cc:
  Auto merged
2004-06-23 18:58:52 +03:00
unknown
cd23d6e37a join_nested.test, join_nested.result:
new file
Many files:
  Nested joins added.


sql/item_cmpfunc.h:
  Nested joins added.
sql/item_func.h:
  Nested joins added.
sql/sql_base.cc:
  Nested joins added.
sql/sql_lex.cc:
  Nested joins added.
sql/sql_lex.h:
  Nested joins added.
sql/sql_parse.cc:
  Nested joins added.
sql/sql_select.cc:
  Nested joins added.
sql/sql_select.h:
  Nested joins added.
sql/sql_yacc.yy:
  Nested joins added.
sql/table.h:
  Nested joins added.
mysql-test/r/join_outer.result:
  Nested joins added.
mysql-test/r/select.result:
  Nested joins added.
2004-06-10 22:27:21 -07:00
unknown
d8f0df52d3 Optimization to use less memory. 2004-06-10 19:10:21 +05:00
unknown
07b5fdbcdb do not unlock tables early if we have subquery in HAVING clause (BUG#3984)
mysql-test/r/subselect_innodb.result:
  test of unlocking innodb tables and subquery in HAVING clause
mysql-test/t/subselect_innodb.test:
  test of unlocking innodb tables and subquery in HAVING clause
sql/item_subselect.cc:
  mark SELECT with subquery in HAVING clause
sql/sql_lex.cc:
  mark SELECT with subquery in HAVING clause
sql/sql_lex.h:
  mark SELECT with subquery in HAVING clause
sql/sql_select.cc:
  do not unlock tables early if we have subquery in HAVING clause
2004-06-09 23:32:20 +03:00
unknown
f8866c162b Merging 4.1 to 5.0.
BitKeeper/etc/ignore:
  auto-union
BitKeeper/etc/logging_ok:
  auto-union
client/mysqltest.c:
  Auto merged
configure.in:
  Auto merged
include/my_sys.h:
  Auto merged
include/mysql_com.h:
  Auto merged
libmysql/libmysql.c:
  Auto merged
libmysqld/Makefile.am:
  Auto merged
libmysqld/lib_sql.cc:
  Auto merged
myisam/mi_check.c:
  Auto merged
myisam/myisamchk.c:
  Auto merged
myisam/myisamdef.h:
  Auto merged
mysql-test/r/func_group.result:
  Auto merged
mysql-test/r/func_time.result:
  Auto merged
mysql-test/r/null.result:
  Auto merged
mysql-test/r/query_cache.result:
  Auto merged
mysql-test/r/rpl_server_id2.result:
  Auto merged
mysql-test/r/select.result:
  Auto merged
mysql-test/r/subselect.result:
  Auto merged
mysql-test/r/variables.result:
  Auto merged
mysql-test/t/rpl000015.test:
  Auto merged
mysql-test/t/rpl_error_ignored_table.test:
  Auto merged
mysql-test/t/rpl_log.test:
  Auto merged
mysql-test/t/rpl_log_pos.test:
  Auto merged
mysql-test/t/rpl_max_relay_size.test:
  Auto merged
mysql-test/t/rpl_relayrotate.test:
  Auto merged
mysql-test/t/rpl_rotate_logs.test:
  Auto merged
mysql-test/t/rpl_server_id2.test:
  Auto merged
mysql-test/t/subselect.test:
  Auto merged
mysql-test/t/variables.test:
  Auto merged
mysys/my_pthread.c:
  Auto merged
netware/BUILD/compile-netware-all:
  Auto merged
netware/BUILD/compile-netware-standard:
  Auto merged
netware/BUILD/mwenv:
  Auto merged
netware/Makefile.am:
  Auto merged
netware/my_manage.c:
  Auto merged
netware/my_manage.h:
  Auto merged
netware/mysql_test_run.c:
  Auto merged
scripts/mysql_install_db.sh:
  Auto merged
sql/Makefile.am:
  Auto merged
sql/ha_berkeley.cc:
  Auto merged
sql/ha_berkeley.h:
  Auto merged
sql/ha_innodb.cc:
  Auto merged
sql/ha_innodb.h:
  Auto merged
sql/ha_myisam.cc:
  Auto merged
sql/handler.cc:
  Auto merged
sql/handler.h:
  Auto merged
sql/item.cc:
  Auto merged
sql/item.h:
  Auto merged
sql/item_cmpfunc.cc:
  Auto merged
sql/item_func.cc:
  Auto merged
sql/item_subselect.cc:
  Auto merged
sql/item_subselect.h:
  Auto merged
sql/item_sum.cc:
  Auto merged
sql/item_sum.h:
  Auto merged
sql/item_timefunc.cc:
  Auto merged
sql/lock.cc:
  Auto merged
sql/mysql_priv.h:
  Auto merged
sql/opt_range.cc:
  Auto merged
sql/protocol.cc:
  Auto merged
sql/protocol.h:
  Auto merged
sql/repl_failsafe.cc:
  Auto merged
sql/set_var.cc:
  Auto merged
sql/sql_acl.cc:
  Auto merged
sql/sql_base.cc:
  Auto merged
sql/sql_cache.cc:
  Auto merged
sql/sql_class.cc:
  Auto merged
sql/sql_class.h:
  Auto merged
sql/sql_db.cc:
  Auto merged
sql/sql_insert.cc:
  Auto merged
sql/sql_parse.cc:
  Auto merged
sql/sql_prepare.cc:
  Auto merged
sql/sql_select.h:
  Auto merged
sql/sql_show.cc:
  Auto merged
sql/sql_string.cc:
  Auto merged
sql/sql_string.h:
  Auto merged
sql/sql_table.cc:
  Auto merged
sql/sql_union.cc:
  Auto merged
sql/sql_yacc.yy:
  Auto merged
tests/client_test.c:
  Auto merged
2004-05-26 17:04:45 +02:00
unknown
0bf85cfdfa Fix for bug which caused temp_table.test fail on Darwin 7.3
The code in mysql_create_table() code assumes that if lower_case_names==2 then table alias 
should contain unchanged table name, and this was not true for temporary tables which
had 'tmp-table' constant as alias. Now we are using table name as alias for such tables.


sql/sql_lex.cc:
  Removed tmp_table_alias constant which is no longer used.
sql/sql_lex.h:
  Removed tmp_table_alias constant which is no longer used.
sql/sql_yacc.yy:
  Let us use table name instead of 'tmp-table' as alias for table being created by 
  CREATE TEMPORARY TABLE statement. This fixes failing temp_table.test on Darwin 7.3 
  since mysql_create_table() code assumes that if lower_case_names==2 then table alias 
  should contain unchanged table name (and now this assumtion is true but it were false
  for temporary tables before...).
2004-05-24 15:48:19 +04:00
unknown
16227c28e6 PS and SP made compatible in mechanism used for preparing query for rexecutions (Bug #2266)
mysql-test/r/sp.result:
  test suite for Bug #2266
mysql-test/t/sp.test:
  test suite for Bug #2266
sql/item_subselect.cc:
  made ancestor for Statement (Item_arena)
sql/item_subselect.h:
  made ancestor for Statement (Item_arena)
sql/item_sum.cc:
  made ancestor for Statement (Item_arena)
sql/item_sum.h:
  made ancestor for Statement (Item_arena)
sql/mysql_priv.h:
  reset_stmt_for_execute use PS and SP
sql/sp_head.cc:
  sp_head use Item_arena as ancestor to be PS cleunup compatible
  SP use PS storing/restoring/cleanup mechanisms
  cleanup() of SP Items added
  Items created in temporary memory pool during SP execution saved for normal freeing after SP execution
sql/sp_head.h:
  sp_head use Item_arena
sql/sql_base.cc:
  made ancestor for Statement (Item_arena)
  results of wild_setup made permanent
  setup_conds make natural joins expanding only once and store results in PS/SP memory
sql/sql_class.cc:
  made ancestor for Statement (Item_arena)
sql/sql_class.h:
  made ancestor for Statement (Item_arena)
  method to detect PS preparation added
sql/sql_delete.cc:
  storing where for DELETE and mark first execution
sql/sql_derived.cc:
  use method
sql/sql_insert.cc:
  mark first execution for INSERT
sql/sql_lex.cc:
  flags to correctly make transformations of query and storing them in memory of PS/SP
  made ancestor for Statement (Item_arena)
sql/sql_lex.h:
  reved variable od SP ol saving data
  flags to correctly make transformations of query and storing them in memory of PS/SP
sql/sql_parse.cc:
  cleunup unit for any query
sql/sql_prepare.cc:
  made ancestor for Statement (Item_arena)
  storing where moved to preparation
  changed interface of reset_stmt_for_execute to use it is SP
  do not restore where/order by/group by before first execution (but tables and unit can be chenged without execution and should be prepared (subqueries executes on demand))
sql/sql_select.cc:
  storing where for SELECT/multi-DELETE/... and mark first execution
sql/sql_union.cc:
  made ancestor for Statement (Item_arena)
sql/sql_update.cc:
  storing where for UPDATE and mark first execution
2004-05-20 02:02:49 +03:00
unknown
aebab97dd0 Merge sanja.is.com.ua:/home/bell/mysql/bk/mysql-4.1
into sanja.is.com.ua:/home/bell/mysql/bk/work-explain-4.1


mysql-test/r/subselect.result:
  Auto merged
mysql-test/t/subselect.test:
  Auto merged
sql/sql_lex.cc:
  Auto merged
sql/sql_lex.h:
  Auto merged
sql/sql_select.cc:
  Auto merged
sql/sql_union.cc:
  Auto merged
2004-05-14 15:29:23 +03:00
unknown
e54ca13b66 keep old engine & JOIN if we changed subquery Item (Bug #3646)
mysql-test/r/subselect.result:
  ALL/ANY test
mysql-test/t/subselect.test:
  ALL/ANY test
sql/item_subselect.cc:
  keep old engine & JOIN if we changed subquery Item, which allow avoid second all SELECT items fix_fields call with pervios clean up (because of second setup_tables which remove table->key_use and maybe something else)
  keep list when we change Item in SELECT list
  processing inserted max/min function (now JOIN::prepare will be called only once)
  methods of changing item for subselect engines
sql/item_subselect.h:
  change item & results procedure
sql/item_sum.cc:
  Item_sum_hybrid::clear moved to .cc file (to keep .h clean and to make inserving/removing debug info easy)
sql/item_sum.h:
  Item_sum_hybrid::clear moved to .cc file (to keep .h clean and to make inserving/removing debug info easy)
sql/sql_lex.cc:
  note about new method
sql/sql_lex.h:
  method for changing result of UNION JOINs
sql/sql_select.cc:
  method for changing result in JOIN
sql/sql_select.h:
  method for changing result in JOIN
sql/sql_union.cc:
  method for changing result in JOIN
2004-05-07 23:06:11 +03:00
unknown
e9c1e75b48 Merge 4.1 -> 5.0
BitKeeper/etc/ignore:
  auto-union
BitKeeper/etc/logging_ok:
  auto-union
VC++Files/sql/mysqld.dsp:
  Auto merged
configure.in:
  Auto merged
include/my_global.h:
  Auto merged
include/mysql_com.h:
  Auto merged
libmysql/libmysql.c:
  Auto merged
libmysqld/Makefile.am:
  Auto merged
myisam/myisamchk.c:
  Auto merged
myisam/myisamdef.h:
  Auto merged
mysql-test/install_test_db.sh:
  Auto merged
mysql-test/r/func_time.result:
  Auto merged
mysql-test/r/mysqldump.result:
  Auto merged
mysql-test/r/show_check.result:
  Auto merged
mysql-test/r/subselect.result:
  Auto merged
mysql-test/r/union.result:
  Auto merged
mysql-test/t/func_time.test:
  Auto merged
mysql-test/t/subselect.test:
  Auto merged
scripts/make_binary_distribution.sh:
  Auto merged
scripts/mysql_install_db.sh:
  Auto merged
sql/ha_berkeley.cc:
  Auto merged
mysql-test/t/rpl_error_ignored_table.test:
  Auto merged
sql/ha_berkeley.h:
  Auto merged
sql/ha_innodb.cc:
  Auto merged
sql/ha_innodb.h:
  Auto merged
sql/ha_myisam.cc:
  Auto merged
sql/handler.cc:
  Auto merged
sql/handler.h:
  Auto merged
sql/item.cc:
  Auto merged
sql/item.h:
  Auto merged
sql/item_cmpfunc.cc:
  Auto merged
sql/item_cmpfunc.h:
  Auto merged
sql/item_subselect.cc:
  Auto merged
sql/item_sum.cc:
  Auto merged
sql/item_sum.h:
  Auto merged
sql/lex.h:
  Auto merged
sql/log.cc:
  Auto merged
sql/mysql_priv.h:
  Auto merged
sql/mysqld.cc:
  Auto merged
sql/protocol.cc:
  Auto merged
sql/records.cc:
  Auto merged
sql/set_var.cc:
  Auto merged
sql/sql_acl.cc:
  Auto merged
sql/sql_acl.h:
  Auto merged
sql/sql_base.cc:
  Auto merged
sql/sql_cache.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_insert.cc:
  Auto merged
sql/sql_lex.cc:
  Auto merged
sql/sql_load.cc:
  Auto merged
sql/sql_prepare.cc:
  Auto merged
sql/sql_select.h:
  Auto merged
sql/sql_show.cc:
  Auto merged
sql/sql_string.cc:
  Auto merged
sql/sql_test.cc:
  Auto merged
sql/sql_update.cc:
  Auto merged
sql/sql_yacc.yy:
  Auto merged
sql/table.h:
  Auto merged
tests/client_test.c:
  Auto merged
2004-05-07 18:52:06 +02:00
unknown
1a4f499ca8 EXPLAIN UNION using same routing which used for execution which allow return correct bug messages (Bug #3639)
EXPLAIN of hidden SELECT of UNION


mysql-test/r/derived.result:
  explain of hidden select
mysql-test/r/subselect.result:
  explain of hidden select
mysql-test/r/union.result:
  explain of hidden select
  correct error messages on explain
mysql-test/t/subselect.test:
  show eliminated costants in WHERE clause
mysql-test/t/union.test:
  correct error messages on EXPLAIN with union
sql/item.cc:
  fixed name constructing for global ORDER BY items
sql/sql_class.h:
  select ID can be negative (for hidden SELECTs)
  removed unused field
sql/sql_lex.cc:
  new flag of UNION EXPLAIN
sql/sql_lex.h:
  new flag of UNION EXPLAIN
  select ID can be negative (for hidden SELECTs)
sql/sql_select.cc:
  EXPLAIN UNION using same routing which used for execution
  explain for hidden SELECT of UNION
sql/sql_union.cc:
  EXPLAIN UNION using same routing which used for execution
2004-05-06 20:40:21 +03:00
unknown
2c95f97c2b Merge sanja.is.com.ua:/home/bell/mysql/bk/mysql-4.1
into sanja.is.com.ua:/home/bell/mysql/bk/work-ndb-4.1


mysql-test/r/subselect.result:
  Auto merged
sql/sql_lex.cc:
  Auto merged
sql/sql_parse.cc:
  Auto merged
sql/sql_union.cc:
  Auto merged
sql/sql_update.cc:
  Auto merged
2004-05-05 21:24:13 +03:00
unknown
f6428e8bb9 caching of queries with isammerge tables forbiden using general way
SQL_SELECT_LIMIT as default will be applied only for SELECT statement if there was not explicit LIMIT clause
correct table list passed to class constructor of select_update


mysql-test/r/subselect.result:
  do not show limit if it is not explicit
mysql-test/r/union.result:
  test of LIMIT + ORDER
mysql-test/t/union.test:
  test of LIMIT + ORDER
sql/ha_isammrg.h:
  caching of queries with isammerge tables forbiden
sql/sql_cache.cc:
  removed check on isammerge
sql/sql_lex.cc:
  tag of explicit limit in statement
sql/sql_lex.h:
  tag of explicit limit in statement
sql/sql_parse.cc:
  blanks in empty line removed
  no limit by default (SQL_SELECT_LIMIT as default will be applied only for SELECT statement if there was not explicit LIMIT clause)
sql/sql_union.cc:
  reverted incorrect patch
sql/sql_update.cc:
  reverted incorrect patch
  correct table list passed to class constructor
sql/sql_yacc.yy:
  explicit LIMIT marked
2004-05-05 21:21:41 +03:00
unknown
bddee0c170 Windows fixes for VC++ compiler compability
myisam/myisam_ftdump.c:
  VC++ compiler compability fix
mysys/my_getsystime.c:
  Applied Sergei's code for Windows (still subject to changes by him)
sql/handler.cc:
  VC++ compiler compability fix
sql/item_geofunc.cc:
  Removed non-used variable
sql/item_strfunc.cc:
  VC++ compiler compability fix
sql/opt_range.cc:
  VC++ compiler compability fix
sql/sql_insert.cc:
  VC++ compiler compability fix
sql/sql_lex.cc:
  VC++ compiler compability fix
sql/sql_parse.cc:
  VC++ compiler compability fix
sql/sql_prepare.cc:
  VC++ compiler compability fix
sql/sql_union.cc:
  Removed non-used variable and VC++ compiler compability fix
2004-05-05 02:59:17 -03:00
unknown
f1ab98d48e Renamed MY_LEX_COLON to MY_LEX_SEMICOLON (at Serg's request) 2004-04-28 01:49:05 +04:00
unknown
978ba8f47e Fix for BUG#3567: Disallow several SQL statements inside a Prepared Statement. 2004-04-27 03:44:41 +04:00
unknown
43dcf48e2f Formatting changes requested by Monty
sql/gen_lex_hash.cc:
  Minor changes 
   - fix space between for and (
sql/item_subselect.cc:
  Minor changes 
   - fix space between for and (
sql/sql_lex.cc:
  Minor changes 
   - fix space between for and (
sql/sql_string.cc:
  Minor changes 
   - fix space between for and (
2004-04-15 09:17:55 +02:00
unknown
0ba6cb48d8 Added missing return statement
sql/sql_delete.cc:
  Added missing return
sql/sql_lex.cc:
  Comment fixes
sql/sql_parse.cc:
  Comment fixes
2004-04-12 03:26:32 +03:00
unknown
8ab58393c5 after review PS fixes
sql/item_cmpfunc.cc:
  merged in one if
sql/mysql_priv.h:
  removed unused paremeter of check_one_table_access
  declaration of new function for SP share code
sql/set_var.cc:
  function descriotion added
  unneeded parantses removed
sql/sql_acl.cc:
  new parameter to limit number of checked tables for check_grant
sql/sql_acl.h:
  new parameter to limit number of checked tables for check_grant
sql/sql_delete.cc:
  preparation moved in separate function
sql/sql_insert.cc:
  preparation moved in separate function
sql/sql_lex.cc:
  comment style fixed
  unneeded assignment removed
sql/sql_parse.cc:
  new parameter to limit number of checked tables for check_grant
  table list manipulation removed (because of above)
  new precheck function
sql/sql_prepare.cc:
  function rewrited to shere code with sql_prepare.cc
  flow control fixed
sql/sql_show.cc:
  new parameter to limit number of checked tables for check_grant
sql/sql_update.cc:
  preparation moved in separate function
sql/table.h:
  flag renamed
2004-04-10 01:14:32 +03:00
unknown
d5135aff3a merge
sql/item_cmpfunc.cc:
  Auto merged
sql/mysql_priv.h:
  Auto merged
sql/set_var.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_select.cc:
  Auto merged
2004-04-08 00:19:43 +03:00
unknown
c9d856c8b7 new error for unsupported command in PS
fixed IN subselect with basic constant left expression
SQLCOM_CREATE_TABLE, SQLCOM_UPDATE_MULTI, SQLCOM_REPLACE_SELECT, SQLCOM_INSERT_SELECT, QLCOM_DELETE_MULTI fixed to be compatible with PS (BUG#3398, BUG#3406)
fixed multiupdate privelege check (BUG#3408)
fixed multiupdate tables check (BUG#3411)
unchecked commands now is rejected by PS protocol to avoid serever crash
fixed cleunup procedure to be compatible sith DO/SET (BUG#3393)


include/mysqld_error.h:
  new error for unsupported command in PS
mysql-test/r/multi_update.result:
  test sutes (BUG#3408, BUG#3411)
mysql-test/t/multi_update.test:
  test sutes (BUG#3408, BUG#3411)
sql/item_cmpfunc.cc:
  fixed IN subselect with basic constant left expression
sql/mysql_priv.h:
  some function frop sql_parse.h become public
sql/set_var.cc:
  check for SET command via PS
sql/set_var.h:
  check for SET command via PS
sql/share/czech/errmsg.txt:
  new error for unsupported command in PS
sql/share/danish/errmsg.txt:
  new error for unsupported command in PS
sql/share/dutch/errmsg.txt:
  new error for unsupported command in PS
sql/share/english/errmsg.txt:
  new error for unsupported command in PS
sql/share/estonian/errmsg.txt:
  new error for unsupported command in PS
sql/share/french/errmsg.txt:
  new error for unsupported command in PS
sql/share/german/errmsg.txt:
  new error for unsupported command in PS
sql/share/greek/errmsg.txt:
  new error for unsupported command in PS
sql/share/hungarian/errmsg.txt:
  new error for unsupported command in PS
sql/share/italian/errmsg.txt:
  new error for unsupported command in PS
sql/share/japanese/errmsg.txt:
  new error for unsupported command in PS
sql/share/korean/errmsg.txt:
  new error for unsupported command in PS
sql/share/norwegian-ny/errmsg.txt:
  new error for unsupported command in PS
sql/share/norwegian/errmsg.txt:
  new error for unsupported command in PS
sql/share/polish/errmsg.txt:
  new error for unsupported command in PS
sql/share/portuguese/errmsg.txt:
  new error for unsupported command in PS
sql/share/romanian/errmsg.txt:
  new error for unsupported command in PS
sql/share/russian/errmsg.txt:
  new error for unsupported command in PS
sql/share/serbian/errmsg.txt:
  new error for unsupported command in PS
sql/share/slovak/errmsg.txt:
  new error for unsupported command in PS
sql/share/spanish/errmsg.txt:
  new error for unsupported command in PS
sql/share/swedish/errmsg.txt:
  new error for unsupported command in PS
sql/share/ukrainian/errmsg.txt:
  new error for unsupported command in PS
sql/sql_lex.cc:
  first table unlincking procedures for CREATE command
sql/sql_lex.h:
  first table unlincking procedures for CREATE command
sql/sql_parse.cc:
  used function to exclude first table from list
  SQLCOM_CREATE_TABLE, SQLCOM_UPDATE_MULTI, SQLCOM_REPLACE_SELECT, SQLCOM_INSERT_SELECT, QLCOM_DELETE_MULTI fixed to be compatible with PS (BUG#3398, BUG#3406)
  fixed multiupdate privelege check (BUG#3408)
  fixed multiupdate tables check (BUG#3411)
sql/sql_prepare.cc:
  fixed a lot of commands to be compatible with PS
  unchecked commands now is rejected to avoid serever crash
sql/sql_select.cc:
  allow empty result for PS preparing
sql/sql_union.cc:
  fixed cleunup procedure to be compatible sith DO/SET (BUG#3393)
sql/sql_update.cc:
  fixed update to use correct tables lists (BUG#3408)
sql/table.h:
  flag to support multi update tables check (BUG#3408)
tests/client_test.c:
  removed unsupported tables
  fixed show table test
  added new tests
2004-04-08 00:16:17 +03:00
unknown
c635d37479 Merge 4.1 -> 5.0.
BitKeeper/etc/ignore:
  auto-union
BitKeeper/etc/logging_ok:
  auto-union
VC++Files/sql/mysqld.dsp:
  Auto merged
client/Makefile.am:
  Auto merged
client/mysql.cc:
  Auto merged
client/mysqltest.c:
  Auto merged
configure.in:
  Auto merged
include/my_global.h:
  Auto merged
include/my_pthread.h:
  Auto merged
include/my_sys.h:
  Auto merged
include/mysql_com.h:
  Auto merged
libmysqld/Makefile.am:
  Auto merged
libmysqld/lib_sql.cc:
  Auto merged
myisam/mi_check.c:
  Auto merged
myisam/myisamchk.c:
  Auto merged
myisam/myisamdef.h:
  Auto merged
mysql-test/install_test_db.sh:
  Auto merged
mysql-test/r/insert_select.result:
  Auto merged
mysql-test/r/join_outer.result:
  Auto merged
mysql-test/r/null.result:
  Auto merged
mysql-test/r/connect.result:
  Auto merged
mysql-test/r/func_sapdb.result:
  Auto merged
mysql-test/r/mix_innodb_myisam_binlog.result:
  Auto merged
mysql-test/r/mysqldump.result:
  Auto merged
mysql-test/r/rpl_change_master.result:
  Auto merged
mysql-test/r/rpl_log.result:
  Auto merged
mysql-test/r/show_check.result:
  Auto merged
mysql-test/r/symlink.result:
  Auto merged
mysql-test/r/rpl_flush_log_loop.result:
  Auto merged
mysql-test/r/rpl_flush_tables.result:
  Auto merged
mysql-test/r/rpl_loaddata.result:
  Auto merged
mysql-test/r/rpl_loaddata_rule_m.result:
  Auto merged
mysql-test/r/rpl_loaddata_rule_s.result:
  Auto merged
mysql-test/r/rpl_max_relay_size.result:
  Auto merged
mysql-test/r/rpl_reset_slave.result:
  Auto merged
mysql-test/r/rpl_temporary.result:
  Auto merged
mysql-test/r/rpl_until.result:
  Auto merged
mysql-test/r/rpl_user_variables.result:
  Auto merged
mysql-test/r/subselect.result:
  Auto merged
mysql-test/r/union.result:
  Auto merged
mysql-test/r/variables.result:
  Auto merged
mysql-test/t/func_sapdb.test:
  Auto merged
mysql-test/t/mix_innodb_myisam_binlog.test:
  Auto merged
mysql-test/t/mysqlbinlog.test:
  Auto merged
mysql-test/t/rpl_change_master.test:
  Auto merged
mysql-test/t/rpl_log.test:
  Auto merged
mysql-test/t/variables.test:
  Auto merged
netware/BUILD/compile-linux-tools:
  Auto merged
netware/BUILD/compile-netware-END:
  Auto merged
netware/BUILD/compile-netware-all:
  Auto merged
netware/BUILD/compile-netware-standard:
  Auto merged
mysql-test/t/rpl_empty_master_crash.test:
  Auto merged
mysql-test/t/rpl_error_ignored_table.test:
  Auto merged
mysql-test/t/rpl_flush_log_loop.test:
  Auto merged
mysql-test/t/rpl_loaddata.test:
  Auto merged
mysql-test/t/rpl_loaddata_rule_m.test:
  Auto merged
mysql-test/t/rpl_loaddata_rule_s.test:
  Auto merged
mysql-test/t/rpl_max_relay_size.test:
  Auto merged
mysql-test/t/rpl_openssl.test:
  Auto merged
mysql-test/t/rpl_relayrotate-slave.opt:
  Auto merged
mysql-test/t/rpl_reset_slave.test:
  Auto merged
mysql-test/t/rpl_trunc_binlog.test:
  Auto merged
mysql-test/t/rpl_until.test:
  Auto merged
mysql-test/t/rpl_user_variables.test:
  Auto merged
mysql-test/t/subselect.test:
  Auto merged
scripts/make_binary_distribution.sh:
  Auto merged
scripts/mysql_create_system_tables.sh:
  Auto merged
scripts/mysql_fix_privilege_tables.sql:
  Auto merged
scripts/mysql_install_db.sh:
  Auto merged
sql/filesort.cc:
  Auto merged
sql/ha_berkeley.cc:
  Auto merged
sql/ha_berkeley.h:
  Auto merged
sql/ha_innodb.h:
  Auto merged
sql/ha_myisam.cc:
  Auto merged
sql/handler.cc:
  Auto merged
sql/handler.h:
  Auto merged
sql/item.cc:
  Auto merged
sql/item.h:
  Auto merged
sql/item_cmpfunc.cc:
  Auto merged
sql/item_cmpfunc.h:
  Auto merged
sql/item_create.cc:
  Auto merged
sql/item_create.h:
  Auto merged
sql/item_subselect.cc:
  Auto merged
sql/item_sum.cc:
  Auto merged
sql/item_sum.h:
  Auto merged
sql/item_timefunc.h:
  Auto merged
sql/lock.cc:
  Auto merged
sql/log_event.h:
  Auto merged
sql/mysqld.cc:
  Auto merged
sql/net_serv.cc:
  Auto merged
sql/protocol.cc:
  Auto merged
sql/protocol.h:
  Auto merged
sql/repl_failsafe.cc:
  Auto merged
sql/sql_acl.cc:
  Auto merged
sql/sql_acl.h:
  Auto merged
sql/sql_base.cc:
  Auto merged
sql/sql_cache.cc:
  Auto merged
sql/sql_class.h:
  Auto merged
sql/sql_db.cc:
  Auto merged
sql/sql_delete.cc:
  Auto merged
sql/sql_derived.cc:
  Auto merged
sql/sql_lex.h:
  Auto merged
sql/sql_list.h:
  Auto merged
sql/sql_load.cc:
  Auto merged
sql/sql_rename.cc:
  Auto merged
sql/sql_repl.cc:
  Auto merged
sql/sql_repl.h:
  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_test.cc:
  Auto merged
sql/sql_update.cc:
  Auto merged
sql-common/client.c:
  Auto merged
tests/client_test.c:
  Auto merged
2004-04-07 19:07:44 +02:00
unknown
7873b89fc5 Fixed many compiler warnings
Fixed bugs in group_concat with ORDER BY and DISTINCT (Bugs #2695, #3381 and #3319)
Fixed crash when doing rollback in slave and the io thread catched up with the sql thread
Set locked_in_memory properly


include/mysql_com.h:
  Fixed compiler warning
libmysqld/emb_qcache.cc:
  Removed not used variable
libmysqld/lib_sql.cc:
  Removed not used variable
myisam/mi_locking.c:
  Added comment
myisam/mi_rnext.c:
  Fixed bug in concurrent insert
myisam/mi_rprev.c:
  Simple optimization
mysql-test/r/func_gconcat.result:
  New tests
mysql-test/t/func_gconcat.test:
  New tests
mysql-test/t/func_group.test:
  Cleanup
sql-common/client.c:
  Removed compiler warning
sql/derror.cc:
  Better comments
sql/field.cc:
  Removed not used function/variable
sql/field.h:
  Removed not needed variable
sql/ha_innodb.cc:
  Removed not used function
sql/item.cc:
  Fixed compiler warning
sql/item_cmpfunc.cc:
  Fixed compiler warning
sql/item_func.cc:
  Fixed compiler warning
sql/item_geofunc.cc:
  Fixed compiler warning
sql/item_sum.cc:
  Fixed bugs in group_concat and added more comments
  (Bugs #2695, #3381 and #3319)
  - field->abs_offset was not needed
  - Wrong assumption of field order in temporary table
  - Some not used variables removed
  - Added ORDER BY fields after argument fields so that code in sql_select.cc can move all fields to point to temporary tables, if needed.
  - Optimized loops
sql/item_sum.h:
  Bug fixing and cleanup of group_concat()
sql/log.cc:
  Removed wrong comment
sql/log_event.cc:
  Removed compiler warning
sql/mysqld.cc:
  Set locked_in_memory properly
sql/protocol.cc:
  Removed compiler warning
sql/set_var.cc:
  Code cleanup
sql/slave.cc:
  Fixed crash when doing rollback in slave and the io thread catched up with the sql thread
sql/sql_cache.cc:
  Removed compiler warnings
sql/sql_derived.cc:
  Removed not used variable
sql/sql_insert.cc:
  Removed compiler warnings
sql/sql_lex.cc:
  Removed not used lable
sql/sql_lex.h:
  Removed compiler warnings
sql/sql_parse.cc:
  Removed compiler warnings
sql/sql_prepare.cc:
  Removed compiler warnings
sql/sql_select.cc:
  Removed not used variables
  Added function comments
sql/sql_show.cc:
  Removed compiler warnings
sql/sql_yacc.yy:
  Fix for ORDER BY handling in GROUP_CONCAT()
2004-04-05 13:56:05 +03:00
unknown
0a073770c9 after review patch
commant for function


sql/item_subselect.cc:
  redusing number of parameters
sql/sql_derived.cc:
  redusing number of parameters
sql/sql_lex.cc:
  redusing number of parameters
  comment for function
sql/sql_lex.h:
  redusing number of parameters
sql/sql_parse.cc:
  redusing number of parameters
sql/sql_select.cc:
  redusing number of parameters
sql/sql_union.cc:
  redusing number of parameters
2004-03-29 22:40:49 +03:00
unknown
c375d86831 merge
mysql-test/r/union.result:
  Auto merged
2004-03-27 15:59:48 +02:00
unknown
bdb874226e Merge sanja.is.com.ua:/home/bell/mysql/bk/mysql-4.1
into sanja.is.com.ua:/home/bell/mysql/bk/work-alias-4.1


sql/sql_lex.cc:
  Auto merged
sql/sql_union.cc:
  Auto merged
2004-03-25 14:40:36 +02:00
unknown
c0a9df1aae correct support for a mix of UNION/UNION ALL in the same query.
Bug#1428
2004-03-23 14:43:24 +01:00
unknown
a36185af9a fixed union with prepared statement bug found by Konstantin
sql/sql_lex.cc:
  initialisation for safety
sql/sql_union.cc:
  item list should be saved in statement memory
tests/client_test.c:
  test suite
2004-03-23 14:26:54 +02:00
unknown
50499c6d7b fixed comments 2004-03-15 11:02:54 +02:00
unknown
952f99d4c6 merge
mysql-test/r/derived.result:
  Auto merged
mysql-test/t/derived.test:
  Auto merged
sql/item.cc:
  Auto merged
sql/item_cmpfunc.cc:
  Auto merged
sql/item_cmpfunc.h:
  Auto merged
sql/item_sum.h:
  Auto merged
sql/mysql_priv.h:
  Auto merged
sql/sql_acl.cc:
  Auto merged
sql/sql_base.cc:
  Auto merged
sql/sql_class.cc:
  Auto merged
sql/sql_class.h:
  Auto merged
sql/sql_lex.cc:
  Auto merged
sql/sql_select.cc:
  Auto merged
sql/sql_union.cc:
  Auto merged
sql/sql_update.cc:
  Auto merged
2004-02-17 11:12:55 +02:00
unknown
7b6b03f340 merge
sql/mysql_priv.h:
  Auto merged
sql/sql_base.cc:
  Auto merged
sql/sql_class.h:
  Auto merged
sql/sql_insert.cc:
  Auto merged
sql/sql_lex.cc:
  Auto merged
sql/sql_load.cc:
  Auto merged
sql/sql_select.cc:
  Auto merged
sql/sql_update.cc:
  Auto merged
2004-02-17 01:52:33 +02:00
unknown
709356d473 Changed wellformedlen to well_formed_len
Fixed that blobs >16M can be inserted/updated
Fixed bug when doing CREATE TEMPORARY TABLE ... LIKE


include/m_ctype.h:
  Changed wellformedlen to well_formed_len
include/mysql.h:
  Fixed comment
libmysql/libmysql.c:
  Fixed indentation
libmysqld/lib_sql.cc:
  Fixed indentation
mysql-test/r/ctype_utf8.result:
  updated warning numbers
mysql-test/r/innodb.result:
  Moved test to right place
mysql-test/r/myisam-blob.result:
  More test for blobs
mysql-test/r/rpl000002.result:
  Move test to better place
mysql-test/r/rpl_log.result:
  Move test to better place
mysql-test/r/union.result:
  Move test to better place
mysql-test/t/innodb.test:
  Moved test to right place
mysql-test/t/myisam-blob.test:
  More test of blobs
mysql-test/t/rpl000002.test:
  Move test to better place
mysql-test/t/rpl_log.test:
  Move test to better place
mysql-test/t/union.test:
  Move test to better place
sql/field.cc:
  Changed wellformedlen to well_formed_len.
  Fixed that blobs >16M can be inserted/updated (new bug)
sql/field.h:
  Code optimization
sql/sql_lex.cc:
  Changed short variable names
sql/sql_show.cc:
  Optimized quote handling
sql/sql_table.cc:
  Fixed bug when doing CREATE TEMPORARY TABLE ... LIKE
sql/sql_union.cc:
  Added comment
strings/ctype-big5.c:
  Changed wellformedlen to well_formed_len
strings/ctype-bin.c:
  Changed wellformedlen to well_formed_len
strings/ctype-euc_kr.c:
  Changed wellformedlen to well_formed_len
strings/ctype-gb2312.c:
  Changed wellformedlen to well_formed_len
strings/ctype-gbk.c:
  Changed wellformedlen to well_formed_len
strings/ctype-latin1.c:
  Changed wellformedlen to well_formed_len
strings/ctype-mb.c:
  Changed wellformedlen to well_formed_len
strings/ctype-simple.c:
  Changed wellformedlen to well_formed_len
strings/ctype-sjis.c:
  Changed wellformedlen to well_formed_len
strings/ctype-tis620.c:
  Changed wellformedlen to well_formed_len
strings/ctype-ucs2.c:
  Changed wellformedlen to well_formed_len
  Indentation changes
strings/ctype-ujis.c:
  Changed wellformedlen to well_formed_len
strings/ctype-utf8.c:
  Changed wellformedlen to well_formed_len
2004-02-17 01:35:17 +02:00
unknown
54d93c4153 ulternative bugfix for BUG#2508 and fix for BUG#2809 - every table has its own TABLE structure
mysql-test/r/union.result:
  fix for union test becuase now not all fields in UNION allow NULLS
  fix of test
  test suite for BUG#2809
mysql-test/t/union.test:
  test suite for BUG#2809
sql/mysql_priv.h:
  removed unused parameter of setup_tables()
sql/sql_base.cc:
  removed unused parameter of setup_tables()
  cleanup of unused code
sql/sql_class.h:
  removed unused field
sql/sql_help.cc:
  removed unused parameter of setup_tables()
sql/sql_insert.cc:
  removed unused parameter of setup_tables()
sql/sql_lex.cc:
  excluded duplicate tables finding for UNION
sql/sql_load.cc:
  removed unused parameter of setup_tables()
sql/sql_olap.cc:
  removed unused parameter of setup_tables()
sql/sql_prepare.cc:
  removed unused parameter of setup_tables()
sql/sql_select.cc:
  removed unused parameter of setup_tables()
  revert old BUG#2508 patch
sql/sql_union.cc:
  revert old BUG#2508 patch
  removed unused code
sql/sql_update.cc:
  removed unused parameter of setup_tables()
sql/table.h:
  shared used only for multi-update for now
2004-02-17 01:14:51 +02:00
unknown
4899507c7b Merge mysql.com:/usr/local/bk/mysql-5.0
into mysql.com:/home/pem/work/mysql-5.0


mysql-test/r/show_check.result:
  Auto merged
sql/sql_lex.cc:
  Auto merged
sql/sql_yacc.yy:
  Auto merged
2004-02-16 12:47:47 +01:00
unknown
6826a55b1d merge
sql/item.h:
  Auto merged
sql/item_sum.h:
  Auto merged
sql/sql_class.h:
  Auto merged
sql/sql_lex.cc:
  Auto merged
sql/sql_prepare.cc:
  Auto merged
2004-02-14 13:31:39 +02:00
unknown
47e4ca7bec Merge sanja.is.com.ua:/home/bell/mysql/bk/mysql-4.1
into sanja.is.com.ua:/home/bell/mysql/bk/work-limit-4.1


sql/sql_lex.cc:
  Auto merged
sql/sql_parse.cc:
  Auto merged
sql/sql_yacc.yy:
  Auto merged
2004-02-14 13:06:04 +02:00
unknown
f05d5c844f a little optimization in yylex
(case MY_LEX_USER_VARIABLE_DELIMITER for multichar strings)
and my_mbcharlen


include/m_ctype.h:
  a trivial optimization of my_mbcharlen (case !USE_MB)
sql/sql_lex.cc:
  a little optimization in yylex 
  (case MY_LEX_USER_VARIABLE_DELIMITER for multichar strings)
2004-02-14 02:26:27 +04:00
unknown
078919ad9e Merge mysql.com:/home/pem/work/mysql-4.1
into mysql.com:/home/pem/work/mysql-5.0-merge


client/mysql.cc:
  Auto merged
libmysql/libmysql.c:
  Auto merged
libmysqld/lib_sql.cc:
  Auto merged
mysql-test/r/mysqldump.result:
  Auto merged
mysql-test/r/show_check.result:
  Auto merged
sql/item.cc:
  Auto merged
sql/mysql_priv.h:
  Auto merged
sql/sql_class.h:
  Auto merged
sql/sql_lex.cc:
  Auto merged
sql/sql_parse.cc:
  Auto merged
sql-common/client.c:
  Auto merged
sql/sql_prepare.cc:
  Auto merged
sql/sql_show.cc:
  Auto merged
sql/sql_table.cc:
  Auto merged
sql/sql_yacc.yy:
  Auto merged
tests/client_test.c:
  Auto merged
2004-02-13 17:39:00 +01:00
unknown
d476dceb96 Merge sanja.is.com.ua:/home/bell/mysql/bk/mysql-4.1
into sanja.is.com.ua:/home/bell/mysql/bk/work-limit-4.1


mysql-test/r/subselect.result:
  Auto merged
mysql-test/t/subselect.test:
  Auto merged
sql/sql_parse.cc:
  Auto merged
sql/sql_yacc.yy:
  Auto merged
sql/sql_lex.cc:
  Auto merged
2004-02-12 22:33:30 +02:00
unknown
0655f9c633 Merge vvagin@bk-internal.mysql.com:/home/bk/mysql-4.1
into eagle.mysql.r18.ru:/home/vva/work/BUG_2593/mysql-4.1


sql/sql_lex.cc:
  Auto merged
2004-02-13 00:33:29 +04:00
unknown
0bc06e9ec5 Merge eagle.mysql.r18.ru:/home/vva/work/mysql.orig/clear/mysql-4.1
into eagle.mysql.r18.ru:/home/vva/work/BUG_2593/mysql-4.1


sql/mysql_priv.h:
  Auto merged
sql/sql_lex.cc:
  Auto merged
sql/sql_show.cc:
  Auto merged
2004-02-13 00:31:39 +04:00
unknown
7658394a58 Merge mysql.com:/usr/local/bk/mysql-5.0
into mysql.com:/home/pem/work/mysql-5.0


mysql-test/r/show_check.result:
  Auto merged
sql/sql_lex.cc:
  Auto merged
sql/sql_yacc.yy:
  Auto merged
2004-02-12 13:52:10 +01:00
unknown
1e8dcbe01f Bug#2703
"MySQL server does not detect if garbage chara at the end of query"

Allow the parser to see the garbage characters.
Garbage should cause the parser to report an error.


sql/sql_lex.cc:
  Return END_OF_INPUT when at the end of the input buffer.
  Allows the parser to determine if there is junk after a \0 character.
sql/sql_parse.cc:
  Undo 1.314.1.1 04/02/11 12:32:42 guilhem@mysql.com
sql/sql_prepare.cc:
  Undo 1.73 04/02/11 12:32:42 guilhem@mysql.com
2004-02-12 12:01:27 +00:00
unknown
0f0ca5e35b merge
sql/item.cc:
  Auto merged
sql/sql_class.h:
  Auto merged
sql/sql_lex.cc:
  Auto merged
sql/sql_prepare.cc:
  Auto merged
2004-02-12 11:12:16 +02:00
unknown
4b37cf65f7 memory leacks in PS with subqueries fixed (adddition to fix of BUG#2462)
sql/item.h:
  mechanism to keep reference in cache array for row IN
sql/item_cmpfunc.cc:
  mechanism to keep reference in cache array for row IN
  layout fixed
sql/item_cmpfunc.h:
  mechanism to keep reference in cache array for row IN
sql/item_subselect.cc:
  fixed memory pools swapping
  prevented deleting Item_in_optimizer cache in case of row IN subquery
sql/mysql_priv.h:
  declarations of function moved to be useful in sql_class.h
sql/sql_base.cc:
  keep fields expanded from '*' in statement memory pool
sql/sql_class.cc:
  fixed restoring/backup of memory pool and list of items
sql/sql_class.h:
  memory allocation methods moved to Statement
  memory pool substituting for preparing
sql/sql_lex.cc:
  ref_pointer_array kept in statement memory
sql/sql_lex.h:
  reinitialization of UNIT
sql/sql_prepare.cc:
  memory allocation/swapping fixed
tests/client_test.c:
  layout fixed
2004-02-12 03:10:26 +02:00
unknown
6965116320 code cleanup of processing MY_LEX_USER_VARIABLE_DELIMITER
in sql/sql_lex.cc


sql/sql_lex.cc:
  code cleanup of processing MY_LEX_USER_VARIABLE_DELIMITER
2004-02-11 00:47:18 +04:00
unknown
6efd76f317 Merge 4.1 into 5.0.
BitKeeper/etc/logging_ok:
  auto-union
configure.in:
  Auto merged
BitKeeper/deleted/.del-opt_ft.cc~2048ffa561f9c59:
  Auto merged
BitKeeper/deleted/.del-opt_ft.h~24aac1d29304599a:
  Auto merged
client/mysql.cc:
  Auto merged
include/my_global.h:
  Auto merged
libmysql/libmysql.c:
  Auto merged
libmysqld/Makefile.am:
  Auto merged
libmysqld/lib_sql.cc:
  Auto merged
myisam/mi_check.c:
  Auto merged
mysql-test/install_test_db.sh:
  Auto merged
mysql-test/r/multi_update.result:
  Auto merged
mysql-test/r/mysqldump.result:
  Auto merged
mysql-test/r/null.result:
  Auto merged
mysql-test/r/show_check.result:
  Auto merged
mysql-test/r/subselect.result:
  Auto merged
mysql-test/r/symlink.result:
  Auto merged
mysql-test/t/multi_update.test:
  Auto merged
mysql-test/t/null.test:
  Auto merged
mysql-test/t/rpl_until.test:
  Auto merged
mysql-test/t/subselect.test:
  Auto merged
sql/Makefile.am:
  Auto merged
sql/filesort.cc:
  Auto merged
sql/item.cc:
  Auto merged
sql/item_cmpfunc.cc:
  Auto merged
sql/item_cmpfunc.h:
  Auto merged
sql/item_create.cc:
  Auto merged
sql/item_create.h:
  Auto merged
sql/item_func.h:
  Auto merged
sql/item_subselect.cc:
  Auto merged
sql/item_sum.cc:
  Auto merged
sql/item_sum.h:
  Auto merged
sql/item_timefunc.cc:
  Auto merged
sql/mysqld.cc:
  Auto merged
sql/protocol.cc:
  Auto merged
sql/repl_failsafe.cc:
  Auto merged
sql/set_var.cc:
  Auto merged
sql/slave.cc:
  Auto merged
sql/slave.h:
  Auto merged
sql/sql_acl.cc:
  Auto merged
sql/sql_base.cc:
  Auto merged
sql/sql_cache.cc:
  Auto merged
sql/sql_class.h:
  Auto merged
sql/sql_db.cc:
  Auto merged
sql/sql_delete.cc:
  Auto merged
sql/sql_derived.cc:
  Auto merged
sql/sql_insert.cc:
  Auto merged
sql/sql_lex.cc:
  Auto merged
sql/sql_lex.h:
  Auto merged
sql/sql_list.h:
  Auto merged
sql/sql_load.cc:
  Auto merged
sql/sql_prepare.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_union.cc:
  Auto merged
sql/sql_update.cc:
  Auto merged
sql-common/client.c:
  Auto merged
2004-02-10 18:44:02 +01:00
unknown
859aedb446 Merge vvagin@bk-internal.mysql.com:/home/bk/mysql-4.1
into eagle.mysql.r18.ru:/home/vva/work/BUG_2592/mysql-4.1


sql/sql_lex.cc:
  Auto merged
2004-02-10 19:33:02 +04:00
unknown
73c56ba8a5 Merge sanja.is.com.ua:/home/bell/mysql/bk/mysql-4.1
into sanja.is.com.ua:/home/bell/mysql/bk/work-prepared-4.1


mysql-test/r/derived.result:
  Auto merged
mysql-test/t/derived.test:
  Auto merged
sql/sql_acl.cc:
  Auto merged
sql/sql_lex.cc:
  Auto merged
sql/sql_lex.h:
  Auto merged
sql/sql_prepare.cc:
  Auto merged
sql/sql_select.cc:
  Auto merged
sql/sql_union.cc:
  Auto merged
sql/sql_update.cc:
  Auto merged
2004-02-10 02:41:21 +02:00
unknown
ecb11989ad after merge & valgrind test fixes (BUG#2120)
sql/sql_derived.cc:
  memory leack fixed
sql/sql_lex.cc:
  flag to avoid double cleaning
sql/sql_lex.h:
  flag to avoid double cleaning
sql/sql_select.cc:
  right way to cleanup JOIN_TAB
sql/sql_select.h:
  right way to cleanup JOIN_TAB
sql/sql_union.cc:
  flag to avoid double cleaning
2004-02-10 02:18:22 +02:00
unknown
8302f040b7 Merge sanja.is.com.ua:/home/bell/mysql/bk/work-derived2-4.1/
into sanja.is.com.ua:/home/bell/mysql/bk/work-prepared-4.1


sql/sql_lex.cc:
  Auto merged
sql/sql_lex.h:
  Auto merged
sql/sql_prepare.cc:
  Auto merged
sql/sql_select.cc:
  Auto merged
2004-02-09 14:47:41 +02:00
unknown
541cb675c8 fixed subquery with PS (BUG#2462)
fixed UNION preparation


sql/item.cc:
  debug output added
sql/item.h:
  debug output added
sql/item_cmpfunc.cc:
  correct cleunup() for Item_in_optimizer
sql/item_cmpfunc.h:
  correct cleunup() for Item_in_optimizer
  debug output added
sql/item_func.h:
  debug output added
sql/item_subselect.cc:
  support of prepared statemnts added - mostly memorry allocation manegement, only one trabsformatio & correct cleupup()
sql/item_subselect.h:
  support of prepared statemnts added - mostly memorry allocation manegement, only one trabsformatio & correct cleupup()
sql/item_sum.cc:
  debug output added
sql/item_sum.h:
  debug output added
sql/sql_class.cc:
  function to switch allocation arena for Items
sql/sql_class.h:
  function to switch allocation arena for Items
  pointer on current prepared statement added
sql/sql_lex.cc:
  comment fixed
sql/sql_lex.h:
  item cleanup support
sql/sql_prepare.cc:
  - fixed preparation of PS to avoid storing junk in its memory + correct work with union
  - fixed tables cleanup for UNION & subqueries
sql/sql_select.cc:
  removed condition which is always true for now
  fixed layout
sql/sql_union.cc:
  support of UNION subquery cleanup
tests/client_test.c:
  test of repeatable subqueries
  test of correct UNION initialisation
2004-02-08 20:14:13 +02:00
unknown
a54adfc3ab fixed bug #2592 mysqldump doesn't quote "tricky" names correctly
mysql-test/r/mysqldump.result:
  added test for 
  bug #2592 mysqldump doesn't quote "tricky" names correctly
  please note, output's still looking wrong because of bug #2593
  it will be fixed when fix for bug #2593 will be pushed
mysql-test/t/mysqldump.test:
  added test for bug 
  #2592 mysqldump doesn't quote "tricky" names correctly
sql/sql_lex.cc:
  fixed processing of multibyte quoted variables
2004-02-07 02:22:12 +04:00
unknown
dfbaa16160 1. fixed bug @2593 "SHOW CREATE TABLE doesn't properly double quotes"
2. added automatic quotation of keywords in SHOW CREATE TABLE


mysql-test/r/show_check.result:
  added tests for 
  bug #2593 "SHOW CREATE TABLE doesn't properly double quotas"
  and for automatic quotation of keywords
mysql-test/t/show_check.test:
  added tests for 
  bug #2593 "SHOW CREATE TABLE doesn't properly double quotas"
  and for automatic quotation of keywords
sql/mysql_priv.h:
  added declaration of function is_keyword
sql/sql_lex.cc:
  added implementation of function is_keyword
sql/sql_show.cc:
  changed function append_identifier and it's subfunctions
  1. fixed bug @2593 "SHOW CREATE TABLE doesn't properly double quotes"
  2. added automatic quotation of keywords
2004-02-07 00:57:22 +04:00
unknown
fc248069e9 correct assignment of default limit (BUG#2600)
mysql-test/r/subselect.result:
  test of global limit and subqueries
mysql-test/t/subselect.test:
  test of global limit and subqueries
sql/sql_lex.cc:
  correct detection of non-default limits
sql/sql_parse.cc:
  correct assignment of default limit
sql/sql_yacc.yy:
  correct assignment of default limit
2004-02-04 15:26:41 +02:00
unknown
68c0a29987 now all tables of query are locked in one place (including derived tables)
fixed BUG#2120 and other problem with EXPLAINing derived tables


mysql-test/r/derived.result:
  correct tables names & Co in derived tables
  test case for BUG#2120
mysql-test/t/derived.test:
  test case for BUG#2120
sql/mysql_priv.h:
  derived tables processing moved after open/locking all tables (in open_and_lock_tables)
sql/repl_failsafe.cc:
  correct initialization of TABLE_LIST
sql/sql_acl.cc:
  used simple table opening without derived table processing to avoid unneeded initialization of SELECT_LEX
sql/sql_base.cc:
  derived tables processing moved after open/locking all tables (in open_and_lock_tables)
sql/sql_delete.cc:
  all tables processing is done during opening
sql/sql_derived.cc:
  derived tables processing moved after open/locking all tables (in open_and_lock_tables) to sutisfy "all query tables locking" at the moment
sql/sql_insert.cc:
  all tables processing is done during opening
  correct initialization of TABLE_LIST
sql/sql_lex.cc:
  now table list will be created for whole query
  layout fix
  correct check of updated table in subqueries
sql/sql_lex.h:
  now table list will be created for whole query
  correct check of updated table in subqueries
sql/sql_olap.cc:
  THIS FUNCTION IS USED NOWHERE
  it will be good to remove it at all (handle_olaps)
sql/sql_parse.cc:
  derived tables processing moved after open/locking all tables (in open_and_lock_tables)
sql/sql_prepare.cc:
  new creating list parameters
  all tables processing is done during opening
sql/sql_select.cc:
  all tables processing is done during opening
sql/sql_select.h:
  now it used only within file where is defined
sql/sql_udf.cc:
  used simple table opening without derived table processing to avoid unneeded initialization of SELECT_LEX
sql/sql_update.cc:
  all tables processing is done during opening
2004-02-01 15:30:32 +02:00
unknown
e7a336d869 Unused variable removed (cleanup spotted in bug #2214) 2004-01-29 18:27:52 +03:00