Commit graph

29505 commits

Author SHA1 Message Date
unknown
886a35bd82 Bug#16461: connection_id() does not work properly inside trigger
CONNECTION_ID() was implemented as a constant Item, i.e. an instance of
Item_static_int_func class holding value computed at creation time.
Since Items are created on parsing, and trigger statements are parsed
on table open, the first connection to open a particular table would
effectively set its own CONNECTION_ID() inside trigger statements for
that table.

Re-implement CONNECTION_ID() as a class derived from Item_int_func, and
compute connection_id on every call to fix_fields().


mysql-test/r/trigger.result:
  Add result for bug#16461.
mysql-test/t/trigger.test:
  Add test case for bug#16461.
sql/item.cc:
  Remove now unused class Item_static_int_func.
sql/item.h:
  Remove now unused class Item_static_int_func.
sql/item_create.cc:
  Use new implementation of CONNECTION_ID().
sql/item_func.cc:
  Re-implement CONNECTION_ID() as Item_func_connection_id
  (was Item_static_int_func).  Set max_length to 10, as it was before.
  Compute connection_id dynamically on every call to fix_fields().
sql/item_func.h:
  Re-implement CONNECTION_ID() as Item_func_connection_id
  (was Item_static_int_func).
2006-04-12 19:31:00 +04:00
unknown
daac388624 Merge mysql.com:/extern/mysql/bk/mysql-5.0-runtime
into  mysql.com:/extern/mysql/5.0/generic/mysql-5.0-runtime
2006-04-07 16:55:49 +02:00
unknown
148cf113e5 Renaming sp_pcontext members and methods; less cryptic and more consistent.
Also added comments, and fixing some coding style (mostly in comments too).
There are no functional changes, so no tests or documentation needed.
(This was originally part of a bugfix, but it was decided to not include this
 in that patch; instead it's done separately.)


sql/sp_head.cc:
  Renaming sp_pcontext members and methods; less cryptic and more consistent.
sql/sp_head.h:
  Renaming sp_pcontext members and methods; less cryptic and more consistent.
sql/sp_pcontext.cc:
  Renaming sp_pcontext members and methods; less cryptic and more consistent.
  Also added comments, and fixing some coding style (mostly in comments too).
sql/sp_pcontext.h:
  Renaming sp_pcontext members and methods; less cryptic and more consistent.
  Also added comments, and fixing some coding style (mostly in comments too).
sql/sp_rcontext.cc:
  Renaming sp_pcontext members and methods; less cryptic and more consistent.
sql/sp_rcontext.h:
  Renaming sp_pcontext members and methods; less cryptic and more consistent.
sql/sql_yacc.yy:
  Renaming sp_pcontext members and methods; less cryptic and more consistent.
2006-04-07 16:53:15 +02:00
unknown
cab73a6009 Bug#15933: max_used_connections is wrong after FLUSH STATUS if connections are cached
After FLUSH STATUS max_used_connections was reset to 0, and haven't
been updated while cached threads were reused, until the moment a new
thread was created.

The first suggested fix from original bug report was implemented:

  a) On flushing the status, set max_used_connections to
  threads_connected, not to 0.

  b) Check if it is necessary to increment max_used_connections when
  taking a thread from the cache as well as when creating new threads


mysql-test/r/status.result:
  Add result for bug#15933.
mysql-test/t/status.test:
  Add test case for bug#15933.
  Fixed typo.
sql/mysql_priv.h:
  Add declaration of refresh_status(), which is now external.
sql/mysqld.cc:
  Remove start_cached_thread() (code moved directly into create_new_thread()).
  Add comment for create_new_thread ().
  In create_new_thread() update max_used_connections when creating new thread
  and when reusing the cached one.
  Move refresh_status() from sql/sql_parse.cc here, on refresh set
  max_used_connections to the current number of connections.
sql/sql_parse.cc:
  refresh_status() moved to sql/mysqld.cc.
2006-04-07 15:30:40 +04:00
unknown
70f4dbaa6e yassl link problem fixed
config/ac-macros/yassl.m4:
  typo
