summaryrefslogtreecommitdiff
path: root/sql/structs.h
Commit message (Collapse)AuthorAgeFilesLines
* Merge branch '5.5' into 10.0Sergei Golubchik2015-03-061-0/+1
|\
| * MDEV-6838: Using too big key for internal temp tablesVicențiu Ciorbaru2015-02-281-0/+1
| | | | | | | | | | | | | | | | | | | | | | This bug manifests due to wrong computation and evaluation of keyinfo->key_length. The issues were: * Using table->file->max_key_length() as an absolute value that must not be reached for a key, while it represents the maximum number of bytes possible for a table key. * Incorrectly computing the keyinfo->key_length size during KEY_PART_INFO creation. The metadata information regarding the key such the field length (for strings) was added twice.
* | 10.0-base merge (roles)Sergei Golubchik2013-10-291-0/+8
|\ \
| * | support DEFINER=role and DEFINER=current_roleSergei Golubchik2013-10-181-0/+8
| | |
* | | Temporary commit of 10.0-mergeMichael Widenius2013-03-261-4/+4
|/ /
* | Addressed all remaining issues from the review of the patchIgor Babaev2012-12-131-1/+1
| | | | | | | | | | | | | | | | | | | | | | that introduced engine independent persistent statistics. In particular: - added an enumeration type for possible values of the system variable use_stat_tables - renamed KEY::real_rec_per_key to KEY::actual_rec_per_key - optimized the collection of statistical data for any primary key defined only on one column.
* | Performed re-factoring and re-structuring of the code for mwl#248:Igor Babaev2012-07-261-36/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - Moved the definitions of the classes to store data from persistent statistical tables into statistics.h, leaving in other internal data structures only references to the corresponding objects. - Defined class Column_statistics_collected derived from the class Column_statistics. This is a helper class to collect statistics on columns. - Moved references to read statistics to TABLE SHARE, leaving the the reference to the collected statistics in TABLE. - Added a new clone method for the class Field allowing to clone fields attached to table shares. It was was used to create fields for min/max values in the memory of the table share. A lso: - Added procedures to allocate memory for statistical data in the table share memory and in table memory. Also: - Added a test case demonstrating how ANALYZE could work in parallel to collect statistics on different indexes of the same table. - Added a test two demonstrate how two connections working simultaneously could allocate memory for statistical data in the table share memory.
* | Changed the type of all double columns in the system statistical tablesIgor Babaev2012-06-251-5/+18
| | | | | | | | | | | | mysql.column_stat, mysql.table_stat for the type DECIMAL(12,4). When cached the values from these columns are multiplied by factor 10^5 and stored as ulong numbers now.
* | The pilot implementation of mwl#250: Use the statistics from persistentIgor Babaev2012-04-111-0/+14
| | | | | | | | statistical tables instead of the statistics provided by engine.
* | Merge maria-5.3-mwl248 -> 5.5 = maria-5.5-mwl248.Igor Babaev2012-03-191-0/+25
|\ \ | |/ |/|
| * The main patch for the MWL#248 back-ported from Igor Babaev2012-01-041-0/+25
| | | | | | | | lp:~igorb-seattle/mysql-server/mysql-azalea-wl4777.
* | Merge MWL #247 from mariadb 5.3 -> mariadb 5.5.Igor Babaev2012-03-021-0/+3
|\ \
| * \ Merged MWL#247 into the latest 5.3.Igor Babaev2011-12-311-0/+3
| |\ \ | | |/ | |/|
| | * Implementation of the MWL#247: Make the optimizer use extended keys.Igor Babaev2011-12-311-0/+3
| | | | | | | | | | | | | | | The main patch. .
| * | Merge with 5.2.Michael Widenius2011-12-111-2/+5
| |\ \ | | | | | | | | | | | | no_error handling for select (used by INSERT ... SELECT) still needs to be fixed, but I will do that in a separate commit
| | * \ Merge with MariaDB 5.1Michael Widenius2011-11-241-2/+5
| | |\ \
* | | \ \ 5.3->5.5 mergeSergei Golubchik2011-11-221-3/+6
|\ \ \ \ \ | |/ / / /
| * | | | BUG#882472: subselect4.test fails in current 5.3Sergey Petrunya2011-10-271-1/+1
| | |_|/ | |/| | | | | | | | | | | | | | | | | | | | | | - The problem was that the value of READ_RECORD::file was not updated when the underlying table was temporary and was converted from heap to myisam. Resolved by eliminating READ_RECORD::file, always use READ_RECORD::table->file
| * | | Allow one to block an account by using GRANT max_user_connections = -1Michael Widenius2011-09-261-3/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | One can set @@global.max_user_connections to -1 to block anyone, except SUPER user, to login. If max_user_connection is 0, one can't change it without a restart (needed to get user connections counting to work correctly) mysql-test/r/system_mysql_db.result: Changed max_user_connections to handle negative numbers. mysql-test/r/user_limits-2.result: New test case that one can't change max_user_connection if it was 0 mysql-test/r/user_limits.result: Fixed wrong error messages. mysql-test/r/variables.result: Store / restore max_user_connections (needed as there is now a --master.opt file that changes it) mysql-test/t/subselect_mat_cost-master.opt: Enable slow query log (as this test found some errors in slow query logging) mysql-test/t/user_limits-2.test: New test case that one can't change max_user_connection if it was 0 mysql-test/t/user_limits-master.opt: Set max_user_connections (as one can't change it if it was 0) mysql-test/t/user_limits.test: Test max_user_connections -1 mysql-test/t/variables-master.opt: Set max_user_connections (as one can't change it if it was 0) mysql-test/t/variables.test: Set/restore max_user_connections scripts/Makefile.am: Add a text message to mysql_fix_privilege_tables.sql that it's automaticly generated scripts/mysql_system_tables.sql: Change max_user_connections to signed scripts/mysql_system_tables_fix.sql: Change max_user_connections to signed sql/item_func.cc: Change SHOW_INT to be signed. (Needed for max_user_connections and it's probably a bug that it was not originally signed) sql/log.cc: Remove some code that was not needed (All these variables are reset at start of query) sql/mysql_priv.h: Made max_user_connections signed. Added max_user_connections_checking sql/mysqld.cc: Added max_user_connections_checking so that we know if max_user_connections was 0 at startup (Which means that we will not do connection counting for accounts that don't have user resource limits) Set thd->start_utime at same time as thr_create_utime. (Before start_utime could be < thr_create_utime which lead to wrong query counting) sql/set_var.cc: Don't allow one to change 'max_user_connections' if it was 0 at startup. sql/sql_acl.cc: Change user_connection counting to be negative. sql/sql_connect.cc: If max_user_connections is < 0 then only SUPER user can login. Fixed wrong variable names for error messages. Fixed wrong initial value for questions. Set thd->start_utime and thd->thr_create_utime at startup. Needed to get time_out_user_resource_limits() to work. sql/sql_show.cc: SHOW_INT is now negative sql/sql_yacc.yy: Support negative values for MAX_USER_CONNECTIONS sql/structs.h: Make user connect counting work with signed numbers.
* | | | mysql-5.5.18 mergeSergei Golubchik2011-11-031-2/+2
|\ \ \ \
| * \ \ \ Updated/added copyright headersKent Boortz2011-06-301-2/+2
| |\ \ \ \ | | | |_|/ | | |/| |
| | * | | Updated/added copyright headersKent Boortz2011-06-301-2/+5
| | |\ \ \
| | | * | | Updated/added copyright headersKent Boortz2011-06-301-2/+3
| | | | | |
| * | | | | WL#1054: Pluggable authentication supportGeorgi Kodinov2010-08-091-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Merged the implementation to a new base tree.
* | | | | | merge with 5.3Sergei Golubchik2011-10-191-2/+2
|\ \ \ \ \ \ | | |_|_|/ / | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | sql/sql_insert.cc: CREATE ... IF NOT EXISTS may do nothing, but it is still not a failure. don't forget to my_ok it. ****** CREATE ... IF NOT EXISTS may do nothing, but it is still not a failure. don't forget to my_ok it. sql/sql_table.cc: small cleanup ****** small cleanup
| * | | | | Merge with 5.2Michael Widenius2011-05-161-1/+2
| |\ \ \ \ \ | | | |_|_|/ | | |/| | |
| | * | | | small enhancement of the create table options feature:Sergei Golubchik2011-05-101-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | no unnecessary casting from void*, more type safety. typos fixed.
| * | | | | Backport of:Sergey Petrunya2011-01-141-1/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 3723 oystein.grovlen@sun.com 2009-11-23 Bug#46548 (addendum) Remove KEY::extra_length. It is not in use.
* | | | | | lots of post-merge changesSergei Golubchik2011-04-251-0/+1
| | | | | |
* | | | | | merge.Sergei Golubchik2010-11-251-2/+115
|\ \ \ \ \ \ | |/ / / / / | | | / / / | |_|/ / / |/| | | | | | | | | checkpoint. does not compile.
| * | | | MariaDB 5.2 -> MariaDB 5.3 merge Sergey Petrunya2010-06-261-1/+5
| |\ \ \ \ | | |/ / /
| | * | | MWL#43 CREATE TABLE options (by Sanja)Sergei Golubchik2010-04-081-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Docs/sp-imp-spec.txt: New sql_mode added. include/my_base.h: Flag in frm of create options. libmysqld/CMakeLists.txt: New files added. libmysqld/Makefile.am: New files added. mysql-test/r/events_bugs.result: New sql_mode added. mysql-test/r/information_schema.result: New sql_mode added. mysql-test/r/sp.result: New sql_mode added. mysql-test/r/system_mysql_db.result: New sql_mode added. mysql-test/suite/funcs_1/r/is_columns_mysql.result: New sql_mode added. mysql-test/suite/funcs_1/r/is_columns_mysql_embedded.result: New sql_mode added. mysql-test/t/events_bugs.test: New sql_mode added. mysql-test/t/sp.test: New sql_mode added. scripts/mysql_system_tables.sql: New sql_mode added. scripts/mysql_system_tables_fix.sql: New sql_mode added. sql/CMakeLists.txt: New files added. sql/Makefile.am: New files added. sql/event_db_repository.cc: New sql_mode added. sql/field.cc: Create options support added. sql/field.h: Create options support added. sql/ha_partition.cc: Create options support added. sql/handler.cc: Create options support added. sql/handler.h: Create options support added. sql/log_event.h: New sql_mode added. sql/mysql_priv.h: New sql_mode added. sql/mysqld.cc: New sql_mode added. sql/share/errmsg.txt: New error messages added. sql/sp.cc: New sql_mode added. sql/sp_head.cc: Create options support added. sql/sql_class.cc: Create options support added. Debug added. sql/sql_class.h: Create options support added. sql/sql_insert.cc: my_safe_a* moved to mysqld_priv.h sql/sql_lex.h: Create options support added. sql/sql_parse.cc: Create options support added. sql/sql_show.cc: Create options support added. sql/sql_table.cc: Create options support added. sql/sql_view.cc: New sql_mode added. sql/sql_yacc.yy: Create options support added. sql/structs.h: Create options support added. sql/table.cc: Create options support added. sql/table.h: Create options support added. sql/unireg.cc: Create options support added. storage/example/ha_example.cc: Create options example. storage/example/ha_example.h: Create options example. storage/pbxt/src/discover_xt.cc: Create options support added.
| | * | | pluggable auth with plugin examplesSergei Golubchik2010-03-291-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Makefile.am: add new API files to the check_abi rule, remove duplicates client/CMakeLists.txt: now a client can use dlopen too client/Makefile.am: be csh-friendly include/my_global.h: add dummy plugs for dlopen and co. for the code that needs them to work in static builds mysys/Makefile.am: be csh-friendly plugin/auth/dialog.c: typo fixed
| * | | | Merge MariaDB-5.2 -> MariaDB 5.3Sergey Petrunya2010-03-201-4/+10
| |\ \ \ \ | | |/ / /
| | * | | merge 5.1-> 5.2unknown2009-12-081-4/+10
| | |\ \ \ | | | |/ /
| | | * | A fix and a test case for Konstantin Osipov2009-11-031-4/+10
| | | |\ \ | | | | |/ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Bug#41756 "Strange error messages about locks from InnoDB". In JT_EQ_REF (join_read_key()) access method, don't try to unlock rows in the handler, unless certain that a) they were locked b) they are not used. Unlocking of rows is done by the logic of the nested join loop, and is unaware of the possible caching that the access method may have. This could lead to double unlocking, when a row was unlocked first after reading into the cache, and then when taken from cache, as well as to unlocking of rows which were actually used (but taken from cache). Delegate part of the unlocking logic to the access method, and in JT_EQ_REF count how many times a record was actually used in the join. Unlock it only if it's usage count is 0. Implemented review comments. mysql-test/r/innodb_lock_wait_timeout_1.result: Update results (Bug41756). mysql-test/t/innodb_lock_wait_timeout_1.test: Add a test case (Bug#41756). sql/item_subselect.cc: Complete struct READ_RECORD initialization with a new member to unlock records. sql/records.cc: Extend READ_RECORD API with a method to unlock read records. sql/sql_select.cc: In JT_EQ_REF (join_read_key()) access method, don't try to unlock rows in the handler, unless certain that a) they were locked b) they are not used. sql/sql_select.h: Add members to TABLE_REF to count TABLE_REF buffer usage count. sql/structs.h: Update declarations.
| | | | * A fix and a test case forKonstantin Osipov2009-11-031-4/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Bug#41756 "Strange error messages about locks from InnoDB". In JT_EQ_REF (join_read_key()) access method, don't try to unlock rows in the handler, unless certain that a) they were locked b) they are not used. Unlocking of rows is done by the logic of the nested join loop, and is unaware of the possible caching that the access method may have. This could lead to double unlocking, when a row was unlocked first after reading into the cache, and then when taken from cache, as well as to unlocking of rows which were actually used (but taken from cache). Delegate part of the unlocking logic to the access method, and in JT_EQ_REF count how many times a record was actually used in the join. Unlock it only if it's usage count is 0. Implemented review comments. mysql-test/r/bug41756.result: Add result file (Bug#41756) mysql-test/t/bug41756-master.opt: Use --innodb-locks-unsafe-for-binlog, as in 5.0 just using read_committed isolation is not sufficient to reproduce the bug. mysql-test/t/bug41756.test: Add a test file (Bug#41756) sql/item_subselect.cc: Complete struct READ_RECORD initialization with a new member to unlock records. sql/records.cc: Extend READ_RECORD API with a method to unlock read records. sql/sql_select.cc: In JT_EQ_REF (join_read_key()) access method, don't try to unlock rows in the handler, unless certain that a) they were locked b) they are not used. sql/sql_select.h: Add members to TABLE_REF to count TABLE_REF buffer usage count. sql/structs.h: Update declarations.
| | | | * Merge from Tim's 5.0.76-release tree to make 5.0.77 .Chad MILLER2009-01-211-1/+1
| | | | |\
| | | | | * Bug#41131 "Questions" fails to increment - ignores statements instead stored ↵Sergey Glukhov2008-12-291-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | procs(5.0 ver) Added global status variable 'Queries' which represents total amount of queries executed by server including statements executed by SPs. note: It's old behaviour of 'Questions' variable. mysql-test/r/status.result: test result mysql-test/t/status.test: test case sql/mysqld.cc: Added global status variable 'Queries' which represents total amount of queries executed by server including statements executed by SPs. note: It's old behaviour of 'Questions' variable. sql/sql_show.cc: Added global status variable 'Queries' which represents total amount of queries executed by server including statements executed by SPs. note: It's old behaviour of 'Questions' variable. sql/structs.h: Added global status variable 'Queries' which represents total amount of queries executed by server including statements executed by SPs. note: It's old behaviour of 'Questions' variable.
| | | | * | Merged from 5.0 (enterprise).Chad MILLER2008-12-171-1/+1
| | | | |\ \ | | | | | |/
| | | | | * Bug#24289 Status Variable "Questions" gets wrong values with Stored RoutinesKristofer Pettersson2008-10-091-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When running Stored Routines the Status Variable "Questions" was wrongly incremented. According to the manual it should contain the "number of statements that clients have sent to the server" Introduced a new status variable 'questions' to replace the query_id variable which currently corresponds badly with the number of statements sent by the client. The new behavior is ment to be backward compatible with 4.0 and at the same time work with new features in a similar way. This is a backport from 6.0 mysql-test/r/status2.result: Added test case mysql-test/t/status2.test: Added test case sql/mysqld.cc: Introduced a new status variable 'questions' to replace the query_id variable which currently corresponds badly with the number of statements sent by the client. sql/sql_class.h: Introduced a new status variable 'questions' to replace the query_id variable which currently corresponds badly with the number of statements sent by the client. sql/sql_parse.cc: To be backward compatible with 4.0 and at the same time extend the interpretation of the Question variable, it should be increased on all COM-commands but COM_STATISTICS, COM_PING, COM_STMT_PREPARE, COM_STMT_CLOSE and COM_STMT_RESET. Since COM_QUERY can process multiple statements, there has to be an extra increase there as well. sql/sql_show.cc: Removed deprecated SHOW_QUESTION status code. sql/structs.h: Removed deprecated SHOW_QUESTION status code.
| | | | * | Merge bk-internal.mysql.com:/home/bk/mysql-5.0unknown2007-12-101-0/+1
| | | | |\ \ | | | | | |/ | | | | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | into zippy.cornsilk.net:/home/cmiller/work/mysql/mysql-5.0-community CMakeLists.txt: Auto merged include/config-win.h: Auto merged include/my_sys.h: Auto merged libmysql/CMakeLists.txt: Auto merged myisam/mi_open.c: Auto merged mysql-test/r/information_schema.result: Auto merged mysql-test/r/information_schema_db.result: Auto merged mysql-test/r/symlink.result: Auto merged mysql-test/t/information_schema.test: Auto merged mysql-test/t/symlink.test: Auto merged mysys/my_symlink2.c: Auto merged sql/ha_myisam.cc: Auto merged sql/ha_ndbcluster.cc: Auto merged sql/item_cmpfunc.cc: Auto merged sql/item_func.cc: Auto merged sql/log_event.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/sp_head.cc: Auto merged sql/sql_base.cc: Auto merged sql/sql_class.cc: Auto merged sql/sql_class.h: Auto merged sql/sql_insert.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_table.cc: Auto merged sql/sql_view.cc: Auto merged sql/sql_yacc.yy: Auto merged sql/structs.h: Auto merged sql/table.h: Auto merged support-files/mysql.spec.sh: Auto merged win/configure.js: Auto merged Makefile.am: Manual merge. client/mysqlcheck.c: Manual merge. configure.in: Manual merge. mysql-test/r/mysqlcheck.result: Manual merge. mysql-test/t/mysqlcheck.test: Manual merge. sql/sql_delete.cc: Manual merge. sql/sql_update.cc: Manual merge.
| | | | | * Merge mysqldev@production.mysql.com:my/mysql-5.0-releaseunknown2007-07-021-0/+1
| | | | | |\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | into zippy.cornsilk.net:/home/cmiller/work/mysql/mysql-5.0-community BitKeeper/triggers/post-commit: Auto merged client/CMakeLists.txt: Auto merged extra/CMakeLists.txt: Auto merged libmysql/CMakeLists.txt: Auto merged libmysqld/Makefile.am: Auto merged myisam/CMakeLists.txt: Auto merged mysql-test/r/func_in.result: Auto merged mysql-test/r/information_schema_db.result: Auto merged mysql-test/t/func_in.test: Auto merged mysql-test/t/information_schema.test: Auto merged server-tools/instance-manager/CMakeLists.txt: Auto merged sql/Makefile.am: Auto merged sql/ha_archive.cc: Auto merged sql/ha_myisam.cc: Auto merged sql/ha_ndbcluster.cc: Auto merged sql/item_cmpfunc.cc: Auto merged sql/item_func.cc: Auto merged sql/lock.cc: Auto merged sql/log_event.cc: Auto merged sql/mysql_priv.h: Auto merged sql/mysqld.cc: Auto merged sql/slave.cc: Auto merged sql/sp_head.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_insert.cc: Auto merged sql/sql_lex.cc: Auto merged sql/sql_lex.h: Auto merged sql/sql_prepare.cc: Auto merged sql/sql_repl.cc: Auto merged sql/sql_show.cc: Auto merged sql/sql_table.cc: Auto merged sql/sql_update.cc: Auto merged sql/sql_view.cc: Auto merged sql/sql_yacc.yy: Auto merged sql/structs.h: Auto merged sql/table.h: Auto merged support-files/mysql.spec.sh: Auto merged win/Makefile.am: Auto merged win/README: Auto merged win/configure.js: Auto merged CMakeLists.txt: manual merge. configure.in: manual merge. mysql-test/r/information_schema.result: manual merge. sql/CMakeLists.txt: manual merge. sql/set_var.cc: manual merge. sql/sql_parse.cc: manual merge. sql/sql_select.cc: manual merge.
| | | | | | * Bug#24822: Patch: uptime_since_flush_statusunknown2007-01-181-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Provide the number of seconds since flush as a new status variable named "Uptime_since_flush_status". --- Override the post-flush value, as a second could pass between the two statements. mysql-test/r/information_schema.result: Test new status variable. --- Override the post-flush value, as a second could pass between the two statements. mysql-test/t/information_schema.test: Test new status variable. --- Override the post-flush value, as a second could pass between the two statements. sql/mysql_priv.h: Add variable to hold previous flush time. sql/mysqld.cc: Add variable to hold previous flush time. Insert name for referring to it, and initialize the value. sql/sql_show.cc: Yield value of elapsed time since flush when asked. sql/structs.h: Add new show-flush-time to SHOW types enumeration.
| * | | | | | Backport of subquery optimizations to 5.3.Sergey Petrunya2010-01-171-0/+21
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | There are still test failures because of: - Wrong query results in outer join + semi join - EXPLAIN output differences
| * | | | | | Backport into MariaDB-5.2 the following:Sergey Petrunya2009-12-151-1/+2
| |/ / / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | WL#2474 "Multi Range Read: Change the default MRR implementation to implement new MRR interface" WL#2475 "Batched range read functions for MyISAM/InnoDb" "Index condition pushdown for MyISAM/InnoDB" Igor's fix from sp1r-igor@olga.mysql.com-20080330055902-07614: There could be observed the following problems: 1. EXPLAIN did not mention pushdown conditions from on expressions in the 'extra' column. As a result if a query had no where conditions pushed down to a table, but had on conditions pushed to this table the 'extra' column in the EXPLAIN for the table missed 'using where'. 2. Conditions for ref access were not eliminated from on expressions though such conditions were eliminated from the where condition.
| * | | | | This is based on the userstatv2 patch from Percona and OurDelta.Michael Widenius2009-10-191-0/+108
| |/ / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The original code comes, as far as I know, from Google (Mark Callaghan's team) with additional work from Percona, Ourdelta and Weldon Whipple. This code provides the same functionallity, but with a lot of changes to make it faster and better fit the MariaDB infrastucture. Added new status variables: - Com_show_client_statistics, Com_show_index_statistics, Com_show_table_statistics, Com_show_user_statistics - Access_denied_errors, Busy_time (clock time), Binlog_bytes_written, Cpu_time, Empty_queries, Rows_sent, Rows_read Added new variable / startup option 'userstat' to control if user statistics should be enabled or not Added my_getcputime(); Returns cpu time used by this thread. New FLUSH commands: - FLUSH SLOW QUERY LOG - FLUSH TABLE_STATISTICS - FLUSH INDEX_STATISTICS - FLUSH USER_STATISTICS - FLUSH CLIENT_STATISTICS New SHOW commands: - SHOW CLIENT_STATISTICS - SHOW USER_STATISTICS - SHOW TABLE_STATISTICS - SHOW INDEX_STATISTICS New Information schemas: - CLIENT_STATISTICS - USER_STATISTICS - INDEX_STATISTICS - TABLE_STATISTICS Added support for all new flush commands to mysqladmin Added handler::ha_... wrappers for all handler read calls to do statistics counting - Changed all code to use new ha_... calls - Count number of read rows, changed rows and rows read trough an index Added counting of number of bytes sent to binary log (status variable Binlog_bytes_written) Added counting of access denied errors (status variable Access_denied_erors) Bugs fixed: - Fixed bug in add_to_status() and add_diff_to_status() where longlong variables where threated as long - CLOCK_GETTIME was not propely working on Linuxm client/mysqladmin.cc: Added support for all new flush commmands and some common combinations: flush-slow-log flush-table-statistics flush-index-statistics flush-user-statistics flush-client-statistics flush-all-status flush-all-statistics configure.in: Added checking if clock_gettime needs the librt. (Fixes Bug #37639 clock_gettime is never used/enabled in Linux/Unix) include/my_sys.h: Added my_getcputime() include/mysql_com.h: Added LIST_PROCESS_HOST_LEN & new REFRESH target defines mysql-test/r/information_schema.result: New information schema tables added mysql-test/r/information_schema_all_engines.result: New information schema tables added mysql-test/r/information_schema_db.result: New information schema tables added mysql-test/r/log_slow.result: Added testing that flosh slow query logs is accepted mysql-test/r/status_user.result: Basic testing of user, client, table and index statistics mysql-test/t/log_slow.test: Added testing that flosh slow query logs is accepted mysql-test/t/status_user-master.opt: Ensure that we get a fresh restart before running status_user.test mysql-test/t/status_user.test: Basic testing of user, client, table and index statistics mysys/my_getsystime.c: Added my_getcputime() Returns cpu time used by this thread. sql/authors.h: Updated authors to have core and original MySQL developers first. sql/event_data_objects.cc: Updated call to mysql_reset_thd_for_next_command() sql/event_db_repository.cc: Changed to use new ha_... calls sql/filesort.cc: Changed to use new ha_... calls sql/ha_partition.cc: Changed to use new ha_... calls Fixed comment syntax sql/handler.cc: Changed to use new ha_... calls Reset table statistics Added code to update global table and index status Added counting of rows changed sql/handler.h: Added table and index statistics variables Added function reset_statistics() Added handler::ha_... wrappers for all handler read calls to do statistics counting Protected all normal read calls to ensure we use the new calls in the server. Made ha_partition a friend class so that partition code can call the old read functions sql/item_subselect.cc: Changed to use new ha_... calls sql/lex.h: Added keywords for new information schema tables and flush commands sql/log.cc: Added flush_slow_log() Added counting of number of bytes sent to binary log Removed not needed test of thd (It's used before, so it's safe to use) Added THD object to MYSQL_BIN_LOG::write_cache() to simplify statistics counting sql/log.h: Added new parameter to write_cache() Added flush_slow_log() functions. sql/log_event.cc: Updated call to mysql_reset_thd_for_next_command() Changed to use new ha_... calls sql/log_event_old.cc: Updated call to mysql_reset_thd_for_next_command() Changed to use new ha_... calls sql/mysql_priv.h: Updated call to mysql_reset_thd_for_next_command() Added new statistics functions and variables needed by these. sql/mysqld.cc: Added new statistics variables and structures to handle these Added new status variables: - Com_show_client_statistics, Com_show_index_statistics, Com_show_table_statistics, Com_show_user_statistics - Access_denied_errors, Busy_time (clock time), Binlog_bytes_written, Cpu_time, Empty_queries, Rows_set, Rows_read Added new option 'userstat' to control if user statistics should be enabled or not sql/opt_range.cc: Changed to use new ha_... calls sql/opt_range.h: Changed to use new ha_... calls sql/opt_sum.cc: Changed to use new ha_... calls sql/records.cc: Changed to use new ha_... calls sql/set_var.cc: Added variable 'userstat' sql/sp.cc: Changed to use new ha_... calls sql/sql_acl.cc: Changed to use new ha_... calls Added counting of access_denied_errors sql/sql_base.cc: Added call to statistics functions sql/sql_class.cc: Added usage of org_status_var, to store status variables at start of command Added functions THD::update_stats(), THD::update_all_stats() Fixed bug in add_to_status() and add_diff_to_status() where longlong variables where threated as long sql/sql_class.h: Added new status variables to status_var Moved variables that was not ulong in status_var last. Added variables to THD for storing temporary values during statistics counting sql/sql_connect.cc: Variables and functions to calculate user and client statistics Added counting of access_denied_errors and lost_connections sql/sql_cursor.cc: Changed to use new ha_... calls sql/sql_handler.cc: Changed to use new ha_... calls sql/sql_help.cc: Changed to use new ha_... calls sql/sql_insert.cc: Changed to use new ha_... calls sql/sql_lex.h: Added SQLCOM_SHOW_USER_STATS, SQLCOM_SHOW_TABLE_STATS, SQLCOM_SHOW_INDEX_STATS, SQLCOM_SHOW_CLIENT_STATS sql/sql_parse.cc: Added handling of: - SHOW CLIENT_STATISTICS - SHOW USER_STATISTICS - SHOW TABLE_STATISTICS - SHOW INDEX_STATISTICS Added handling of new FLUSH commands: - FLUSH SLOW QUERY LOGS - FLUSH TABLE_STATISTICS - FLUSH INDEX_STATISTICS - FLUSH USER_STATISTICS - FLUSH CLIENT_STATISTICS Added THD parameter to mysql_reset_thd_for_next_command() Added initialization and calls to user statistics functions Added increment of statistics variables empty_queries, rows_sent and access_denied_errors. Added counting of cpu time per query sql/sql_plugin.cc: Changed to use new ha_... calls sql/sql_prepare.cc: Updated call to mysql_reset_thd_for_next_command() sql/sql_select.cc: Changed to use new ha_... calls Indentation changes sql/sql_servers.cc: Changed to use new ha_... calls sql/sql_show.cc: Added counting of access denied errors Added function for new information schema tables: - CLIENT_STATISTICS - USER_STATISTICS - INDEX_STATISTICS - TABLE_STATISTICS Changed to use new ha_... calls sql/sql_table.cc: Changed to use new ha_... calls sql/sql_udf.cc: Changed to use new ha_... calls sql/sql_update.cc: Changed to use new ha_... calls sql/sql_yacc.yy: Add new show and flush commands sql/structs.h: Add name_length to KEY to avoid some strlen Added cache_name to KEY for fast storage of keyvalue in cache Added structs USER_STATS, TABLE_STATS, INDEX_STATS Added function prototypes for statistics functions sql/table.cc: Store db+table+index name into keyinfo->cache_name sql/table.h: Added new information schema tables sql/tztime.cc: Changed to use new ha_... calls
* | | | | WL#5030: Split and remove mysql_priv.hMats Kindahl2010-03-311-0/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch: - Moves all definitions from the mysql_priv.h file into header files for the component where the variable is defined - Creates header files if the component lacks one - Eliminates all include directives from mysql_priv.h - Eliminates all circular include cycles - Rename time.cc to sql_time.cc - Rename mysql_priv.h to sql_priv.h
* | | | | Patch for WL#3736: Extended Table, Column and Index Comments.Alexander Nozdrin2010-02-201-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The task is to (a) add a comment on indexes and (b) increase the maximum length of column, table and the new index comments. The patch committed on behalf of Yoshinori Matsunobu (Yoshinori.Matsunobu@Sun.COM).
* | | | | WL#4738 streamline/simplify @@variable creation processSergei Golubchik2009-12-221-2/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Bug#16565 mysqld --help --verbose does not order variablesBug#20413 sql_slave_skip_counter is not shown in show variables Bug#20415 Output of mysqld --help --verbose is incomplete Bug#25430 variable not found in SELECT @@global.ft_max_word_len; Bug#32902 plugin variables don't know their names Bug#34599 MySQLD Option and Variable Reference need to be consistent in formatting! Bug#34829 No default value for variable and setting default does not raise error Bug#34834 ? Is accepted as a valid sql mode Bug#34878 Few variables have default value according to documentation but error occurs Bug#34883 ft_boolean_syntax cant be assigned from user variable to global var. Bug#37187 `INFORMATION_SCHEMA`.`GLOBAL_VARIABLES`: inconsistent status Bug#40988 log_output_basic.test succeeded though syntactically false. Bug#41010 enum-style command-line options are not honoured (maria.maria-recover fails) Bug#42103 Setting key_buffer_size to a negative value may lead to very large allocations Bug#44691 Some plugins configured as MYSQL_PLUGIN_MANDATORY in can be disabled Bug#44797 plugins w/o command-line options have no disabling option in --help Bug#46314 string system variables don't support expressions Bug#46470 sys_vars.max_binlog_cache_size_basic_32 is broken Bug#46586 When using the plugin interface the type "set" for options caused a crash. Bug#47212 Crash in DBUG_PRINT in mysqltest.cc when trying to print octal number Bug#48758 mysqltest crashes on sys_vars.collation_server_basic in gcov builds Bug#49417 some complaints about mysqld --help --verbose output Bug#49540 DEFAULT value of binlog_format isn't the default value Bug#49640 ambiguous option '--skip-skip-myisam' (double skip prefix) Bug#49644 init_connect and \0 Bug#49645 init_slave and multi-byte characters Bug#49646 mysql --show-warnings crashes when server dies CMakeLists.txt: Bug#44691 Some plugins configured as MYSQL_PLUGIN_MANDATORY in can be disabled client/mysql.cc: don't crash with --show-warnings when mysqld dies config/ac-macros/plugins.m4: Bug#44691 Some plugins configured as MYSQL_PLUGIN_MANDATORY in can be disabled include/my_getopt.h: comments include/my_pthread.h: fix double #define mysql-test/mysql-test-run.pl: run sys_vars suite by default properly recognize envirinment variables (e.g. MTR_MAX_SAVE_CORE) set to 0 escape gdb command line arguments mysql-test/suite/sys_vars/r/rpl_init_slave_func.result: init_slave+utf8 bug mysql-test/suite/sys_vars/t/rpl_init_slave_func.test: init_slave+utf8 bug mysys/my_getopt.c: Bug#34599 MySQLD Option and Variable Reference need to be consistent in formatting! Bug#46586 When using the plugin interface the type "set" for options caused a crash. Bug#49640 ambiguous option '--skip-skip-myisam' (double skip prefix) mysys/typelib.c: support for flagset sql/ha_ndbcluster.cc: backport from telco tree sql/item_func.cc: Bug#49644 init_connect and \0 Bug#49645 init_slave and multi-byte characters sql/sql_builtin.cc.in: Bug#44691 Some plugins configured as MYSQL_PLUGIN_MANDATORY in can be disabled sql/sql_plugin.cc: Bug#44691 Some plugins configured as MYSQL_PLUGIN_MANDATORY in can be disabled Bug#32902 plugin variables don't know their names Bug#44797 plugins w/o command-line options have no disabling option in --help sql/sys_vars.cc: all server variables are defined here storage/myisam/ft_parser.c: remove unnecessary updates of param->quot storage/myisam/ha_myisam.cc: myisam_* variables belong here strings/my_vsnprintf.c: %o and %llx unittest/mysys/my_vsnprintf-t.c: %o and %llx tests vio/viosocket.c: bugfix: fix @@wait_timeout to work with socket timeouts (vs. alarm thread)