Commit graph

17413 commits

Author SHA1 Message Date
Staale Smedseng
e5ae4e2392 A fix for Bug#22891 "session level max_allowed_packet can be
set but is ignored".
                                  
This patch makes @@session.max_allowed_packed and
@@session.net_buffer_length read-only as suggested in the bug
report. The user will have to use SET GLOBAL (and reconnect)
to alter the session values of these variables.
                            
The error string ER_VARIABLE_IS_READONLY is introduced.
                            
Tests are modified accordingly.


sql/set_var.cc:
  The class sys_var_thd_ulong_session_readonly is introduced as
  a specialization of sys_var_thd_ulong implementing a read-only
  session variable. The class overrides check() and
  check_default() to achieve the read-only property for the
  session part of the variable.
sql/set_var.h:
  The class sys_var_thd_ulong_session_readonly is introduced as
  a specialization of sys_var_thd_ulong implementing a read-only
  session variable. The class overrides check() and
  check_default() to achieve the read-only property for the
  session part of the variable.
sql/share/errmsg.txt:
  New error ER_VARIABLE_IS_READONLY.
2008-11-20 08:51:48 +01:00
Chad MILLER
c720394e70 Merge fix for bug 39178. 2008-11-18 12:04:36 -05:00
Chad MILLER
480046c52e Bug#39178: non-RSA keys in connection to a RSA-keyed yaSSL-using server \
using crashes server

When the server is configured to use a RSA key, and when the client sends
a cipher-suite list that contains a non-RSA key as acceptable, the server 
would try to process that key even though it was impossible.

Now, yaSSL sets its own acceptable-cipher list according to what kind of
key the server is started with, and will never explore and try to pair 
impossible combinations.

This involves a partial import of the current YaSSL tree, not the whole
thing, so as to try to avoid introducing new bugs.

(Updated to avoid many whitespace changes and make diff smaller.)
2008-11-18 11:45:44 -05:00
Sergey Vojtovich
ca1ad1c552 Merge. 2008-11-18 15:38:28 +04:00
Sergey Vojtovich
780186f962 Merge. 2008-11-18 15:10:52 +04:00
Alexey Botchkov
3e02f95574 merging 2008-11-18 13:52:03 +04:00
Alexey Botchkov
1199dfcbfa Bug#34517 SHOW GLOBAL STATUS does not work properly in embedded server.
GLOBAL STATUS is calculated by studying the list of threads. In the
        embedded server threads were not linked to the internal list, so the
        calculation always returns 0. Fixed by 'linking' the embedded-server
        threads to the same list

per-file comments:
  libmysqld/lib_sql.cc
Bug#34517 SHOW GLOBAL STATUS does not work properly in embedded server.
    Add newly created 'threads' to the internal thread list.
    Remove them from the list as they're freed.

  mysql-test/r/information_schema.result
Bug#34517 SHOW GLOBAL STATUS does not work properly in embedded server.
    test result

  mysql-test/t/information_schema.test
Bug#34517 SHOW GLOBAL STATUS does not work properly in embedded server.
    test case added
2008-11-17 20:06:03 +04:00
Alexey Botchkov
ed77f02a92 merging 2008-11-17 19:43:10 +04:00
Alexey Botchkov
88a8863627 Bug#31616 div_precision_increment description looks wrong
Item_func_div didn't calculate the precision of the result properly.
  The result of 5/0.0001 is 5000 so we have to add decimals of the divisor
  to the planned precision.

per-file comments:
  mysql-test/r/type_newdecimal.result
Bug#31616 div_precision_increment description looks wrong
    test result fixed

  mysql-test/t/type_newdecimal.test
Bug#31616 div_precision_increment description looks wrong
    test case

  sql/item_func.cc
Bug#31616 div_precision_increment description looks wrong
    precision must be increased with args[1]->decimals parameter
2008-11-17 19:41:09 +04:00
Mattias Jonsson
1db7d8f6cb Bug#40595: Non-matching rows not released with READ-COMMITTED on tables
with partitions