libmysql/Makefile.am:
  move common code to Makefile.shared
libmysql/Makefile.shared:
  move common code to Makefile.shared
libmysql_r/Makefile.am:
  move common code to Makefile.shared
2006-04-03 12:07:18 +02:00
unknown
b5ca723613 Merge
scripts/mysql_install_db.sh:
  Auto merged
2006-04-03 03:52:22 +02:00
unknown
2574445ef1 Makefile.am:
Distribute mysql-test-run.pl


mysql-test/Makefile.am:
  Distribute mysql-test-run.pl
2006-04-03 03:47:28 +02:00
unknown
d2744ebcfd Merge mysql.com:/Users/kent/mysql/bk/mysql-4.0
into mysql.com:/Users/kent/mysql/bk/mysql-4.1-new


scripts/mysql_install_db.sh:
  Auto merged
2006-04-03 03:40:54 +02:00
unknown
e2b19a59d2 mysql_install_db.sh, MySQLEULA.txt, mysql_install_db.c:
Changed web address order.mysql.com to shop.mysql.com


netware/mysql_install_db.c:
  Changed web address order.mysql.com to shop.mysql.com
Docs/MySQLEULA.txt:
  Changed web address order.mysql.com to shop.mysql.com
scripts/mysql_install_db.sh:
  Changed web address order.mysql.com to shop.mysql.com
2006-04-03 03:37:43 +02:00
unknown
6de1d9d378 Makefile.am:
Install Perl mysql-test-run into test directory


mysql-test/Makefile.am:
  Install Perl mysql-test-run into test directory
