Commit graph

7952 commits

Author SHA1 Message Date
unknown
d17a3ae1f4 Add the new sp cache files too (should have been in previous changeset). 2003-07-03 16:01:31 +02:00
unknown
f1c754efe9 Code cleanup (and moved sp cache to separate file). 2003-07-03 15:58:37 +02:00
unknown
8070c06ae0 SP cache (WL#730). (Mostly by vva, additions by pem.)
sql/sp.cc:
  In-memory cache added.
  sp_clear_function_cache() no longer needed.
sql/sp.h:
  In-memory cache added.
  sp_clear_function_cache() no longer needed.
sql/sql_class.cc:
  In-memory cache added.
sql/sql_class.h:
  In-memory cache added.
sql/sql_parse.cc:
  In-memory cache added.
  sp_clear_function_cache() no longer needed.
  Don't delete sp_heads after each use.
2003-07-01 18:14:24 +02:00
unknown
31a58c4068 Bugfixes for the sp_head memroot stuff.
sql/sp.cc:
  Bugfixes for the sp_head memroot stuff. (Do things in the correct order
  at error clean-up.)
sql/sp_head.cc:
  Bugfixes for the sp_head memroot stuff. Make sure everything goes to the
  right memroot. Need separate post-reset-memroot init in sp_head.
sql/sp_head.h:
  Need separate post-reset-memroot init method.
sql/sql_yacc.yy:
  Bugfixes for the sp_head memroot stuff. Make sure everything goes to the
  right memroot. Must do things in the correct order for this.
2003-07-01 17:19:48 +02:00
unknown
663ac86f6c sp_head now has its own mem_root (WL#961).
Also fixed some difficult memory leaks that became apparent
in this task.


sql/sp.cc:
  sp_head now has its own mem_root.
sql/sp_head.cc:
  sp_head now has its own mem_root.
  Also fixed some difficult memory leaks.
sql/sp_head.h:
  sp_head now has its own mem_root.
sql/sql_lex.h:
  Fixed some memory leaks in sp_head. Need to keep track on used lex:es.
sql/sql_parse.cc:
  sp_head now has its own mem_root.
  Fixed SP memory leaks.
sql/sql_prepare.cc:
  Fixed SP memory leaks.
sql/sql_yacc.yy:
  sp_head now has its own mem_root.
2003-06-29 18:15:17 +02:00
unknown
e42120c664 Fixed bug #643, which caused intermittent crashes in net_printf() with repeated
syntax errors in stored procedures.


mysql-test/r/sp-error.result:
  New test case for bugfix (#643)
mysql-test/t/sp-error.test:
  New test case for bugfix (#643)
sql/sp_head.cc:
  Forgot to copy a slot from the original lex. (bug #643)
2003-06-12 15:31:20 +02:00
unknown
40f41ee1fc 'Expand the mysql.proc table to include (almost) all fields' task(851)
Fix after review
2003-06-02 14:25:01 +05:00
unknown
de22365966 Reviewed Novell-supplied patch for 5.0 tree
configure.in:
  Can't put this in yet because of 'make dist'
2003-05-29 14:44:00 -04:00
unknown
c560a02dcd rlyon-5.0.0-alpha.patch
client/mysql.cc:
  Import patch rlyon-5.0.0-alpha.patch
configure.in:
  Import patch rlyon-5.0.0-alpha.patch
include/config-netware.h:
  Import patch rlyon-5.0.0-alpha.patch
include/my_global.h:
  Import patch rlyon-5.0.0-alpha.patch
include/my_pthread.h:
  Import patch rlyon-5.0.0-alpha.patch
mysys/my_pthread.c:
  Import patch rlyon-5.0.0-alpha.patch
netware/BUILD/compile-AUTOTOOLS:
  Import patch rlyon-5.0.0-alpha.patch
netware/BUILD/compile-linux-tools:
  Import patch rlyon-5.0.0-alpha.patch
netware/BUILD/compile-netware-END:
  Import patch rlyon-5.0.0-alpha.patch
netware/BUILD/compile-netware-START:
  Import patch rlyon-5.0.0-alpha.patch
netware/BUILD/compile-netware-all:
  Import patch rlyon-5.0.0-alpha.patch
netware/BUILD/compile-netware-debug:
  Import patch rlyon-5.0.0-alpha.patch
netware/BUILD/compile-netware-standard:
  Import patch rlyon-5.0.0-alpha.patch
netware/BUILD/mwasmnlm:
  Import patch rlyon-5.0.0-alpha.patch
netware/BUILD/mwccnlm:
  Import patch rlyon-5.0.0-alpha.patch
netware/BUILD/mwenv:
  Import patch rlyon-5.0.0-alpha.patch
netware/BUILD/mwldnlm:
  Import patch rlyon-5.0.0-alpha.patch
netware/BUILD/nwbootstrap:
  Import patch rlyon-5.0.0-alpha.patch
netware/Makefile.am:
  Import patch rlyon-5.0.0-alpha.patch
netware/mysql_test_run.c:
  Import patch rlyon-5.0.0-alpha.patch
scripts/make_binary_distribution.sh:
  Import patch rlyon-5.0.0-alpha.patch
sql/mysqld.cc:
  Import patch rlyon-5.0.0-alpha.patch
sql/slave.cc:
  Import patch rlyon-5.0.0-alpha.patch
netware/BUILD/compile-netware-src:
  Import patch rlyon-5.0.0-alpha.patch
netware/BUILD/cron-build:
  Import patch rlyon-5.0.0-alpha.patch
netware/BUILD/crontab:
  Import patch rlyon-5.0.0-alpha.patch
netware/BUILD/knetware.imp:
  Import patch rlyon-5.0.0-alpha.patch
2003-05-29 14:28:02 -04:00
unknown
8ea9613e7e Adopt SP stuff to the new lex pointer.
mysql-test/r/sp.result:
  New test (of more call levels).
mysql-test/t/sp.test:
  New test (of more call levels).
sql/mysql_priv.h:
  SPs wants to init lex only.
sql/sp.cc:
  Restore lex pointer (and fixed memory leak).
sql/sp_head.cc:
  lex is now a pointer, so reset things the right way.
sql/sp_head.h:
  lex is now a pointer.
sql/sql_lex.h:
  SPs wants to init lex only.
sql/sql_parse.cc:
  SPs wants to init lex only.
sql/sql_prepare.cc:
  Restore lex pointer.
2003-05-23 15:32:31 +02:00
unknown
78c162ee22 Merge eagle.mysql.r18.ru:/home/vva/work/mysql.orig/clear/mysql-5.0
into eagle.mysql.r18.ru:/home/vva/work/LEX_PTR/mysql-5.0


sql/sp.cc:
  Auto merged
sql/sp_head.cc:
  Auto merged
sql/sql_class.cc:
  Auto merged
sql/sql_yacc.yy:
  Auto merged
2003-05-14 19:48:58 -04:00
unknown
ab7b332835 Task #627 : user variables' names are now case-insensitive :
@test=@"tEsT"=@`teST` etc. Tests updated.
Note that the patch to sql_class.cc does not use HASH_CASE_INSENSITIVE as did the one which I sent for review. This is because meanwhile HASH_CASE_INSENSITIVE has disappeared (since cset 1.1504.1.6).


mysql-test/r/variables.result:
  updated test
mysql-test/t/variables.test:
  updated test
sql/sql_class.cc:
  Task #627 : user variables' names are now case-insensitive :
  @test=@"tEsT"=@`teST` etc.
2003-05-12 15:36:31 +02:00
unknown
fb5df27adf Expand the mysql.proc table 2003-05-06 21:09:20 +05:00
unknown
b9121cdea3 made lex a pointer in THD 2003-05-05 14:54:37 -04:00
unknown
0e89178661 Merge mysql.com:/home/pem/work/mysql-4.1
into mysql.com:/home/pem/work/mysql-5.0
2003-04-30 14:56:41 +02:00
unknown
4a506d6e23 Fixed bug in Item_func_compress::val_str() on MacOS X (bigendian); the length
was not properly stored in the buffer.


sql/item_strfunc.cc:
  Made it work on MacOS X (bigendian) where int4store is a macro that expands
  the arguments several times.
  It's possible this should be done differently, like not side-stepping the
  String methods the way it's done here, or fixing String::c_ptr(), but this
  simple fix was the quickest way.
2003-04-30 13:10:53 +02:00
unknown
aa1720f3cb One final post-merge fix. 2003-04-29 15:00:16 +02:00
unknown
16a751cca8 Post-merge fix. 2003-04-29 12:31:03 +02:00
unknown
3f25329605 Merged 4.1 to 5.0.
BitKeeper/etc/ignore:
  auto-union
BitKeeper/etc/logging_ok:
  auto-union
include/mysql_com.h:
  Auto merged
libmysql/libmysql.c:
  Auto merged
mysql-test/r/subselect.result:
  Auto merged
mysql-test/r/variables.result:
  Auto merged
mysql-test/t/subselect.test:
  Auto merged
sql/item.cc:
  Auto merged
sql/item.h:
  Auto merged
sql/item_func.cc:
  Auto merged
sql/lex.h:
  Auto merged
sql/log.cc:
  Auto merged
sql/log_event.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/slave.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_delete.cc:
  Auto merged
sql/sql_derived.cc:
  Auto merged
sql/sql_lex.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/sql_update.cc:
  Auto merged
sql/sql_yacc.yy:
  Auto merged
2003-04-29 12:06:04 +02:00
unknown
4ceb257849 Documentation fixed according bug 185 fixing patch (1.1551 03/04/23 00:
Docs/internals.texi:
  Documentation fixed according bug 185 fixing patch (1.1551 03/04/23 00:01:19)
BitKeeper/etc/logging_ok:
  Logging to logging@openlogging.org accepted
2003-04-28 20:40:41 +03:00
unknown
c9a7f29bc6 Merge abotchkov@bk-internal.mysql.com:/home/bk/mysql-4.1
into deer.mysql.r18.ru:/home/hf/work/mysql-4.1.cursor


BitKeeper/etc/ignore:
  auto-union
2003-04-28 14:29:22 +05:00
unknown
c13f555861 SCRUM
Protocol_cursor task
net_field_length definitions trimmed with Monty's suggestions


BitKeeper/etc/ignore:
  Added sql/pack.c to the ignore list
include/my_global.h:
  my_ulonglong definition moved here from mysql.h
include/mysql.h:
  we define my_ulonglong here only if no global.h included
include/mysql_com.h:
  net_field_length_ll definition is here now
sql/mini_client.cc:
  unnecessary cast removed
2003-04-28 14:25:29 +05:00
unknown
64cad16faa Post-fix of bug #302 fix.
Fixed bug #320.
Some new tests and cosmetic changes.
Another strcasecmp() replaced.


mysql-test/r/sp.result:
  Moved SP tests from subselect and added some more.
mysql-test/r/subselect.result:
  Moved SP tests to sp.test.
mysql-test/t/sp.test:
  Moved SP tests from subselect and added some more.
mysql-test/t/subselect.test:
  Moved SP tests to sp.test.
sql/sp.cc:
  Don't close derived tables.
sql/sp_head.cc:
  Minor layout and comment fix.
sql/sp_head.h:
  Minor comment fix.
sql/sql_derived.cc:
  Don't set org_table_list->derived to 1 when debugging, as this breaks certain
  subselect args to SPs.
sql/sql_parse.cc:
  Post-fix of bugfix (free memory on error), and added comment.
sql/sql_yacc.yy:
  Another strcasecmp() replaced.
2003-04-27 17:35:54 +02:00
unknown
55e233ad2b Post-merge fix. 2003-04-26 15:58:39 +03:00
unknown
0c94064bbd merge fix
sql/handler.h:
  Auto merged
sql/item.cc:
  Auto merged
sql/item_strfunc.cc:
  Auto merged
sql/sql_class.h:
  Auto merged
sql/sql_lex.cc:
  Auto merged
sql/sql_lex.h:
  Auto merged
sql/sql_select.cc:
  Auto merged
sql/sql_table.cc:
  Auto merged
2003-04-26 15:26:28 +03:00
unknown
18a321adce Making a better fix for double released pointers and safe
TMP_TABLE_PARAM.
This involved moving things around in include files.
All tests, including the ones with Valgrind passed.
2003-04-26 15:12:14 +03:00
unknown
68e1d7ad42 forgot to commit this one in cset 1.1561 (replication) 2003-04-25 12:31:51 +02:00
unknown
bab7aac779 Merge gbichot@bk-internal.mysql.com:/home/bk/mysql-4.1
into mysql.com:/home/mysql_src/mysql-4.1


sql/mysqld.cc:
  Auto merged
sql/set_var.cc:
  Auto merged
sql/sql_class.h:
  Auto merged
2003-04-24 17:42:07 +02:00
unknown
9b7a51d89d Merge ibabaev@bk-internal.mysql.com:/home/bk/mysql-4.1
into hundin.mysql.fi:/home/igor/dev/mysql-4.1


mysql-test/r/ctype_collate.result:
  Auto merged
sql/mysqld.cc:
  Auto merged
sql/set_var.cc:
  Auto merged
sql/sql_base.cc:
  Auto merged
sql/sql_class.h:
  Auto merged
sql/sql_select.cc:
  Auto merged
2003-04-24 18:42:06 +03:00
unknown
50c17af082 Merge eagle.mysql.r18.ru:/home/vva/work/mysql.orig/clear/mysql-4.1
into eagle.mysql.r18.ru:/home/vva/work/COMPRESS_UNCOMPRESS/mysql-4.1
2003-04-24 11:42:05 -04:00
unknown
78f19df0bc added '.' to end of compressed string 2003-04-24 11:37:55 -04:00
unknown
9f4f19d9f7 Replication: new code to not modify in-memory log positions until the COMMIT
is executed, even if the transaction spans on >=2 relay logs (bug #53).
New variable relay_log_purge =0|1
New test to verify bug #53


sql/log.cc:
  Now we purge a relay log only when we are sure we won't need it,
  i.e. we have executed the final query (if autocommit=1) or the COMMIT.
sql/log_event.cc:
  Better tracking of the relay log's name and position
  lastly executed, even if we are in a transaction which spans on
  2 or more relay logs.
sql/mysql_priv.h:
  new option relay_log_purge (the user can now decide himself
  if he wants his relay logs to be automatically purged or not,
  we don't make unsafe guesses like before)
sql/mysqld.cc:
  new option --innodb (replaces --skip-innodb).
  Useful for the test suite : we have skip-innodb in mysql-test-run,
  but we can ('-opt.info' file) choose to start the server with
  InnoDB for this test only.
  New option --bdb
sql/repl_failsafe.cc:
  Better tracking of the relay log's name and position
  lastly executed, even if we are in a transaction which spans on
  2 or more relay logs.
sql/set_var.cc:
  new variable relay_log_purge
sql/slave.cc:
  Better tracking of the relay log's name and position
  lastly executed, even if we are in a transaction which spans on
  2 or more relay logs.
  Now we purge a relay log only when we are sure we won't need it,
  i.e. we have executed the final query (if autocommit=1) or the COMMIT
sql/slave.h:
  Better tracking of the relay log's name and position
  lastly executed, even if we are in a transaction which spans on
  2 or more relay logs.
sql/sql_class.h:
  prototypes change
sql/sql_parse.cc:
  removed thd argument (was not used in the function's body)
sql/sql_repl.cc:
  Better tracking of the relay log's name and position
  lastly executed, even if we are in a transaction which spans on
  2 or more relay logs.
  Turn relay_log_purge silently off when someone does CHANGE
  MASTER TO RELAY_LOG_*
2003-04-24 15:29:25 +02:00
unknown
4b19dfd431 func_gconcat.result, ctype_many.result:
Added the MAX_LENGTH_FOR_SORT_DATA option
ctype_collate.result:
  Added the MAX_LENGTH_FOR_SORT_DATA option


mysql-test/r/ctype_collate.result:
  Added the MAX_LENGTH_FOR_SORT_DATA option
mysql-test/r/ctype_many.result:
   Added the MAX_LENGTH_FOR_SORT_DATA option
mysql-test/r/func_gconcat.result:
   Added the MAX_LENGTH_FOR_SORT_DATA option
2003-04-24 14:49:01 +03:00
unknown
a7f8b1cb4d Many files:
Added the MAX_LENGTH_FOR_SORT_DATA option
filesort.cc:
  Added the MAX_LENGTH_FOR_SORT_DATA option


sql/filesort.cc:
  Added the MAX_LENGTH_FOR_SORT_DATA option
sql/mysqld.cc:
   Added the MAX_LENGTH_FOR_SORT_DATA option
sql/opt_range.cc:
   Added the MAX_LENGTH_FOR_SORT_DATA option
sql/records.cc:
   Added the MAX_LENGTH_FOR_SORT_DATA option
sql/set_var.cc:
   Added the MAX_LENGTH_FOR_SORT_DATA option
sql/sql_base.cc:
   Added the MAX_LENGTH_FOR_SORT_DATA option
sql/sql_class.h:
   Added the MAX_LENGTH_FOR_SORT_DATA option
sql/sql_delete.cc:
   Added the MAX_LENGTH_FOR_SORT_DATA option
sql/sql_select.cc:
   Added the MAX_LENGTH_FOR_SORT_DATA option
sql/sql_sort.h:
   Added the MAX_LENGTH_FOR_SORT_DATA option
sql/sql_table.cc:
   Added the MAX_LENGTH_FOR_SORT_DATA option
sql/sql_update.cc:
   Added the MAX_LENGTH_FOR_SORT_DATA option
sql/structs.h:
   Added the MAX_LENGTH_FOR_SORT_DATA option
sql/table.h:
   Added the MAX_LENGTH_FOR_SORT_DATA option
sql/uniques.cc:
   Added the MAX_LENGTH_FOR_SORT_DATA option
2003-04-24 14:33:33 +03:00
unknown
06e8139be7 Merge abotchkov@bk-internal.mysql.com:/home/bk/mysql-5.0
into deer.mysql.r18.ru:/home/hf/work/mysql-5.0.kil
2003-04-24 08:22:56 +05:00
unknown
d19e16d4de SCRUM
two versions of KILL
small fix


sql/sql_select.cc:
  it's more logical to use killed here
2003-04-24 08:22:11 +05:00
unknown
37c9401782 subselect in procedure argument list (Bug #302)
BitKeeper/etc/ignore:
  Added libmysqld/sp_pcontext.cc libmysqld/sp.cc libmysqld/sp_head.cc to the ignore list
mysql-test/r/subselect.result:
  test of subselect in procedure argument list
mysql-test/t/subselect.test:
  test of subselect in procedure argument list
sql/sp_head.cc:
  subselect in procedure argument list
sql/sql_parse.cc:
  subselect in procedure argument list
2003-04-23 22:31:47 +03:00
unknown
f0909cd71a SCRUM
Protocol_cursor class and sql-common/ directory


Makefile.am:
  pack.c added to linked sources
include/mysql.h:
  net_field_length_ll declaration added
include/mysql_com.h:
  net_field_length declaration added
libmysql/Makefile.am:
  sql-common files symlinked
libmysql/Makefile.shared:
  pack.lo target added
libmysql/libmysql.c:
  net_field_length removed from here
sql/Makefile.am:
  pack.c added to the sources
sql/mini_client.cc:
  mc_net_field_length functions replaced with net_field_length
sql/protocol.h:
  Protocol_cursor class added
2003-04-23 19:37:33 +05:00
unknown
4405216099 Fixes bug #302: call u((select 1)) now works.
More complex cases, like call u((select x from table limit 1)) does not.
2003-04-23 16:21:56 +02:00
unknown
4ac98ec521 set_var.cc:
We don't need this code any more. It was used to initialize CONVERT structure in 4.0.


sql/set_var.cc:
  We don't need this code any more. It was used to initialize CONVERT structure in 4.0.
2003-04-23 18:38:54 +05:00
unknown
bb12690ad7 Variable names have been renamed:
client_collation -> collation_client
  result_collation -> collation_results
  connection_collation -> collation_connection


BitKeeper/etc/ignore:
  Added client/ssl_test to the ignore list
2003-04-23 18:19:22 +05:00
unknown
fbf47d5234 Fix bug#68: ssl_test.c does not compile/work 2003-04-23 17:10:24 +05:00
unknown
711eb800ad Merge sanja.is.com.ua:/home/bell/mysql/bk/mysql-4.1
into sanja.is.com.ua:/home/bell/mysql/bk/work-order-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_parse.cc:
  Auto merged
sql/sql_yacc.yy:
  Auto merged
2003-04-23 11:20:19 +03:00
unknown
b648068856 Merge sanja.is.com.ua:/home/bell/mysql/bk/mysql-4.1
into sanja.is.com.ua:/home/bell/mysql/bk/work-in-4.1


sql/item_cmpfunc.cc:
  Auto merged
2003-04-23 10:37:13 +03:00
unknown
f525047d1e Made multiple queries (SELECT without INTO) work in SPs.
This included bug fixes in the 4.1 protocol (actually send and receive the
server_status flags).


libmysql/libmysql.c:
  Pick up the server_status (with the 4.1 protocol) as well.
mysql-test/r/sp-error.result:
  Test for "bad selects" in non-CLIENT_MULTI_QUERIES clients (as mysqltest for the
  momen; this test will have to go away eventually).
mysql-test/t/sp-error.test:
  Test for "bad selects" in non-CLIENT_MULTI_QUERIES clients (as mysqltest for the
  momen; this test will have to go away eventually).
sql/protocol.cc:
  Actually send the server_status flags in send_eof() (4.1 protocol), not just zero.
sql/sp_head.cc:
  Made multiple queries (SELECT without INTO) work in SPs.
sql/sp_head.h:
  Made multiple queries (SELECT without INTO) work in SPs.
sql/sql_parse.cc:
  Made multiple queries (SELECT without INTO) work in SPs.
sql/sql_yacc.yy:
  Made multiple queries (SELECT without INTO) work in SPs.
2003-04-23 09:22:54 +02:00
unknown
7900c2f1ad Added --delimiter option to mysql
client/mysql.cc:
  Added --delimiter option to mysql. Statement terminator
  can be a character (';' by default) or a string.
  
  Code clean up
2003-04-23 03:29:03 +03:00
unknown
78b2c66bff Merge eagle.mysql.r18.ru:/home/vva/work/mysql.orig/clear/mysql-4.1
into eagle.mysql.r18.ru:/home/vva/work/COMPRESS_UNCOMPRESS/mysql-4.1
2003-04-22 18:46:06 -04:00
unknown
5ab46afca6 small compress/uncompress modification after monty's review 2003-04-22 18:41:47 -04:00
unknown
06017a0db0 fixed bug 185 (constant IN (SELECT field ...) do not return NULL correctly)
mysql-test/r/subselect.result:
  new test results
  test of bug 185
mysql-test/t/subselect.test:
  test of bug 185
sql/item.h:
  new method
sql/item_cmpfunc.cc:
  new Item to control NULL value in HAVING clouse
sql/item_cmpfunc.h:
  new Item to control NULL value in HAVING clouse
sql/item_subselect.cc:
  if IN was rewrited through WHERE thien it will be rewrited in following way:
  
  WHERE left_expr=item or is null(item) heving is_not_null_test(item)
sql/item_subselect.h:
  Item_is_not_null_test can change was_null flag
sql/sql_select.cc:
  some layout fix
2003-04-23 00:01:19 +03:00
unknown
c5475dd93c sql_base.cc:
Table name cache is case-sensitive now like in 4.0.


sql/sql_base.cc:
  Table name cache is case-sensitive now like in 4.0.
2003-04-22 19:01:24 +05:00