Pre push fix, optimized replace_regex, to cut 2 seconds
from test time.
2008-11-14 23:51:17 +01:00
Ramil Kalimullin
cba2743336 Auto-merge 2008-11-14 13:48:01 +04:00
Ramil Kalimullin
dbc062bf2c Test case for bug #34774: key prefix on text field in federated
tables can cause server to crash!

The bug will be fixed by patch for #34779: "crash in checksum table
on federated tables with blobs containing nulls"

Only a test case commited.


mysql-test/r/federated.result:
  Test case for bug #34774: key prefix on text field in federated 
  tables can cause server to crash!
    - test result.
mysql-test/t/federated.test:
  Test case for bug #34774: key prefix on text field in federated 
  tables can cause server to crash!
    - test case.
2008-11-14 11:42:29 +04:00
Ramil Kalimullin
e3de8d361e Fix for bug#37527: mysqlcheck fails to report entire database
when InnoDB frm file corruption

Problem: mysqlcheck runs 'SHOW FULL TABLE' queries to get table lists.
The query may fail for some reasons (e.g. null .frm file) then
mysqlcheck doesn't process the database tables.

Fix: try to run 'SHOW TABLES' if 'SHOW FULL TABLES' failed.


client/mysqlcheck.c:
  Fix for bug#37527: mysqlcheck fails to report entire database 
  when InnoDB frm file corruption
    - run "SHOW TABLES" query if "SHOW /*!50002 FULL*/ TABLES" failed;
    - print error info if both failed.
mysql-test/r/mysqlcheck.result:
  Fix for bug#37527: mysqlcheck fails to report entire database 
  when InnoDB frm file corruption
    - test result.
mysql-test/t/mysqlcheck.test:
  Fix for bug#37527: mysqlcheck fails to report entire database 
  when InnoDB frm file corruption
    - test case.
