An error occurred fetching the project authors.
- 31 Aug, 2004 1 commit
-
-
unknown authored
mysql-test/r/negation_elimination.result: new tests of negation elimination mysql-test/t/negation_elimination.test: new tests of negation elimination sql/item.h: test of boolean functions added sql/item_cmpfunc.cc: NOT subtree is already checked, so wee need to return just argument sql/item_cmpfunc.h: test of boolean functions added sql/mysql_priv.h: 'place' to detect WHERE clause sql/sql_parse.cc: function for creation negated expression sql/sql_select.cc: removed unused function sql/sql_select.h: removed unused function sql/sql_yacc.yy: 'place' to detect WHERE clause
-
- 25 Aug, 2004 1 commit
-
-
unknown authored
Update to new valgrind mysql-test/mysql-test-run.sh: Update for new valgrind sql/mysql_priv.h: Remove default argument to mysql_truncate() sql/sql_parse.cc: Remove default argument to mysql_truncate()
-
- 24 Aug, 2004 1 commit
-
-
unknown authored
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
-
- 20 Aug, 2004 2 commits
-
-
unknown authored
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.
-
unknown authored
in a deadlock-free manner. This splits locking the global read lock in two steps. This fixes a consequence of this bug, known as: BUG#4953 'mysqldump --master-data may report incorrect binlog position if using InnoDB' And a test. sql/handler.cc: making COMMIT wait if FLUSH TABLES WITH READ LOCK happened. sql/lock.cc: an additional stage so that FLUSH TABLES WITH READ LOCK blocks COMMIT: make_global_read_lock_block_commit(): taking the global read lock is TWO steps (2nd step is optional; without it, COMMIT of existing transactions will be allowed): lock_global_read_lock() THEN make_global_read_lock_block_commit(). sql/mysql_priv.h: new argument to wait_if_global_read_lock() sql/sql_class.h: THD::global_read_lock now an uint to reflect the 2 steps of global read lock (does not block COMMIT / does) sql/sql_db.cc: update for new prototype sql/sql_parse.cc: implementing the two steps of global read lock so that FLUSH TABLES WITH READ LOCK can block COMMIT without deadlocking with COMMITs.
-
- 19 Aug, 2004 2 commits
-
-
unknown authored
Fix for BUG#4971 "CREATE TABLE ... TYPE=HEAP SELECT ... stops slave (wrong DELETE in binlog)": replacing the no_log argument of mysql_create_table() by some safer method (temporarily setting OPTION_BIN_LOG to 0) which guarantees that even the automatic DELETE FROM heap_table does not get into the binlog when a not-yet-existing HEAP table is opened by mysql_create_table(). mysql-test/r/rpl_heap.result: result update mysql-test/t/rpl_heap.test: changing test to test a bug (but anyway, mysql-test-run --manager looks like not working in 4.1 currently, so this test is never run). sql/log.cc: new class Disable_binlog used to temporarily disable binlogging for one thread. sql/mysql_priv.h: removing argument no_log from mysql_create_table(); no_log was not perfect as some binlogging could still be done by open_unireg_entry() for a HEAP table. sql/sql_class.h: new class Disable_binlog used to temporarily disable binlogging for one thread. sql/sql_parse.cc: removing no_log arg from mysql_create_table() sql/sql_table.cc: removing no_log from mysql_create_table(); instead using new class Disable_binlog. Disabling binlogging in some cases, where the binlogging is done later by some other code (case of CREATE SELECT and ALTER).
-
unknown authored
include/mysql.h: Fixed symbol name change. include/mysql_com.h: Reverted parts of previous changeset (name changes) to make it build. libmysql/libmysql.c: Fixed symbol name change. sql/sql_parse.cc: Fixed symbol name change.
-
- 18 Aug, 2004 1 commit
-
-
unknown authored
replacing the no_log argument of mysql_create_table() by some safer method (temporarily setting OPTION_BIN_LOG to 0) which guarantees that even the automatic DELETE FROM heap_table does not get into the binlog when a not-yet-existing HEAP table is opened by mysql_create_table(). mysql-test/r/rpl_heap.result: result update mysql-test/t/rpl_heap.test: testing a bug sql/log.cc: new class Disable_binlog used to temporarily disable binlogging for one thread. sql/mysql_priv.h: removing argument no_log from mysql_create_table(); no_log was perfect as some binlogging could still be done by open_unireg_entry() for a HEAP table. sql/sql_class.h: new class Disable_binlog used to temporarily disable binlogging for one thread. sql/sql_parse.cc: removing no_log sql/sql_table.cc: removing no_log from mysql_create_table(); instead using new class Disable_binlog. Disabling binlogging in some cases, where the binlogging is done later by some other code (case of CREATE SELECT and ALTER).
-
- 13 Aug, 2004 1 commit
-
-
unknown authored
ENUM and SET type didn't compute their length correctly. That showed up for example while converting into a CHAR column.
-
- 10 Aug, 2004 1 commit
-
-
unknown authored
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.
-
- 06 Aug, 2004 1 commit
-
-
unknown authored
We should allow 19 as length of newly created TIMESTAMP fields. mysql-test/r/type_timestamp.result: Added test of TIMESTAMP(19) support. mysql-test/t/type_timestamp.test: Added test of TIMESTAMP(19) support. sql/sql_parse.cc: add_field_to_list(): TIMESTAMP columns should also support 19 as length since it is length of 4.1 compatible representation. BitKeeper/etc/logging_ok: Logging to logging@openlogging.org accepted
-
- 21 Jul, 2004 1 commit
-
-
unknown authored
-
- 12 Jul, 2004 1 commit
-
-
unknown authored
mysys/my_init.c: Extra debugging sql/mysqld.cc: Added comment sql/sql_parse.cc: Removed unneeded info vio/viosocket.c: Added assert. Don't close already closed files
-
- 09 Jul, 2004 1 commit
-
-
unknown authored
Some bug fixes to last pushed code mysql-test/mysql-test-run.sh: Fix for new valgrind (2.1.1) mysql-test/r/bdb.result: Updated results mysql-test/t/ps_1general.test: removed wrong error condition sql/ha_berkeley.cc: Fix for index_flags() in new code sql/item_strfunc.cc: Cleanup (fixed indentation, removed short variable names) sql/mysql_priv.h: Cleanup of db option cacheing sql/mysqld.cc: Cleanup of db option cacheing sql/sql_db.cc: Cleanup of db option cacheing sql/sql_parse.cc: Cleanup of db option cacheing sql/sql_table.cc: sprintf -> strxmov sql/table.cc: key_read should be tested on key parts, not the whole key
-
- 08 Jul, 2004 1 commit
-
-
unknown authored
also known as BUG#2326 Charset of table is determined by charset of db only if "USE db;"
-
- 26 Jun, 2004 1 commit
-
-
unknown authored
mysql-test/r/func_group.result: fixed mysql-test/r/ps.result: SHOW TABLE STATUS test mysql-test/t/ps.test: SHOW TABLE STATUS test sql/sql_parse.cc: Use lex->describe instead of lex->select_lex.options sql/sql_yacc.yy: removed unneed initialization of lex->select_lex.options
-
- 24 Jun, 2004 1 commit
-
-
unknown authored
sql/sql_parse.cc: parameter of my_yyoverflow made independed from YYSIZE_T sql/sql_yacc.yy: parameter of my_yyoverflow made independed from YYSIZE_T
-
- 23 Jun, 2004 1 commit
-
-
unknown authored
mysql-test/r/union.result: test of correct parser stack overflow handling mysql-test/t/union.test: test of correct parser stack overflow handling sql/sql_parse.cc: parameter of my_yyoverflow made independed from YYSIZE_T sql/sql_yacc.yy: parameter of my_yyoverflow made independed from YYSIZE_T
-
- 21 Jun, 2004 1 commit
-
-
unknown authored
sql/item_func.cc: Unused variable 'thd' removed. sql/item_subselect.cc: Unused variable 'type' removed. sql/slave.cc: Unused variable 'return_val' removed. sql/sql_derived.cc: Unused variable 'is_subsel' removed. sql/sql_parse.cc: Unused variables 'pstr' and 'create_info' removed. sql/sql_prepare.cc: Unused variable 'res' removed. sql/time.cc: Unused variable 'str_begin' removed.
-
- 18 Jun, 2004 2 commits
-
-
unknown authored
mysqld >=4.1.3 will however understand shutdown requests sent by clients <4.1.3. And mysqld <4.1.3 will understand shutdown requests sent by clients >=4.1.3 (it will ignore the level). Those shutdown level are just PLACEHOLDERS now. So this change is just to make the 4.1 API suitable before it is frozen. Later we will actually implement the shutdown levels. VC++Files/winmysqladmin/main.cpp: 2nd argument to mysql_shutdown() VC++Files/winmysqladmin/mysql.h: 2nd argument to mysql_shutdown() VC++Files/winmysqladmin/mysql_com.h: Several types of shutdown now. include/mysql_com.h: SHUTDOWN_DEFAULT is now 0 instead of 255, this saves one test in sql_parse.cc libmysql/libmysql.c: correcting mistake (how come that my tests still all worked with this? - should recheck, for curiosity). sql/sql_parse.cc: with SHUTDOWN_DEFAULT==0, no need for testing packet_length.
-
unknown authored
Added basic per-thread time zone functionality (based on public domain elsie-code). Now user can select current time zone (from the list of time zones described in system tables). All NOW-like functions honor this time zone, values of TIMESTAMP type are interpreted as values in this time zone, so now our TIMESTAMP type behaves similar to Oracle's TIMESTAMP WITH LOCAL TIME ZONE (or proper PostgresSQL type). WL#1266 "CONVERT_TZ() - basic time with time zone conversion function". Fixed problems described in Bug #2336 (Different number of warnings when inserting bad datetime as string or as number). This required reworking of datetime realted warning hadling (they now generated at Field object level not in conversion functions). Optimization: Now Field class descendants use table->in_use member instead of current_thd macro. include/my_global.h: Added macro for reading of 32-bit ints stored in network order from unaligned memory location. include/mysqld_error.h: Added error-code for invalid timestamp warning and error-code for wrong or unknown time zone specification. libmysqld/Makefile.am: Added main per-thread time zone support file to libmysqld libmysqld/lib_sql.cc: Added initialization of time zones infrastructure to embedded server. mysql-test/r/connect.result: Updated test result since now mysql database contains more system tables. mysql-test/r/date_formats.result: Now when truncation occurs during conversion to datetime value we are producing Warnings instead of Notes. Also we are giving more clear warnings about this in some cases. mysql-test/r/func_sapdb.result: New warnings about truncation occured during conversion to datetime value added due their better handling. mysql-test/r/func_time.result: New warnings about truncation occured during conversion to datetime value added due their better handling. mysql-test/r/select.result: New warnings about truncation occured during conversion to datetime value added due their better handling. Also tweaked test a bit to made it less ambigious for reader. mysql-test/r/system_mysql_db.result: Updated test result because new system tables holding time zone descriptions were added. mysql-test/r/timezone.result: Updated timezone.test to use new system variable which shows system time zone. Added test of warning which is produced if someone tries to store non-existing (due falling into spring time-gap) datetime value into TIMESTAMP field. mysql-test/r/type_datetime.result: Separated and extended test of values and warnings produced for bad values stored in DATETTIME fields. mysql-test/r/type_time.result: Now we are producing more consistent warning when we are truncating datetime value while storing it in TIME field. mysql-test/r/type_timestamp.result: Separated and extended test of values and warnings produced for bad values stored in TIMESTAMP fields. mysql-test/t/select.test: Updated test to make it less ambigous for reader. mysql-test/t/timezone.test: Updated timezone.test to use new system variable which shows system time zone. Added test of warning which is produced if someone tries to store non-existing (due falling into spring time-gap) datetime value into TIMESTAMP field. mysql-test/t/type_datetime.test: Separated and extended test of values and warnings produced for bad values stored in DATETTIME fields. mysql-test/t/type_timestamp.test: Separated and extended test of values and warnings produced for bad values stored in TIMESTAMP fields. scripts/mysql_create_system_tables.sh: Added creation of tables with time zone descriptions. Also added descriptions of time zones used in tests. scripts/mysql_fix_privilege_tables.sql: Added mysql.time_zone* tables family. sql/Makefile.am: Added files implementing time zone support to server, also added rules for building of mysql_tzinfo_to_sql converter and test_time test. sql/field.cc: Now we are using per-thread time zone for TIMESTAMP <-> whatever conversion. Fixed generation of warnings for datetime types (DATETIME/TIMESTAMP/DATE/...) and any other Field to datetime conversion (now we are generating warnings no in lower level functions like in str_to_TIME() but in Field methods. This allows generate better and more consistent warnings and to reuse code of str_to_TIME() outside of server). Added 3rd parameter to set_warning() method to be able to not increment cut fields but still produce a warning. Also added set_datetime_warning() family of auxiliary methods which allow easier generate datetime related warnings. Also replaced occurences of current_thd with table->in_use member, added asserts for catching all places there we need to set table->in_use accordingly. Renamed fix_datetime() function to number_to_TIME() and moved it to sql/time.cc there it fits better. sql/field.h: Added comment about places where we can use table->in_use member instead of current_thd. Added 3rd parameter to Field::set_warning() method and set_datetime_warning() family of methods. sql/field_conv.cc: Field::set_warning() method with 2 arguments was replaced with more generic set_warning() method with 3 arguments. sql/ha_berkeley.cc: Now we set table->in_use for temporary tables so we have to use table->tmp_table for checking if table is temporary. sql/item.cc: Replaced calls to str_to_time() and str_to_TIME() funcs with their warning generating analogs. sql/item_create.cc: Added creation of CONVERT_TZ function as FUNC_ARG3. sql/item_create.h: Added creation of CONVERT_TZ function as FUNC_ARG3. sql/item_timefunc.cc: Added support of per-thread time zone to NOW-like and FROM_UNIXTIME, UNIX_TIMESTAMP functions. Added support for CONVERT_TZ function. Removed call to str_to_timestamp function which caused non-optimal behavior in certain cases. Replaced calls to str_to_time() function with its warning generating analog. sql/item_timefunc.h: Added support of per-thread time zone to NOW-like and FROM_UNIXTIME, UNIX_TIMESTAMP functions. Added support of CONVERT_TZ function. sql/lex.h: Added support of CONVERT_TZ function. sql/log.cc: Added support for replication of statements depending on time zone. sql/mysql_priv.h: Now including headers with per-thread time zone support functions and classes. Added portable replacement of time_t - my_time_t type. Added time zone as one of query distinguishing parameters for query cache. Fixed declarations of str_to_TIME, str_to_time and my_system_gmt_sec (former my_gmt_sec) since now they have one more out parameter which informs about wrong datetime value or data truncation during conversion. Added warning generating version of str_to_TIME() and str_to_time() functions. Thrown away str_to_datetime/timestamp functions since they are not needed any longer. Added number_to_TIME function. sql/mysqld.cc: Added per-thread time zone support initialization. Added new startup parameter --default-time-zone. sql/set_var.cc: Added support for per-thread time_zone variable. Renamed old timezone variable to system_time_zone. sql/set_var.h: Added support for per-thread time_zone variable. sql/share/czech/errmsg.txt: Added error message for barking when incorrect time zone name or specifiaction is provided and for warning about invalid TIMESTAMP values (e.g. falling into the spring time-gap). sql/share/danish/errmsg.txt: Added error message for barking when incorrect time zone name or specifiaction is provided and for warning about invalid TIMESTAMP values (e.g. falling into the spring time-gap). sql/share/dutch/errmsg.txt: Added error message for barking when incorrect time zone name or specifiaction is provided and for warning about invalid TIMESTAMP values (e.g. falling into the spring time-gap). sql/share/english/errmsg.txt: Added error message for barking when incorrect time zone name or specifiaction is provided and for warning about invalid TIMESTAMP values (e.g. falling into the spring time-gap). sql/share/estonian/errmsg.txt: Added error message for barking when incorrect time zone name or specifiaction is provided and for warning about invalid TIMESTAMP values (e.g. falling into the spring time-gap). sql/share/french/errmsg.txt: Added error message for barking when incorrect time zone name or specifiaction is provided and for warning about invalid TIMESTAMP values (e.g. falling into the spring time-gap). sql/share/german/errmsg.txt: Added error message for barking when incorrect time zone name or specifiaction is provided and for warning about invalid TIMESTAMP values (e.g. falling into the spring time-gap). sql/share/greek/errmsg.txt: Added error message for barking when incorrect time zone name or specifiaction is provided and for warning about invalid TIMESTAMP values (e.g. falling into the spring time-gap). sql/share/hungarian/errmsg.txt: Added error message for barking when incorrect time zone name or specifiaction is provided and for warning about invalid TIMESTAMP values (e.g. falling into the spring time-gap). sql/share/italian/errmsg.txt: Added error message for barking when incorrect time zone name or specifiaction is provided and for warning about invalid TIMESTAMP values (e.g. falling into the spring time-gap). sql/share/japanese/errmsg.txt: Added error message for barking when incorrect time zone name or specifiaction is provided and for warning about invalid TIMESTAMP values (e.g. falling into the spring time-gap). sql/share/korean/errmsg.txt: Added error message for barking when incorrect time zone name or specifiaction is provided and for warning about invalid TIMESTAMP values (e.g. falling into the spring time-gap). sql/share/norwegian-ny/errmsg.txt: Added error message for barking when incorrect time zone name or specifiaction is provided and for warning about invalid TIMESTAMP values (e.g. falling into the spring time-gap). sql/share/norwegian/errmsg.txt: Added error message for barking when incorrect time zone name or specifiaction is provided and for warning about invalid TIMESTAMP values (e.g. falling into the spring time-gap). sql/share/polish/errmsg.txt: Added error message for barking when incorrect time zone name or specifiaction is provided and for warning about invalid TIMESTAMP values (e.g. falling into the spring time-gap). sql/share/portuguese/errmsg.txt: Added error message for barking when incorrect time zone name or specifiaction is provided and for warning about invalid TIMESTAMP values (e.g. falling into the spring time-gap). sql/share/romanian/errmsg.txt: Added error message for barking when incorrect time zone name or specifiaction is provided and for warning about invalid TIMESTAMP values (e.g. falling into the spring time-gap). sql/share/russian/errmsg.txt: Added error message for barking when incorrect time zone name or specifiaction is provided and for warning about invalid TIMESTAMP values (e.g. falling into the spring time-gap). sql/share/serbian/errmsg.txt: Added error message for barking when incorrect time zone name or specifiaction is provided and for warning about invalid TIMESTAMP values (e.g. falling into the spring time-gap). sql/share/slovak/errmsg.txt: Added error message for barking when incorrect time zone name or specifiaction is provided and for warning about invalid TIMESTAMP values (e.g. falling into the spring time-gap). sql/share/spanish/errmsg.txt: Added error message for barking when incorrect time zone name or specifiaction is provided and for warning about invalid TIMESTAMP values (e.g. falling into the spring time-gap). sql/share/swedish/errmsg.txt: Added error message for barking when incorrect time zone name or specifiaction is provided and for warning about invalid TIMESTAMP values (e.g. falling into the spring time-gap). sql/share/ukrainian/errmsg.txt: Added error message for barking when incorrect time zone name or specifiaction is provided and for warning about invalid TIMESTAMP values (e.g. falling into the spring time-gap). sql/slave.cc: In order to support replication of statements using time zones in 4.1 we should ensure that both master and slave have same default time zone. sql/sql_base.cc: Now we are setting TABLE::in_use member for all tables (which assume calls to Field::store or val_ methods). sql/sql_cache.cc: Added time zone as one more query distinguishing parameter for query cache. sql/sql_class.cc: Added THD::time_zone_used variable indicating that this query uses per thread time zone. sql/sql_class.h: Added per-thread time zone variable. Added THD::time_zone_used variable indicating that this query uses per thread time zone so if this is updating query the time zone should be logged to binlog. sql/sql_insert.cc: We should set TABLE::in_use member pointing to thread which is called INSERT DELAYED and not to worker thread. sql/sql_load.cc: Field::set_warning() now has one more argument now. sql/sql_parse.cc: Resetting THD::time_zone_used variable in the end of query processing. sql/sql_select.cc: Now we are setting TABLE::in_use member for all tables (which assume calls to Field::store or val_ methods). sql/sql_show.cc: Now using per thread time zone for extended show tables. sql/time.cc: Added support for per-thread time zones for TIMESTAMP type and reworked generation of warnings for TIMESTAMP and DATETIME types. (Introduced new TIME_to_timestamp() function. Removed hours normalisation from former my_gmt_sec() since it was not working and not used anywhere now, but breaks parameter constness, added to this function generation of warning if we are falling in spring time-gap. Removed str_to_timestamp and str_to_datetime functions which are no longer used. Moved fix_datetime function from sql/field.cc to this file as number_to_TIME() function. Added out parameter for str_to_TIME and str_to_time functions which indicates if value was truncated during conversion, removed direct generation of warnings from this functions.) sql/unireg.cc: Now we are setting TABLE::in_use member for all tables (which assume calls to Field::store or val_ methods). BitKeeper/etc/ignore: Added sql/test_time sql/mysql_tzinfo_to_sql libmysqld/tztime.cc to the ignore list
-
- 17 Jun, 2004 2 commits
- 15 Jun, 2004 1 commit
-
-
unknown authored
Server will however still accept shutdown without specified level; so that old mysqladmin can still shut server down. I would like your comments on the names of shutdown level which I chose. You are welcome to propose better names. Please however check WL#709 before. Reason for the names I propose is to be accurate, thus leaving possibility for other levels which we may imagine in the future; that's why I have rejected names like "fast", "smart", "graceful" so far. My position is that WAIT_ALL_BUFFERS or WAIT_CRITICAL_BUFFERS say what the shutdown does, whereas for "smart", "fast" you need to remember what it does. This should be pushed in 4.1.3 but only after your comments. client/mysqladmin.c: 2nd parameter for mysql_shutdown() include/mysql.h: 2nd paramater for mysql_shutdown() include/mysql_com.h: 4 types of shutdown libmysql/libmysql.c: passing the requested shutdown level sql/sql_parse.cc: check for the shutdown level in dispatch_command(). Though its value is ignored for now. tools/mysqlmanager.c: 2nd parameter to mysql_shutdown
-
- 13 Jun, 2004 1 commit
-
-
unknown authored
mysql-test/r/subselect.result: outer fields resolving in INSERT/REPLACE and CRETE with SELECT mysql-test/t/subselect.test: outer fields resolving in INSERT/REPLACE and CRETE with SELECT sql/sql_parse.cc: fixed field resolving mode fo INSERT/REPLACE and CRETE with SELECT sql/sql_prepare.cc: fixed field resolving mode fo INSERT/REPLACE and CRETE with SELECT
-
- 10 Jun, 2004 3 commits
-
-
unknown authored
correct prefix compare with my_strnncoll include/m_ctype.h: 6th argument to my_strncoll to handle prefix comparison myisam/ft_boolean_search.c: bug#3964 and related issues: problems with charsets where one byte can match many *correct* prefix compare with my_strnncoll *correct* backup of info->lastkey mysql-test/r/fulltext.result: 6th argument to my_strncoll to handle prefix comparison mysql-test/t/fulltext.test: 6th argument to my_strncoll to handle prefix comparison mysys/my_handler.c: 6th argument to my_strncoll to handle prefix comparison sql/sql_parse.cc: cleanup strings/ctype-big5.c: 6th argument to my_strncoll to handle prefix comparison strings/ctype-bin.c: 6th argument to my_strncoll to handle prefix comparison strings/ctype-czech.c: 6th argument to my_strncoll to handle prefix comparison strings/ctype-gbk.c: 6th argument to my_strncoll to handle prefix comparison strings/ctype-latin1.c: 6th argument to my_strncoll to handle prefix comparison strings/ctype-mb.c: 6th argument to my_strncoll to handle prefix comparison strings/ctype-simple.c: 6th argument to my_strncoll to handle prefix comparison strings/ctype-sjis.c: 6th argument to my_strncoll to handle prefix comparison strings/ctype-tis620.c: 6th argument to my_strncoll to handle prefix comparison strings/ctype-uca.c: 6th argument to my_strncoll to handle prefix comparison strings/ctype-ucs2.c: 6th argument to my_strncoll to handle prefix comparison strings/ctype-utf8.c: 6th argument to my_strncoll to handle prefix comparison strings/ctype-win1250ch.c: 6th argument to my_strncoll to handle prefix comparison
-
unknown authored
exactly it's mapped to "ALTER TABLE t; ANALYZE TABLE t;" sql/ha_innodb.cc: ::optimize() now returns "try ALTER and then analyze" instead of only analyze. sql/handler.h: new code to say "try alter and analyze". sql/mysql_priv.h: as we may now use mysql_alter_table() internally to ::optimize we must prevent it from talking to the client. New function mysql_recreate_table() which is the same as ALTER TABLE t; sql/sql_parse.cc: the big block removed here is moved into mysql_recreate_table(). sql/sql_table.cc: In mysql_admin_table(): if the handler returns HA_ADMIN_TRY_ALTER, we close the table, recreate it, then open it and analyze it. This is currently used only for OPTIMIZE TABLE of an InnoDB table.
-
unknown authored
sql/sql_parse.cc: Cleanup of patch
-
- 09 Jun, 2004 2 commits
- 08 Jun, 2004 1 commit
-
-
unknown authored
-
- 07 Jun, 2004 1 commit
-
-
unknown authored
mysql-test/r/ps.result: Better error message mysys/my_error.c: Comments added sql/item.cc: Moved a chunk of code from sql_prepare.cc to Item_param::set_from_user_var sql/item.h: Moved a chunk of code from sql_prepare.cc to Item_param::set_from_user_var sql/item_func.cc: Code cleanup sql/mysql_priv.h: Code cleanup sql/sql_class.cc: Code cleanup sql/sql_parse.cc: use user_var_entry::val_str in PREPARE stmt FROM @var. sql/sql_prepare.cc: Post-review fixes and code cleanup. sql/sql_yacc.yy: Coding style fixes
-
- 03 Jun, 2004 1 commit
-
-
unknown authored
by binlogging some SET ONE_SHOT CHARACTER_SETetc, which will be enough until we have it more compact and more complete in 5.0. With the present patch, replication will work ok between 4.1.3 master and slaves, as long as: - master and slave have the same GLOBAL.COLLATION_SERVER - COLLATION_DATABASE and CHARACTER_SET_DATABASE are not used - application does not use the fact that table is created with charset of the USEd db (BUG#2326). all of which are not too hard to fulfill. ONE_SHOT is reserved for internal use of mysqlbinlog|mysql and works only for charsets, so we give error if used for non-charset vars. Fix for BUG#3875 "mysqlbinlog produces wrong ouput if query uses variables containing quotes" and BUG#3943 "Queries with non-ASCII literals are not replicated properly after SET NAMES". Detecting that master and slave have different global charsets or server ids. mysql-test/r/rpl_server_id1.result: it's normal to not run as I have added a test to compare server ids of master and slave at startup and stop if equal (unless --replicate-same-server-id) mysql-test/r/rpl_user_variables.result: result update (as we now print charset of user var). mysql-test/r/user_var.result: result update mysql-test/t/rpl_server_id1.test: no need to select as slave is not running mysql-test/t/user_var.test: testing if the content of user vars is escaped when mysqlbinlog prints them, and if the name is backquoted. sql/lex.h: new keyword ONE_SHOT sql/log.cc: when writing to the binlog, before writing the actual statement, write some SET ONE_SHOT CHARACTER_SET_CLIENT etc for the slave to know the charset variables (which are important as they affect the inserted data). sql/log_event.cc: print charset and collation of user var in mysqlbinlog and SHOW BINLOG EVENTS. escape the content of the var. Backquote its name. Will ask Bar to check that using my_charset_bin for escaping is ok. sql/set_var.cc: understand SET CHARACTER_SET_CLIENT=10 (don't require a string, accept a number). Refuse changing of GLOBAL CHARACTER_SET_SERVER/COLLATION_SERVER if binlog or slave, as it will make the master or slave make wrong assumptions. A function to catch SET ONE_SHOT on non-charset variables (which is forbidden) sql/set_var.h: no_support_one_shot to know if the var supports ONE_SHOT (only charset vars do, soon timezones). Accept int arg in SET CHARACTER_SET_etc sql/slave.cc: when I/O slave thread starts, verify that master's and slave charsets match. And by the way verify that server ids are different. Don't fail if UNIX_TIMESTAMP() can't be done on master (very old master), that's not fatal. sql/sql_class.cc: one_shot sql/sql_class.h: one_shot sql/sql_lex.h: one_shot sql/sql_parse.cc: when SET ONE_SHOT is used, verify that it's only used for charset/collation vars; otherwise refuse. sql/sql_yacc.yy: ONE_SHOT keyword in SET
-
- 01 Jun, 2004 1 commit
-
-
unknown authored
will disable warnings, --log-warnings will increment warning level by one, or the level can be given as an optional argument. Default level is 1. Changed aborted connection warning to be logged only if the level is > 1. sql/sql_class.h: Changed boolean into ulong. sql/sql_parse.cc: Changed aborted connection warning to be logged only if the level is > 1.
-
- 29 May, 2004 1 commit
-
-
unknown authored
-
- 24 May, 2004 2 commits
-
-
unknown authored
after Monty's review. - Item_param was rewritten. - it turns out that we can't convert string data to character set of connection on the fly, because they first should be written to the binary log. To support efficient conversion we need to rewrite prepared statements binlogging code first. include/my_global.h: Macro swap(a, b, c) was renamed to resolve name conflict with String::swap() method. include/my_sys.h: Added declaration of escape_string_for_mysql() include/mysql_com.h: Removed and moved back: a macro which is visible to libmysql user but has sence only in prepared statement protocol implementation. isam/_search.c: swap -> swap_variables isam/test2.c: swap -> swap_variables libmysql/libmysql.c: - sub_escape_string moved to mysys/charset.c to be visible in sql/ - few cleanups myisam/mi_test2.c: swap -> swap_variables mysys/charset.c: sub_escape_string was moved from libmysql.c to be able to use it in sql/ code. mysys/my_chsize.c: rename: swap -> swap_variables mysys/my_compress.c: swap -> swap_variables mysys/my_handler.c: swap -> swap_variables sql/field.cc: Field::store_time refactored to use TIME_to_string function from time.cc sql/item.cc: New implementation of Item_param class: added support for character sets conversion. sql/item.h: Item_param: - 'state' member introduced instead of many boolean variables. - put ltime, int_value and real_value into union to save space. - remove unimplemented members - set_value renamed to set_str sql/item_timefunc.cc: Refactored to use functions from time.cc sql/lock.cc: rename: swap -> swap_variables sql/mysql_priv.h: - added declarations for TIME_to_ulonglong_*, TIME_to_string functions - const specifiers for make_date, make_time, make_datetime arguments sql/opt_range.cc: rename: swap -> swap_variables sql/protocol.cc: - added character set conversion support to binary protocol. - Protocol::convert changed to point at shared buffer in THD. This lets us use one convert buffer for binary and simple protocol. The same buffer is used for client->server conversions in prepared statements code. - string conversion code refactored to Protocol::store_string_aux function. - few more comments sql/protocol.h: - Protocol::convert now points at THD::convert_buffer: we want to share one buffer between all protocol implementations. sql/sql_class.cc: - implementation of THD::convert_string using THD::convert_buffer (conversion of strings allocated in the system heap). sql/sql_class.h: - THD::convert_buffer is shared between THD and network Protocols and used for character set conversion of strings. - new function to convert String object from one charset to another using THD::convert_buffer sql/sql_insert.cc: A little fix in a comment. sql/sql_parse.cc: Shrink convert buffer in the end of each statement. sql/sql_prepare.cc: Many changes: - static specifier for set_param_* family of functions. - FIELD_TYPE -> MYSQL_TYPE - added set_param_binary as handler for BLOB types. - added character set support - added support for param typecode in mysql_stmt_get_longdata (mysql_stmt_send_long_data handler) - changes in Item_param deployed - few cleanups sql/sql_select.cc: rename: swap -> swap_variables sql/sql_string.cc: - String::append rewritten to support character set conversion for single-byte encodings. - added String::swap method to efficiently exchange two string objects. sql/sql_string.h: Declraration for String::swap(). sql/time.cc: - function TIME_to_string to convert TIME to String in default MySQL format - family of functions TIME_to_ulonglong_* tests/client_test.c: Test for support for character set conversions in prepared statements (binary and text data).
-
unknown authored
Fixed the problem of previous patch with replication, More post-review fixes sql/sql_parse.cc: Added support for PREPARE stmt1 FROM @var sql/sql_prepare.cc: Added support for PREPARE stmt1 FROM @var, Fixed the problem of previous patch with replication Post-review fixes.
-
- 21 May, 2004 2 commits
-
-
unknown authored
to make list of parameters in mysql_alter_table shorted to avoid warning in MSVC (windows) building sql/mysql_priv.h: Introduced parameter object "ALTER_INFO" for mysql_alter_table - changed declaration of mysql_alter_table - changed declaration of mysql_drop_index (replaced List<Alter_drop> by ALTER_INFO) sql/sql_lex.h: Introduced parameter object "ALTER_INFO" for mysql_alter_table - declared struct ALTER_INFO - added ALTER_INFO alter_info; into LEX - removed fields which were added into ALTER_INFO from LEX sql/sql_parse.cc: Introduced parameter object "ALTER_INFO" for mysql_alter_table - changed invotaions of mysql_alter_table - replaced cleaning fields in SQLCOM_OPTIMIZE by ALTER_INFO::reset - changed invocation of mysql_drop_index (replaced lex->drop_list by &lex->alter_info) - changed definition of mysql_create_index and mysql_drop_index to use ALTER_INFO sql/sql_table.cc: Introduced parameter object "ALTER_INFO" for mysql_alter_table - changed definition of mysql_alter_table sql/sql_yacc.yy: Introduced parameter object "ALTER_INFO" for mysql_alter_table - replaced using of removed from LEX fields my fields of LEX::alter_info
-
unknown authored
mysql-test/r/ps.result: Added tests for PREPARE stmt1 FROM @var syntax mysql-test/t/ps.test: Added tests for PREPARE stmt1 FROM @var syntax mysys/my_error.c: Added support for "%.*s" format sql/item.cc: Removed one redundant Item_param::set_value function sql/item.h: Removed one redundant Item_param::set_value function sql/mysqld.cc: Reformmated the code sql/share/czech/errmsg.txt: Changed ER_UNKNOWN_STMT_HANDLER format string sql/share/dutch/errmsg.txt: Changed ER_UNKNOWN_STMT_HANDLER format string sql/share/english/errmsg.txt: Changed ER_UNKNOWN_STMT_HANDLER format string sql/share/estonian/errmsg.txt: Changed ER_UNKNOWN_STMT_HANDLER format string sql/share/french/errmsg.txt: Changed ER_UNKNOWN_STMT_HANDLER format string sql/share/german/errmsg.txt: Changed ER_UNKNOWN_STMT_HANDLER format string sql/share/greek/errmsg.txt: Changed ER_UNKNOWN_STMT_HANDLER format string sql/share/hungarian/errmsg.txt: Changed ER_UNKNOWN_STMT_HANDLER format string sql/share/italian/errmsg.txt: Changed ER_UNKNOWN_STMT_HANDLER format string sql/share/japanese/errmsg.txt: Changed ER_UNKNOWN_STMT_HANDLER format string sql/share/korean/errmsg.txt: Changed ER_UNKNOWN_STMT_HANDLER format string sql/share/norwegian-ny/errmsg.txt: Changed ER_UNKNOWN_STMT_HANDLER format string sql/share/norwegian/errmsg.txt: Changed ER_UNKNOWN_STMT_HANDLER format string sql/share/polish/errmsg.txt: Changed ER_UNKNOWN_STMT_HANDLER format string sql/share/portuguese/errmsg.txt: Changed ER_UNKNOWN_STMT_HANDLER format string sql/share/romanian/errmsg.txt: Changed ER_UNKNOWN_STMT_HANDLER format string sql/share/russian/errmsg.txt: Changed ER_UNKNOWN_STMT_HANDLER format string sql/share/slovak/errmsg.txt: Changed ER_UNKNOWN_STMT_HANDLER format string sql/share/spanish/errmsg.txt: Changed ER_UNKNOWN_STMT_HANDLER format string sql/share/swedish/errmsg.txt: Changed ER_UNKNOWN_STMT_HANDLER format string sql/share/ukrainian/errmsg.txt: Changed ER_UNKNOWN_STMT_HANDLER format string sql/sql_class.h: SQL Prepared statements now can't be used by binary protocol commands sql/sql_lex.h: Added support for PREPARE stmt1 FROM @var syntax. sql/sql_parse.cc: Added support for PREPARE stmt1 FROM @var syntax. sql/sql_prepare.cc: Code cleanup sql/sql_yacc.yy: Added support for PREPARE stmt1 FROM @var syntax.
-
- 18 May, 2004 1 commit
-
-
unknown authored
-