2006-04-02 02:10:41 +02:00
unknown
a6871e2713 Merge 2006-04-01 05:53:37 +02:00
unknown
2a4e2e8da2 Makefile.am:
Let "make install" install mysql-test-run.pl
mysql.spec.sh:
  Set $LDFLAGS from $MYSQL_BUILD_LDFLAGS (bug#16662)


support-files/mysql.spec.sh:
  Set $LDFLAGS from $MYSQL_BUILD_LDFLAGS (bug#16662)
mysql-test/Makefile.am:
  Let "make install" install mysql-test-run.pl
2006-04-01 05:44:10 +02:00
unknown
3eb7f2a239 Merge mysql.com:/Users/kent/mysql/bk/mysql-4.0
into mysql.com:/Users/kent/mysql/bk/mysql-4.1-new


README:
  Auto merged
2006-04-01 04:17:30 +02:00
unknown
c19a6fc5c3 README:
Typo (bug#17167)


README:
  Typo (bug#17167)
2006-04-01 04:13:33 +02:00
unknown
3ff1ec0f89 zlib.m4:
Use CPPFLAGS when testing to link "libz" found in --with-zlib-dir=,
  and search the given include directory first (bug#18369)


config/ac-macros/zlib.m4:
  Use CPPFLAGS when testing to link "libz" found in --with-zlib-dir=,
  and search the given include directory first (bug#18369)
2006-04-01 03:49:14 +02:00
unknown
381e1fced6 Merge mysql.com:/Users/kent/mysql/bk/mysql-4.1-new
into mysql.com:/Users/kent/mysql/bk/mysql-5.0-new


BitKeeper/deleted/.del-acinclude.m4~f4ab416bac5003:
  Auto merged
2006-04-01 03:37:13 +02:00
unknown
1f762dab21 acinclude.m4:
Use CPPFLAGS when testing to link "libz" found in --with-zlib-dir=,
  and search the given include directory first (bug#18369)


acinclude.m4:
  Use CPPFLAGS when testing to link "libz" found in --with-zlib-dir=,
  and search the given include directory first (bug#18369)
2006-04-01 03:28:07 +02:00
unknown
835d2286f5 Merge mysql.com:/Users/kent/mysql/bk/mysql-4.1-new
into mysql.com:/Users/kent/mysql/bk/mysql-5.0-new


VC++Files/libmysqld/libmysqld.vcproj:
  Auto merged
VC++Files/mysys/mysys.vcproj:
  Auto merged
VC++Files/sql/mysqld.vcproj:
  Auto merged
2006-04-01 02:46:32 +02:00
unknown
ab96fa0728 Merge kboortz@bk-internal.mysql.com:/home/bk/mysql-5.0
into mysql.com:/Users/kent/mysql/bk/mysql-5.0-new
2006-04-01 02:46:31 +02:00
unknown
a432c53f07 Merge aivanov@bk-internal.mysql.com:/home/bk/mysql-5.0
into  mysql.com:/home/alexi/innodb/mysql-5.0-merged
2006-04-01 04:46:30 +04:00
unknown
0ad405f9d4 vcproj files:
Set MYSQL_SERVER_SUFFIX from build scripts, not hard
  code it into Visual Studio project files, bug#15974


VC++Files/bdb/bdb.vcproj:
  Set MYSQL_SERVER_SUFFIX from build scripts, not hard code into project files, bug#15974
VC++Files/innobase/innobase.vcproj:
  Set MYSQL_SERVER_SUFFIX from build scripts, not hard code into project files, bug#15974
VC++Files/libmysqld/libmysqld.vcproj:
  Set MYSQL_SERVER_SUFFIX from build scripts, not hard code into project files, bug#15974
VC++Files/mysqldemb/mysqldemb.vcproj:
  Set MYSQL_SERVER_SUFFIX from build scripts, not hard code into project files, bug#15974
VC++Files/mysys/mysys.vcproj:
  Set MYSQL_SERVER_SUFFIX from build scripts, not hard code into project files, bug#15974
VC++Files/sql/mysqld.vcproj:
  Set MYSQL_SERVER_SUFFIX from build scripts, not hard code into project files, bug#15974
2006-04-01 02:14:54 +02:00
unknown
872d1d71a1 Makefile.am, yassl.m4:
Enable automake to determine dependency on yaSSL, by explicitly
  listing the .la files in Makefile.am, instead of using
  'yassl_libs_with_path', bug#18273


config/ac-macros/yassl.m4:
  Enable automake to determine dependency on yaSSL, by explicitly
  listing the .la files in Makefile.am, instead of using
  'yassl_libs_with_path', bug#18273
libmysql/Makefile.am:
  Enable automake to determine dependency on yaSSL, by explicitly
  listing the .la files in Makefile.am, instead of using
  'yassl_libs_with_path', bug#18273
libmysql_r/Makefile.am:
  Enable automake to determine dependency on yaSSL, by explicitly
  listing the .la files in Makefile.am, instead of using
  'yassl_libs_with_path', bug#18273
2006-04-01 01:24:28 +02:00
unknown
87c70a599f Merge aivanov@bk-internal.mysql.com:/home/bk/mysql-5.0
into  mysql.com:/home/alexi/innodb/mysql-5.0-merged
2006-04-01 03:20:39 +04:00
unknown
f6ffb77cb4 Applied innodb-5.0-ss398 snapshot.
Fixed BUG#15650: DELETE with LEFT JOIN crashes server
 with innodb_locks_unsafe_for_binlog.
 Fixed compilation problem with non-C99 compilers
 in btr0sea.c


innobase/btr/btr0sea.c:
  Applied innodb-5.0-ss398 snapshot.
   Fix compilation problem with non-C99 compilers.
sql/ha_innodb.cc:
  Applied innodb-5.0-ss398 snapshot.
   Remove assertion ut_error which crashes the mysqld
   server if it prints a warning about the adaptive latch.
2006-04-01 01:54:15 +04:00
unknown
1de1269116 Fixed a typo. 2006-03-31 22:54:26 +03:00
unknown
085aa5c99e Merge mysql.com:/home/timka/mysql/src/5.0-virgin
into  mysql.com:/home/timka/mysql/src/5.0-bug-16710


mysql-test/r/group_min_max.result:
  Auto merged
mysql-test/t/group_min_max.test:
  Auto merged
sql/item.cc:
  Auto merged
sql/item.h:
  Auto merged
sql/opt_range.cc:
  Auto merged
2006-03-31 12:39:33 +03:00
unknown
a01d48f92e Fix for BUG#16710.
The bug was due to a missed case in the detection of whether an index
can be used for loose scan. More precisely, the range optimizer chose
to use loose index scan for queries for which the condition(s) over
an index key part could not be pushed to the index together with the
loose scan.

As a result, loose index scan was selecting the first row in the
index with a given GROUP BY prefix, and was applying the WHERE
clause after that, while it should have inspected all rows with
the given prefix, and apply the WHERE clause to all of them.

The fix detects and skips such cases.


mysql-test/r/group_min_max.result:
  Added test for BUG#16710.
mysql-test/t/group_min_max.test:
  Added test for BUG#16710.
sql/item.cc:
  Added new method [Item | Item_field]::find_item_in_field_list_processor.
sql/item.h:
  Added new method [Item | Item_field]::find_item_in_field_list_processor.
sql/opt_range.cc:
  Handle the case when there is no MIN/MAX aggregate function, and a
  keypart of the index being considered, that is after the GROUP BY
  prefix, is used in the WHERE clause and the condition where it is
  used cannot be pushed to the index.
  If this is the case, we rule out this index.
2006-03-31 12:34:28 +03:00
unknown
fa7e5ed5d7 zlib.m4, openssl.m4:
Use  when testing if shared library exists, bug#16332


config/ac-macros/openssl.m4:
  Use  when testing if shared library exists, bug#16332
config/ac-macros/zlib.m4:
  Use  when testing if shared library exists, bug#16332
2006-03-31 01:03:45 +02:00
unknown
86504f8785 Merge rurik.mysql.com:/home/igor/mysql-5.0
into  rurik.mysql.com:/home/igor/dev/mysql-5.0-0


sql/sql_select.cc:
  Auto merged
2006-03-30 11:34:14 -08:00
unknown
7369780845 Fix incorrect merge: put '/*' comment start back. 2006-03-30 22:35:50 +04:00
unknown
618269b6c6 Merge epotemkin@bk-internal.mysql.com:/home/bk/mysql-5.0
into sunlight.local:/local_work/15560-bug-5.0-mysql
2006-03-30 19:05:55 +04:00
unknown
321e7b22c3 item_sum.cc, sql_select.cc:
After merge fix for bug#15560
item_sum.h:
   After merge fix for bug#15560


sql/sql_select.cc:
  After merge fix for bug#15560
sql/item_sum.h:
   After merge fix for bug#15560
sql/item_sum.cc:
  After merge fix for bug#15560
2006-03-30 19:04:21 +04:00
unknown
e0708e2c11 Manual merge
myisam/mi_search.c:
  Auto merged
mysql-test/t/ctype_utf8.test:
  Auto merged
2006-03-30 17:14:55 +04:00
unknown
c15921ad3d Merge abarkov@bk-internal.mysql.com:/home/bk/mysql-5.0
into  mysql.com:/usr/home/bar/mysql-5.0


sql/field.cc:
  Auto merged
2006-03-30 13:04:58 +05:00
unknown
ff4de90501 Merge epotemkin@bk-internal.mysql.com:/home/bk/mysql-4.1
into sunlight.local:/local_work/15560-bug-4.1-mysql


sql/sql_table.cc:
  Auto merged
2006-03-30 10:22:03 +04:00
unknown
b7f090e402 Merge mysql.com:/Users/kent/mysql/bk/mysql-5.0-release
into mysql.com:/Users/kent/mysql/bk/mysql-5.0-new


ndb/tools/Makefile.am:
  Auto merged
2006-03-30 08:13:49 +02:00
unknown
e40b76c970 btr0sea.c:
Added BTR_CHUNK_SIZE, removed 'chunk_size' declared after declaration block


innobase/btr/btr0sea.c:
  Added BTR_CHUNK_SIZE, removed 'chunk_size' declared after declaration block
2006-03-30 08:10:03 +02:00
unknown
01109952f2 2006-03-30 06:53:39 +02:00
unknown
66ac19e2cf Merge
BitKeeper/deleted/.del-acinclude.m4~f4ab416bac5003:
  Auto merged
2006-03-30 06:48:40 +02:00
unknown
600a17635e post-merge fix 2006-03-30 09:13:25 +05:00
unknown
a7431720ce Merge
mysql-test/t/create.test:
  Auto merged
sql/sql_table.cc:
  Auto merged
mysql-test/r/create.result:
  SCCS merged
2006-03-30 08:13:28 +05:00
unknown
9a02fede24 Fixed bug #18279: crash in the cases when on conditions are moved
out of a nested join to the on conditions for the nest.
The bug happened due to:
1. The function simplify_joins could change on expressions for nested joins.
   Yet modified on expressions were not saved in prep_on_expr.
2. On expressions were not restored for nested joins in 
   reinit_stmt_before_use.


mysql-test/r/join_nested.result:
  Added a test case for bug #18279.
mysql-test/t/join_nested.test:
  Added a test case for bug #18279.
sql/sql_prepare.cc:
  Fixed bug #18279.
  On expressions were not restored for nested joins in 
  reinit_stmt_before_use.
sql/sql_select.cc:
  Fixed bug #18279.
  The function simplify_joins could change on expressions for nested joins.
  Yet modified on expressions were not saved in prep_on_expr.
2006-03-29 16:45:29 -08:00
unknown
a48af9eb2c Merge bk-internal.mysql.com:/home/bk/mysql-4.1
into  mysql.com:/home/my/mysql-4.1
2006-03-30 03:32:58 +03:00
unknown
4c0111460b Cleanup during review of new pushed code
sql/ha_heap.cc:
  Indentation fixes
strings/ctype-ucs2.c:
  Simplify code
tests/mysql_client_test.c:
  Remove compiler warnings
2006-03-30 03:11:37 +03:00
unknown
2d6a51b4c8 Fix error in prefix compression of keys in MyISAM when key length changed from 254 -> 255
Bug #17705 "FT Index corruption occurs with UTF8 data..."
(Actually, the bug had nothing to do with FT index but with general key compression)



myisam/mi_search.c:
  Fix error in prefix compression of keys in MyISAM when key length changed from 254 -> 255
mysql-test/r/ctype_utf8.result:
  Test of fix for key compression bug
mysql-test/t/ctype_utf8.test:
  Test of fix for key compression bug
2006-03-30 01:50:52 +03:00
unknown
3479ec3780 mysql-test-run.pl:
Check that port range is valid, bug#16807


mysql-test/mysql-test-run.pl:
  Check that port range is valid, bug#16807
2006-03-30 00:48:46 +02:00
unknown
2d8acd2fdc mysqld_safe.sh:
Added --help option, bug#16392
acinclude.m4:
  Use "$shrext_cmds" when testing if shared library exists, bug#16332


acinclude.m4:
  Use "$shrext_cmds" when testing if shared library exists, bug#16332
scripts/mysqld_safe.sh:
  Added --help option, bug#16392
2006-03-29 23:51:23 +02:00
unknown
e672bb7004 Makefile.am:
Use "dist_bin_SCRIPTS" to get a script distributed


ndb/tools/Makefile.am:
  Use "dist_bin_SCRIPTS" to get a script distributed
2006-03-29 22:51:49 +02:00
unknown
92df85b43a Merge kboortz@bk-internal.mysql.com:/home/bk/mysql-4.1
into mysql.com:/Users/kent/mysql/bk/mysql-4.1-new
2006-03-29 22:34:40 +02:00
unknown
113efc0046 Makefile.am:
Use "dist_bin_SCRIPTS" to get a script distributed


ndb/tools/Makefile.am:
  Use "dist_bin_SCRIPTS" to get a script distributed
2006-03-29 22:33:27 +02:00