2008-11-14 11:40:46 +04:00
Sergey Glukhov
ba453779b5 5.0-bugteam->5.1-bugteam automerge(bug#39541) 2008-11-13 17:09:22 +04:00
Sergey Glukhov
c049fc6bd6 Bug#39541 CHECK TABLE on information_schema myisam tables produces error
issue 'The storage engine for the table doesn't support check' note for I_S tables


mysql-test/r/mysqlcheck.result:
  test result
mysql-test/t/mysqlcheck.test:
  test case
sql/sql_table.cc:
  issue 'The storage engine for the table doesn't support check' note for I_S tables
2008-11-13 17:06:48 +04:00
Sergey Glukhov
fc27d0380a Bug#38909 CREATE_OPTIONS in information_schema produces wrong results
table->partition_info is unitialized when we open frm file only.
The fix is check share->partition_info_len which is set on
frm opening stage.


mysql-test/r/information_schema_part.result:
  test result
mysql-test/t/information_schema_part.test:
  test case
sql/sql_show.cc:
  table->partition_info is unitialized when we open frm file only.
  The fix is check share->partition_info_len which is set on
  frm opening stage.
2008-11-13 16:11:51 +04:00
Sergey Glukhov
53b3052352 Bug#39955 SELECT on INFORMATION_SCHEMA.GLOBAL_VARIABLES takes too long
VARIABLE_VALUE field is decreased to 1024 symbols.
(affected I_S tables: GLOBAL_VARIABLES, SESSION_VARIABLES,
 GLOBAL_STATUS, SESSION_STATUS).
The only variable which can be longer than 1024 is
init_connect. The variable will be truncated with warning.
Additional fix:
Added where condition filter which speed up queries which
have where condition with expressions which use VARIABLE_NAME
field.


mysql-test/r/information_schema.result:
  test result
mysql-test/r/show_check.result:
  result fix
mysql-test/suite/funcs_1/r/is_columns_is.result:
  result fix
mysql-test/t/information_schema.test:
  test case
sql/sql_show.cc:
  VARIABLE_VALUE field is decreased to 1024 symbols.
  (affected I_S tables: GLOBAL_VARIABLES, SESSION_VARIABLES,
   GLOBAL_STATUS, SESSION_STATUS).
  The only variable which can be longer than 1024 is
  init_connect. The variable will be truncated with warning.
  Additional fix:
  Added where condition filter which speed up queries which
  have where condition with expressions which use VARIABLE_NAME
  field.
2008-11-13 16:09:11 +04:00
Sergey Glukhov
0dff72726b Bug#35789 wrong datatypes for collation and charset columns in EVENTS, ROUTINES, TRIGGERS
changed 'charset', 'collation' field length from 64 to MY_CS_NAME_SIZE(32)
in tables:
SCHEMATA, TABLES, COLUMNS, CHARACTER_SETS,
COLLATIONS, COLLATION_CHARACTER_SET_APPLICABILITY


mysql-test/r/create.result:
  result fix
mysql-test/r/information_schema.result:
  result fix
mysql-test/r/show_check.result:
  result fix
mysql-test/suite/funcs_1/r/is_character_sets.result:
  result fix
mysql-test/suite/funcs_1/r/is_collation_character_set_applicability.result:
  result fix
mysql-test/suite/funcs_1/r/is_collations.result:
  result fix
mysql-test/suite/funcs_1/r/is_columns.result:
  result fix
mysql-test/suite/funcs_1/r/is_columns_is.result:
  result fix
mysql-test/suite/funcs_1/r/is_routines.result:
  result fix
mysql-test/suite/funcs_1/r/is_schemata.result:
  result fix
mysql-test/suite/funcs_1/r/is_tables.result:
  result fix
sql/sql_show.cc:
  changed 'charset', 'collation' field length from 64 to MY_CS_NAME_SIZE(32)
  in tables:
  SCHEMATA, TABLES, COLUMNS, CHARACTER_SETS,
  COLLATIONS, COLLATION_CHARACTER_SET_APPLICABILITY
  additional fix: ROUTINES.SQL_MODE is changed to be VARCHAR(addon for Bug#29153)
2008-11-13 13:50:20 +04:00
Sergey Vojtovich
ab9ecae47b BUG#38842 - Fix for 25951 seems incorrect
With fix for bug 25951 index hints are ignored for fulltext
searches, as handling of fulltext indexes is different from
handling regular indexes. Meaning it is not possible to
implement true index hints support for fulltext indexes within
the scope of current fulltext architecture.

The problem is that prior to fix for bug 25951, some useful
index hints still could be given for boolean mode searches.

This patch implements special index hints support for fulltext
indexes with the following characteristics:
- all index hints are still ignored for NLQ mode searches -
  it cannot work without an index;
- for 5.1 and up index hints FOR ORDER BY and FOR GROUP BY are
  still ignored for fulltext indexes;
- boolean mode searches honor USE/FORCE/IGNORE INDEX hints;
- as opposed to index hints for regular indexes, index hints
  for fulltext BOOLEAN mode searches affect the usage of the
  index for the whole query.

mysql-test/r/fulltext.result:
  A test case for BUG#38842.
mysql-test/t/fulltext.test:
  A test case for BUG#38842.
sql/item_func.cc:
  For boolean mode searches, which can work without fulltext
  index, use keys_in_use_for_query bitmap instead of keys_in_use.
  
  The effect is that boolean mode searches now honor index hints.
2008-11-11 13:10:51 +04:00
Mattias Jonsson
a5ec6953e1 Bug#40595: Non-matching rows not released with READ-COMMITTED
on tables with partitions

Problem was that the handler function try_semi_consistent_read
was not propagated to the innodb handler.

Solution was to implement that function in the partitioning
handler.

mysql-test/r/partition_innodb.result:
  Bug#40595: Non-matching rows not released with READ-COMMITTED
  on tables with partitions
  
  Updated test result.
mysql-test/t/partition_innodb.test:
  Bug#40595: Non-matching rows not released with READ-COMMITTED
  on tables with partitions
  
  Added test case for bug#40595.
  
  Note: the replace_regex is taking long time. I have not found
  any better regex (it takes time using 'sed' too).
sql/ha_partition.cc:
  Bug#40595: Non-matching rows not released with READ-COMMITTED
  on tables with partitions
  
  Added function to the partitioning handler for handling
  semi consistent reads (unlock_row was already implemented,
  and this is needed for unlock_row to work properly in innodb).
  It uses pruning for optimizing the call.
sql/ha_partition.h:
  Bug#40595: Non-matching rows not released with READ-COMMITTED
  on tables with partitions
  
  Added function to the partitioning handler for handling
  semi consistent reads (unlock_row was already implemented,
  and this is needed for unlock_row to work properly in innodb).
2008-11-10 21:13:24 +01:00
Georgi Kodinov
05dbb26dfc merged 5.1 main -> 5.1-bugteam 2008-11-06 16:18:25 +02:00
Mattias Jonsson
559efbf14e merge 2008-11-06 07:29:07 +01:00
Evgeny Potemkin
8d75510e90 Merged fix for the bug#37870. 2008-11-05 23:46:24 +03:00
Mattias Jonsson
7c5d066b39 merge 2008-11-05 20:44:19 +01:00
Evgeny Potemkin
3c49cb0795 Bug#37870: Usage of uninitialized value caused failed assertion.
The convert_constant_item function converts a constant to integer using
field for condition like 'field = a_constant'. In some cases the
convert_constant_item is called for a subquery when outer select is already
being executed, so convert_constant_item saves field's value to prevent its
corruption. For EXPLAIN and at the prepare phase field's value isn't
initialized yet, thus when convert_constant_item tries to restore saved
value it fails assertion.

Now the convert_constant_item doesn't save/restore field's value if it's
haven't been read yet. Outer constant values are always saved.

mysql-test/r/explain.result:
  Added a test case for the bug#37870.
mysql-test/t/explain.test:
  Added a test case for the bug#37870.
sql/item_cmpfunc.cc:
  Bug#37870: Usage of uninitialized value caused failed assertion.
  Now the convert_constant_item doesn't save/restore field's value if it's
  haven't been read yet. Outer constant values are always saved.
2008-11-05 18:40:23 +03:00
Mattias Jonsson
bcd88c9f9e Bug#40494: MYSQL server crashes on range access with partitioning and
order by

Problem was that the first index read was unordered,
and the next was ordered, resulting in use of
uninitialized data.

Solution was to use the correct variable to see if
the 'next' call should be ordered or not.

mysql-test/r/partition.result:
  Bug#40494: MYSQL server crashes on range access with
  partitioning and order by
  
  Added test case for the bug.
mysql-test/t/partition.test:
  Bug#40494: MYSQL server crashes on range access with
  partitioning and order by
  
  Added test case for the bug.
sql/ha_partition.cc:
  Bug#40494: MYSQL server crashes on range access with
  partitioning and order by
  
  Used the wrong variable to decide to continue with
  ordered or unordered scan.
2008-11-05 15:53:28 +01:00
Matthias Leich
50baafeb8b Merge of bug fix into actual tree 2008-11-04 19:02:56 +01:00
Matthias Leich
d2603f9aed - Fix for Bug #39848, #39863, #39978, #39569
Bug#39848 events_bugs fails sporadically on pushbuild
            (missing rows in table event_log)
     Details: Reimplement the subtest for BUG 28924
              - check if the number of rows within the table
                event_log changes but don't print rows
                because the number varies depending on
                load on testing box
              - shift DROP USER befor DROP EVENT
                = Subtest fits again to old bug
              - remove no more needed comments + variables
  Bug#39863 events_bugs fails sporadically on pushbuild 
            (extra processes in I_S.PROCESSLIST)
     Details: Abort with appropriate message to the protocol if
              release_lock() does not has the intended effect.
              This cannot prevent problems caused by the probably
              buggy release_lock() but it reveals if we had a
              problem in this area.
  Bug#39978 main.events_bugs does not clean up
     Detail: Restore global.event_scheduler = ON at end of test
  Bug#39569 events_bugs fails sporadically on pushbuild
            (should have failed with errno 1539)
     Detail: Set $wait_timeout to 4 instead of 2
- Fix two instabilities (result sets pulled from processlist in
  subtest for bug 16407) which were found during tests with high
  parallel I/O load
- Minor improvements of formatting
  Details:
  - Add comments
  - Remove tabs and trailing blanks
  - Add line breaks for better readability
2008-11-04 12:27:21 +01:00
Mattias Jonsson
460407d30b merge 2008-11-04 09:47:01 +01:00
Mattias Jonsson
747099e3fe merge 2008-11-04 09:36:56 +01:00
Mattias Jonsson
8dd07d32c9 merge 2008-11-04 08:55:43 +01:00
Mattias Jonsson
bb1ad9ce08 Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
The partitioning clause is only a very long single line, which is very
hard to interpret for a human. This patch breaks the partitioning
syntax into one line for the partitioning type, and one line per
partition/subpartition.

mysql-test/r/information_schema_part.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/r/partition.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/r/partition_archive.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/r/partition_datatype.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/r/partition_innodb.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/r/partition_mgm.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/r/partition_mgm_err.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/r/partition_not_windows.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/r/partition_range.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/r/partition_symlink.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/suite/ndb/r/ndb_partition_key.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/suite/ndb/r/ndb_partition_range.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/suite/ndb_team/r/ndb_dd_backuprestore.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/suite/parts/inc/partition_directory.inc:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Changed partitioning clause format for verifying the new output format.
mysql-test/suite/parts/r/ndb_dd_backuprestore.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/suite/parts/r/part_supported_sql_func_innodb.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/suite/parts/r/part_supported_sql_func_myisam.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/suite/parts/r/part_supported_sql_func_ndb.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/suite/parts/r/partition_alter1_1_2_innodb.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/suite/parts/r/partition_alter1_1_2_myisam.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/suite/parts/r/partition_alter1_1_innodb.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/suite/parts/r/partition_alter1_1_myisam.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/suite/parts/r/partition_alter1_2_innodb.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/suite/parts/r/partition_alter1_2_myisam.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/suite/parts/r/partition_alter2_1_innodb.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/suite/parts/r/partition_alter2_1_myisam.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/suite/parts/r/partition_alter2_2_innodb.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/suite/parts/r/partition_alter2_2_myisam.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/suite/parts/r/partition_alter3_innodb.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/suite/parts/r/partition_alter3_myisam.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/suite/parts/r/partition_alter4_innodb.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/suite/parts/r/partition_alter4_myisam.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/suite/parts/r/partition_auto_increment_archive.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/suite/parts/r/partition_auto_increment_blackhole.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/suite/parts/r/partition_auto_increment_innodb.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/suite/parts/r/partition_auto_increment_memory.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/suite/parts/r/partition_auto_increment_myisam.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/suite/parts/r/partition_auto_increment_ndb.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/suite/parts/r/partition_basic_innodb.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/suite/parts/r/partition_basic_myisam.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/suite/parts/r/partition_basic_symlink_innodb.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/suite/parts/r/partition_basic_symlink_myisam.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/suite/parts/r/partition_bit_innodb.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/suite/parts/r/partition_bit_myisam.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/suite/parts/r/partition_bit_ndb.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/suite/parts/r/partition_char_innodb.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/suite/parts/r/partition_char_myisam.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/suite/parts/r/partition_datetime_innodb.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/suite/parts/r/partition_datetime_myisam.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/suite/parts/r/partition_decimal_innodb.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/suite/parts/r/partition_decimal_myisam.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/suite/parts/r/partition_engine_innodb.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/suite/parts/r/partition_engine_myisam.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/suite/parts/r/partition_engine_ndb.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/suite/parts/r/partition_float_innodb.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/suite/parts/r/partition_float_myisam.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/suite/parts/r/partition_int_innodb.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/suite/parts/r/partition_int_myisam.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/suite/parts/r/partition_int_ndb.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/suite/parts/r/partition_mgm_lc0_archive.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/suite/parts/r/partition_mgm_lc0_innodb.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/suite/parts/r/partition_mgm_lc0_memory.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/suite/parts/r/partition_mgm_lc0_myisam.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/suite/parts/r/partition_mgm_lc0_ndb.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/suite/parts/r/partition_mgm_lc1_archive.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/suite/parts/r/partition_mgm_lc1_innodb.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/suite/parts/r/partition_mgm_lc1_memory.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/suite/parts/r/partition_mgm_lc1_myisam.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/suite/parts/r/partition_mgm_lc1_ndb.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/suite/parts/r/partition_mgm_lc2_archive.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/suite/parts/r/partition_mgm_lc2_innodb.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/suite/parts/r/partition_mgm_lc2_memory.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/suite/parts/r/partition_mgm_lc2_myisam.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/suite/parts/r/partition_mgm_lc2_ndb.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/suite/parts/r/partition_special_innodb.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/suite/parts/r/partition_special_myisam.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/suite/parts/r/partition_syntax_innodb.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/suite/parts/r/partition_syntax_myisam.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/suite/parts/r/rpl_partition.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/suite/rpl/r/rpl_extraCol_innodb.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/suite/rpl/r/rpl_extraCol_myisam.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/suite/rpl/r/rpl_innodb_bug28430.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/suite/rpl/r/rpl_row_basic_8partition.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/suite/rpl_ndb/r/rpl_ndb_2innodb.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/suite/rpl_ndb/r/rpl_ndb_2myisam.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/suite/rpl_ndb/r/rpl_ndb_dd_partitions.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/suite/rpl_ndb/r/rpl_ndb_extraCol.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/suite/rpl_ndb/r/rpl_ndb_innodb2ndb.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/suite/rpl_ndb/r/rpl_ndb_myisam2ndb.result:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Updated test result due to the new partitioning clause output format.
mysql-test/t/partition.test:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Added small tests for for the new partitioning clause output format.
mysql-test/t/partition_mgm.test:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Added small tests for for the new partitioning clause output format.
sql/sql_partition.cc:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Changed formatting of the partitioning clause from single line into
  multiple indented lines
sql/sql_show.cc:
  Bug#14326: No formatting of partitioning clause in SHOW CREATE TABLE output
  
  Changed formatting of the partitioning clause from single line into
  multiple indented lines
2008-11-04 08:43:21 +01:00
Mats Kindahl
c780c2a24c Merging with 5.1-5.1.29-rc 2008-11-03 18:50:49 +01:00
Mats Kindahl
ad8ffe6add Bug #40360: Binlog related errors with binlog off
Adding missing drop of created table and tidying display.


mysql-test/t/innodb_mysql.test:
  Adding drop of created table and cleaning variable display
2008-11-03 18:46:47 +01:00
Mats Kindahl
c3a5b59676 Bug #40360: Binlog related errors with binlog off
When statement-based replication is used, and the
transaction isolation level is READ-COMMITTED or stricter,
InnoDB will print an error because statement-based
replication might lead to inconsistency between master
and slave databases. However, when the binary log is not
engaged, this is not an issue and an error should
not be printed.

This patch makes thd_binlog_format() return BINLOG_FORMAT_
UNSPEC when the binary log is not engaged for the given
thread.

mysql-test/t/innodb_mysql.test:
  Adding test that no error message is printed from inside
  InnoDB when the binary log is turned off.
2008-11-03 12:14:48 +01:00
Georgi Kodinov
0d4aeaf6e3 merged 5.0 bug 33811 -> 5.1 bug 33811 working tree 2008-11-03 12:40:58 +02:00
Georgi Kodinov
6af9982569 merged 5.0-bugteam -> bug 33811-5.0-bugteam working tree 2008-11-03 11:50:32 +02:00
Kristofer Pettersson
42659fb82d Fixed race condition in test case status2. A 'disconnect' issues an
implicit command which isn't completed immediately.


mysql-test/r/status2.result:
  * Moved disconnect command to avoid race.
mysql-test/t/status2.test:
  * Moved disconnect command to avoid race.
2008-10-31 10:25:03 +01:00
Mattias Jonsson
58d2372b15 merge 2008-10-29 23:01:41 +01:00
Mattias Jonsson
b72d1507db Bug#39084: Getting intermittent errors with statement-based binary logging
Problem was that partitioning cached the table flags.
These flags could change due to TRANSACTION LEVEL changes.
Solution was to remove the cache and always return the table flags
from the first partition (if the handler was initialized).

mysql-test/r/partition_innodb_stmt.result:
  Bug#39084: Getting intermittent errors with statement-based binary logging
  
  New test result file.
mysql-test/t/partition_innodb_stmt.test:
  Bug#39084: Getting intermittent errors with statement-based binary logging
  
  New test file.
sql/ha_partition.cc:
  Bug#39084: Getting intermittent errors with statement-based binary logging
  
  Removed m_table_flags, and added m_handler_status.
  Added checks that all partitions have the same
  table flags.
  Moved some variable initializations.
  Updated some comments.
  Fixed typo initialise -> initialize
  Changed HA_EXTTA_NO_READCHECK to do nothing, since it
  is only used in ha_open, which is called for every
  partition in ::open anyway.
sql/ha_partition.h:
  Bug#39084: Getting intermittent errors with statement-based binary logging
  
  Removed m_table_flags, and added m_handler_status.
  Always return the first partitions table flags, instead of using
  cached table flags.
  Added define of enabled/disabled partitioning table flags
  Fixed type initialise -> initialize
  Updated some comments.
sql/handler.cc:
  Bug#39084: Getting intermittent errors with statement-based binary logging
  
  Fixed type initialise -> initialize.
sql/handler.h:
  Bug#39084: Getting intermittent errors with statement-based binary logging
  
  Added comment to understand where the cached value is set.
2008-10-29 21:20:04 +01:00
Sergey Glukhov
caa73f2218 automerge 2008-10-27 17:11:44 +04:00
Evgeny Potemkin
fbb6efeb51 Merged fix for the bug#37870. 2008-10-27 15:04:51 +03:00
Sergey Glukhov
903c4dcf3b 5.0-bugteam->5.1-bugteam merge(bug#39040) 2008-10-27 15:58:51 +04:00
Sergey Glukhov
380f1a8440 Bug#39040 valgrind errors/crash when creating views with binlog logging enabled
A string buffers which were included in the 'view' data structure
were allocated on the stack, causing an invalid pointer when used
after the function returned.
The fix: use copy of values for view->md5 & view->queries


mysql-test/r/view.result:
  test result
mysql-test/t/view.test:
  test case
sql/sql_view.cc:
  A string buffers which were included in the 'view' data structure
  were allocated on the stack, causing an invalid pointer when used
  after the function returned.
  The fix: use copy of values for view->md5 & view->queries
2008-10-27 14:22:38 +04:00
Evgeny Potemkin
e27e560783 Bug#37870: Usage of uninitialized value caused failed assertion.
The convert_constant_item function converts a constant to integer using
field for condition like 'field = a_constant'. When the convert_constant_item
is called for a subquery the outer select is already being executed, so
convert_constant_item saves field's value to prevent its corruption.
For EXPLAIN field's value isn't initialized thus when convert_constant_item
tries to restore saved value it fails assertion.
      
Now the convert_constant_item doesn't save/restore field's value
for EXPLAIN.


mysql-test/r/explain.result:
  Added a test case for the bug#37870.
mysql-test/t/explain.test:
  Added a test case for the bug#37870.
sql/item_cmpfunc.cc:
  Bug#37870: Usage of uninitialized value caused failed assertion.
  Now the convert_constant_item doesn't save/restore field's value
  for EXPLAIN.
2008-10-27 12:26:32 +03:00
Serge Kozlov
eafe728fc5 Bug#22442, removed number of port 2008-10-26 22:34:24 +03:00
Serge Kozlov
1108ba23e0 Bug#22442.
1. Replace --sleep by wait_* primitive
2. Vertical output for SHOW SLAVE STATUS
3. Updated result file
2008-10-26 21:53:21 +03:00
Davi Arnaut
460a90b0bf Post-merge fix: Update warning number due to repositioning in the error list.
mysql-test/r/partition_windows.result:
  Update warning number due to new errors appearing earlier
  in the list.
mysql-test/r/windows.result:
  Update warning number due to new errors appearing earlier
  in the list.
2008-10-26 15:05:24 -02:00
Davi Arnaut
d4438c99ff Merge from mysql-5.1-5.1.29-rc into mysql-5.1-bugteam 2008-10-24 11:58:48 -02:00
Davi Arnaut
463c837c3a Merge from mysql-5.0-bugteam into mysql-5.1-bugteam
mysql-test/r/partition_not_windows.result:
  Update warning number due to new errors appearing earlier
  in the list.
mysql-test/r/partition_symlink.result:
  Update warning number due to new errors appearing earlier
  in the list.
mysql-test/r/symlink.result:
  Update warning number due to new errors appearing earlier
  in the list.
2008-10-24 10:50:59 -02:00