An error occurred fetching the project authors.
  1. 22 Apr, 2006 1 commit
  2. 20 Apr, 2006 1 commit
    • unknown's avatar
      WL 2826: Error handling of ALTER TABLE for partitioning · 319c5da1
      unknown authored
      Various bug fixes (mostly mixed to and from in replace methods)
      
      
      sql/sql_partition.cc:
        Various bug fixes (mostly mixed to and from in replace methods)
      sql/sql_table.cc:
        Various bug fixes (mostly mixed to and from in replace methods)
      319c5da1
  3. 18 Apr, 2006 1 commit
    • unknown's avatar
      WL 2826: Error handling of ALTER TABLE for partitioning · 4624982e
      unknown authored
      Use \0 to indicate frm-file
      Add more comments
      Add more #ifdef code missing previously
      
      
      sql/sql_partition.cc:
        Use \0 to indicate frm-file
      sql/sql_table.cc:
        Use \0 to indicate frm-file
        Add more comments
        Add more #ifdef code missing previously
      4624982e
  4. 16 Apr, 2006 1 commit
    • unknown's avatar
      WL 2826: Error handling of ALTER TABLE for partitioning · 9a40c5bf
      unknown authored
      After review changes
      
      
      mysql-test/r/ndb_partition_key.result:
        Fixed result file
      sql/ha_ndbcluster.cc:
        Fixed interface to create_handler_files
      sql/ha_ndbcluster.h:
        Fixed interface to create_handler_files
      sql/ha_partition.cc:
        Fixed interface to create_handler_files and made it two-stage for rename
        Removed print_error and now it's used by MySQL Server parts instead
      sql/ha_partition.h:
        Fixed interface to create_handler_files
      sql/mysql_priv.h:
        Fixed error injects
        Externalised Global DDL log mutex
        Some interface changes
      sql/mysqld.cc:
        Moved close of DDL log until all user threads been closed
      sql/sql_base.cc:
        Interface changes
      sql/sql_partition.cc:
        Moved print_error to mysql server part
      sql/sql_table.cc:
        Lots of after review changes
      sql/table.cc:
        Fixed upgrade code
      9a40c5bf
  5. 10 Apr, 2006 1 commit
    • unknown's avatar
      BUG#18750: Various problems with partition names, quotation marks · 42d7e8c0
      unknown authored
      mysql-test/r/partition.result:
        Added new test cases
      mysql-test/t/partition.test:
        Added new test cases
      sql/partition_info.cc:
        Check partition names that they don't have trailing spaces
      sql/share/errmsg.txt:
        Added error code for wrong partition names
      sql/sql_partition.cc:
        New method to add partition name strings, ignore OPTION_SHOW_QUOTE_CREATE
      sql/sql_show.cc:
        require_quotes had a bug with identifiers that consisted of only digits,
        these are allowed identifiers but must be quoted and require_quote didn't
        tell this.
      sql/sql_yacc.yy:
        Partition names should identifers and not ident_or_text
      42d7e8c0
  6. 06 Apr, 2006 1 commit
    • unknown's avatar
      BUG#18558 "Partition pruning results are incorrect for certain class of WHERE clauses" : · 4d1666f6
      unknown authored
      * Produce right results for conditions that were transformed to "(partitioning_range) AND
        (list_of_subpartitioning_ranges)": make each partition id set iterator auto-reset itself
        after it has returned all partition ids in the sequence 
      * Fix "Range mapping" and "Range mapping" partitioning interval analysis functions to 
        correctly deal with NULL values. 
      
      
      mysql-test/r/partition_pruning.result:
        Testcase for BUG#18558
      mysql-test/t/partition_pruning.test:
        Testcase for BUG#18558
      sql/opt_range.cc:
        BUG#18558: Move partition set iterator initialization to sql_partition.cc, comment fixes
      sql/partition_info.h:
        BUG#18558: Make each partition set iterator auto-reset itself after it has returned all 
        partition ids in the set it enumerates.
      sql/sql_partition.cc:
        BUG#18558: 
        - Make each partition set iterator auto-reset itself after it has returned all 
          partition ids in the set it enumerates. 
        - Fix partition interval analysis to correctly handle intervals with one or both
          NULL bounds.
      sql/sql_partition.h:
        BUG#18558: 
         - Make each partition set iterator auto-reset itself after it has returned all 
           partition ids in the set it enumerates. 
         - Rename PARTITION_ITERATOR::has_null_value to ret_null_part
      4d1666f6
  7. 03 Apr, 2006 2 commits
    • unknown's avatar
      BUG#18659: In get_part_iter_for_interval_via_walking(), when we need to · a26509ae
      unknown authored
      obtain partition number, call partition_info->get_part_partition_id() when
      the table has subpartitions, and get_partition_id() otherwise. (The bug
      was that we were always doing the latter)
      
      
      mysql-test/r/partition_pruning.result:
        Testcase for BUG#18659
      mysql-test/t/partition_pruning.test:
        Testcase for BUG#18659
      a26509ae
    • unknown's avatar
      Fixes · b7b95ecf
      unknown authored
      b7b95ecf
  8. 01 Apr, 2006 1 commit
  9. 31 Mar, 2006 2 commits
    • unknown's avatar
      cleaned up a few method comments · 04570aa5
      unknown authored
      moved several functions from sql_partition to be member functions
      
      
      sql/partition_info.h:
        move these funcs from sql_partition to this class
      sql/sql_partition.cc:
        move these funcs from sql_partition to this class
      sql/sql_table.cc:
        calling the member func now instead
      04570aa5
    • unknown's avatar
      Fix for BUG#18025: Wrong query results because of bugs in partition pruning: · 45751090
      unknown authored
       - Fix typo bug in SEL_ARG::is_singlepoint()
       - In set_up_range_analysis_info(), treat MEDIUMINT as enumerable type just like other integer types
      
      
      mysql-test/r/partition_pruning.result:
        Testcase for BUG#18025
      mysql-test/t/partition_pruning.test:
        Testcase for BUG#18025
      sql/opt_range.cc:
        BUG#18025: Fix a typo bug in SEL_ARG::is_singlepoint()
      sql/sql_partition.cc:
        BUG#18025: In set_up_range_analysis_info(), treat MEDIUMINT as enumerable type just like other integer types.
      45751090
  10. 29 Mar, 2006 1 commit
    • unknown's avatar
      Fixed compiler and valgrind warnings · 59eaf292
      unknown authored
      Added missing DBUG_xxx_RETURN statements
      Fixed some usage of not initialized variables (as found by valgrind)
      Ensure that we don't remove locked tables used as name locks from open table cache until unlock_table_names() are called.
      This was fixed by having drop_locked_name() returning any table used as a name lock so that we can free it in unlock_table_names()
      This will allow Tomas to continue with his work to use namelocks to syncronize things.
      
      Note: valgrind still produces a lot of warnings about using not initialized code and shows memory loss errors when running the ndb tests
      
      
      BitKeeper/etc/ignore:
        added mysql-test/r/*.log
      client/mysqltest.c:
        Change type of variables to get rid of compiler warnings
        More debugging
        Fix memory leak
      mysql-test/mysql-test-run.sh:
        Collect warnings about missing DBUG_RETURN statements
      mysql-test/r/lock_multi.result:
        Add test of new code
      mysql-test/r/ndb_condition_pushdown.result:
        Drop used tables before test
      mysql-test/t/lock_multi.test:
        Add test of new code
      mysql-test/t/ndb_condition_pushdown.test:
        Drop used tables before test
      mysql-test/valgrind.supp:
        Ignore 'safe' warnings from libz (when used with archive)
      sql/event.cc:
        More comments
        Simplify code
        Fixed memory leak found by valgrind
      sql/ha_archive.cc:
        Remove compiler warnings (Wrong handlerton structure and signed/unsigned comparison)
      sql/ha_berkeley.cc:
        Fixed compiler warning
      sql/ha_blackhole.cc:
        Fixed compiler warning
      sql/ha_federated.cc:
        Fixed compiler warning
      sql/ha_heap.cc:
        Fixed compiler warning
      sql/ha_myisam.cc:
        Fixed compiler warning
      sql/ha_myisammrg.cc:
        Fixed compiler warning
      sql/ha_ndbcluster.cc:
        Fixed compiler warnings
      sql/ha_partition.cc:
        Fixed compiler warning
        Fixed error noticed by valgrind in ha_partition::rnd_init()
      sql/handler.cc:
        Fixed compiler warning
      sql/handler.h:
        Fixed compiler warning
      sql/item.cc:
        Fixed compiler warning
      sql/item_xmlfunc.cc:
        Fixed warning from valgrind when calling memcpy with wrong address
      sql/lock.cc:
        More debugging
      sql/log.cc:
        Fixed compiler warning
        Indentation fixes
      sql/log.h:
        Fixed compiler warning
      sql/mysql_priv.h:
        Changed prototype for 'drop_locked_tables'
      sql/opt_range.cc:
        Indentation fix
      sql/password.c:
        Removed compiler warnings
      sql/set_var.cc:
        Fixed compiler warning
      sql/slave.cc:
        Fixed compiler warning
      sql/sp_head.cc:
        Fixed compiler warning
      sql/sql_acl.cc:
        Fixed compiler warning
      sql/sql_analyse.cc:
        Added missing DBUG_RETURN statements
      sql/sql_base.cc:
        Removed de-reference of not initialized pointer
        More comments
        drop_locked_tables() changed to not delete tables used for name locking
        Fixed compiler warnings
      sql/sql_delete.cc:
        Fixed usage of not initialized variable
        (deleted could be referenced in some not common error conditions)
      sql/sql_parse.cc:
        Added missing DBUG_VOID_RETURN
        Simplify code
      sql/sql_partition.cc:
        Fixed usage of wrong variable (noticed by valgrind)
      sql/sql_plugin.cc:
        Removed compiler warning
      sql/sql_show.cc:
        Removed compiler warning
      sql/sql_table.cc:
        Ensure that we don't remove locked tables used as name locks from open table cache until unlock_table_names() are called.
        This was fixed by having drop_locked_name() returning any table used as a name lock so that we can free it in unlock_table_names()
        This will allow Tomas to continue with his work to use namelocks to syncronize things.
        
        Fixed wrong test of 'table_type' (path_length could otherwise be accessed uninitialized)
        
        Remove compile warnings about not initialized variables.
      sql/sql_yacc.yy:
        Ensure that no_write_to_binlog is properly initialized
        (Was accessed uninitialized by partition code)
      sql/table.cc:
        Removed valgrind warnings (not fatal)
        Removed compiler warnings
      sql/tztime.cc:
        Removed valgrind warning
      storage/ndb/include/ndbapi/NdbIndexStat.hpp:
        Removed compiler warning
      59eaf292
  11. 28 Mar, 2006 2 commits
    • unknown's avatar
      BUG#13520: BUG#13433: Fixed proper delimiters for fields and comments · 6f2d033c
      unknown authored
      mysql-test/r/partition.result:
        New test cases
      mysql-test/t/partition.test:
        New test cases
      sql/sql_partition.cc:
        Fixed proper delimiters for fields and comments
      6f2d033c
    • unknown's avatar
      Bug#18053 Partitions: crash if null · 44517ca0
      unknown authored
      Bug#18070 Partitions: wrong result on WHERE ... IS NULL
       removed unnecessary code
       added handling of NULL values
      
      
      mysql-test/r/partition.result:
        Bug#18053 Partitions: crash if null
        Bug#18070 Partitions: wrong result on WHERE ... IS NULL
         test case
      mysql-test/t/partition.test:
        Bug#18053 Partitions: crash if null
        Bug#18070 Partitions: wrong result on WHERE ... IS NULL
         test case
      sql/opt_range.cc:
        Bug#18053 Partitions: crash if null
        Bug#18070 Partitions: wrong result on WHERE ... IS NULL
         initialisation of part_iter.has_null_value
      sql/sql_partition.h:
        Bug#18053 Partitions: crash if null
        Bug#18070 Partitions: wrong result on WHERE ... IS NULL
         added has_null_value
      44517ca0
  12. 24 Mar, 2006 2 commits
    • unknown's avatar
      BUG#16806: ALTER TABLE with new field in before position fails · d45ebd7a
      unknown authored
      Review fixes
      
      
      sql/sql_partition.cc:
        Review fixes
      sql/sql_table.cc:
        Review fixes
      d45ebd7a
    • unknown's avatar
      WL 2826: Error handling of ALTER TABLE for partitioning · 3928d962
      unknown authored
      Loads of review comments fixed
      inactivate => deactivate
      table log => ddl log
      Commented on Error Inject Module added
      Put various #defines into enums
      Fixed abort_and_upgrade_lock, removed unnecessary parameter
      Fixed mysqlish method intro's
      Fixed warning statements
      5.1.7 was released still with partition states in clear text
      
      Fixed io_size bug
      Fixed bug in open that TRUNCATED before reading :)
      file_entry => file_entry_buf
      Don't open DDL log until first write call to DDL log
      handler_type => handler_name
      no => num
      
      
      
      sql/ha_partition.cc:
        Loads of review comments fixed
        inactivate => deactivate
        table log => ddl log
      sql/mysql_priv.h:
        Loads of review comments fixed
        inactivate => deactivate
        table log => ddl log
        Commented on Error Inject Module added
        Put various #defines into enums
        Fixed abort_and_upgrade_lock, removed unnecessary parameter
      sql/mysqld.cc:
        Loads of review comments fixed
        inactivate => deactivate
        table log => ddl log
        Commented on Error Inject Module added
        Put various #defines into enums
        Fixed abort_and_upgrade_lock, removed unnecessary parameter
      sql/partition_element.h:
        Loads of review comments fixed
        inactivate => deactivate
        table log => ddl log
        Commented on Error Inject Module added
        Put various #defines into enums
        Fixed abort_and_upgrade_lock, removed unnecessary parameter
      sql/partition_info.h:
        Loads of review comments fixed
        inactivate => deactivate
        table log => ddl log
        Commented on Error Inject Module added
        Put various #defines into enums
        Fixed abort_and_upgrade_lock, removed unnecessary parameter
      sql/share/errmsg.txt:
        Loads of review comments fixed
        inactivate => deactivate
        table log => ddl log
        Commented on Error Inject Module added
        Put various #defines into enums
        Fixed abort_and_upgrade_lock, removed unnecessary parameter
      sql/sql_base.cc:
        Loads of review comments fixed
        inactivate => deactivate
        table log => ddl log
        Commented on Error Inject Module added
        Put various #defines into enums
        Fixed abort_and_upgrade_lock, removed unnecessary parameter
      sql/sql_partition.cc:
        Loads of review comments fixed
        inactivate => deactivate
        table log => ddl log
        Commented on Error Inject Module added
        Put various #defines into enums
        Fixed abort_and_upgrade_lock, removed unnecessary parameter
        Fixed mysqlish method intro's
        Fixed warning statements
      sql/sql_table.cc:
        Loads of review comments fixed
        inactivate => deactivate
        table log => ddl log
        Commented on Error Inject Module added
        Put various #defines into enums
        Fixed abort_and_upgrade_lock, removed unnecessary parameter
        Fixed mysqlish method intro's
        Fixed warning statements
        Fixed io_size bug
        Fixed bug in open that TRUNCATED before reading :)
        file_entry => file_entry_buf
        Don't open DDL log until first write call to DDL log
        handler_type => handler_name
        no => num
      sql/table.cc:
        Loads of review comments fixed
        inactivate => deactivate
        table log => ddl log
        Commented on Error Inject Module added
        Put various #defines into enums
        Fixed abort_and_upgrade_lock, removed unnecessary parameter
        Fixed mysqlish method intro's
        Fixed warning statements
        5.1.7 was released still with partition states in clear text
        
        Fixed io_size bug
        Fixed bug in open that TRUNCATED before reading :)
        file_entry => file_entry_buf
        Don't open DDL log until first write call to DDL log
        handler_type => handler_name
        no => num
      3928d962
  13. 23 Mar, 2006 1 commit
    • unknown's avatar
      BUG #16806: ALTER TABLE fails when creating new field not last in table · 95efef09
      unknown authored
      Moved some code to else path to avoid delete, create, delete, create scenarios.
      Fixed up the partition info object for some cases where we move from default
      partitioning in NDB to default partitioning using partitioning.
      
      
      sql/sql_partition.cc:
        Added a new parameter for partition default handling
        This is to avoid calling get_no_parts on tables not yet
        created.
        Ensure that we don't reuse the old part_info object for
        any other operation than CREATE TABLE after reading up
        the frm file.
      sql/sql_table.cc:
        Moved some code to else path to avoid delete, create, delete, create scenarios.
        Fixed up the partition info object for some cases where we move from default
        partitioning in NDB to default partitioning using partitioning.
      95efef09
  14. 22 Mar, 2006 2 commits
  15. 21 Mar, 2006 1 commit
  16. 20 Mar, 2006 3 commits
    • unknown's avatar
      BUG#17754 · 51f70d9f
      unknown authored
      Added new syntax ALTER TABLE t1 REMOVE PARTITIONING,
      changed semantics of ALTER TABLE t1 ENGINE=X; to not remove partitioning
      Fix a number of mix engine bugs in partitioning
      
      
      mysql-test/r/ndb_partition_key.result:
        Added a number of new test cases
      mysql-test/r/partition.result:
        Added a number of new test cases
      mysql-test/t/ndb_partition_key.test:
        Added a number of new test cases
      mysql-test/t/partition.test:
        Added a number of new test cases
      sql/lex.h:
        REMOVE and PARTITIONING added as keywords in parser
      sql/sql_lex.h:
        Added flag to alter_info flag
      sql/sql_partition.cc:
        Fixes for the new syntax, changes of the current semantics of the syntax.
        Fixes for errors in handling mixes of table handlers in partitioning syntax
        for ALTER TABLE
      sql/sql_table.cc:
        Bug fix
      sql/sql_yacc.yy:
        New syntax for REMOVE PARTITIONING
      51f70d9f
    • unknown's avatar
      Bug#14367 Partitions: crash if utf8 column · de264164
      unknown authored
        use part_info->item_free_list instead of thd->free_list during partition function parsing
      
      
      mysql-test/r/partition.result:
        Bug#14367 Partitions: crash if utf8 column
          test case
      mysql-test/t/partition.test:
        Bug#14367 Partitions: crash if utf8 column
          test case
      sql/item.cc:
        Bug#14367 Partitions: crash if utf8 column
          create copy of string in current mem_root to avoid memory leak
      de264164
    • unknown's avatar
      bug #17290 (sp with delete, create and rollback causes MySQLD core) · afe397ff
      unknown authored
      additional fixes
      
      
      mysql-test/r/partition.result:
        result fixed
      mysql-test/t/partition.test:
        testcase
      sql/sql_parse.cc:
        part_info cloning moved here
      sql/sql_partition.cc:
        fixes
      sql/sql_table.cc:
        part_info cloning removed
      afe397ff
  17. 18 Mar, 2006 1 commit
    • unknown's avatar
      bug 17290 and bug 14350 · 6a421c56
      unknown authored
      added THD::work_part_info member where we now store modified
      partition_info structure.
      It allows no solve problem when different parts of the part_info get
      into different mem_roots
      
      
      sql/partition_info.cc:
        get_clone implementation
      sql/partition_info.h:
        get_clone() declared
      sql/sql_class.h:
        THD::work_part_info added
      sql/sql_partition.cc:
        thd->work_part_info instead of lex->part_info
      sql/sql_table.cc:
        thd->work_part_info instad of lex->part_info
      sql/unireg.cc:
        thd->work_part_info instad of lex->part_info
      6a421c56
  18. 16 Mar, 2006 1 commit
    • unknown's avatar
      BUG#17772 · 01cce283
      unknown authored
      A crash after ALTER TABLE t1 RENAME ...
      
      
      mysql-test/r/partition.result:
        New test case
      mysql-test/t/partition.test:
        New test case
      sql/sql_lex.h:
        Introduced like name for CREATE TABLE t1 LIKE t2
      sql/sql_parse.cc:
        Introduced like name for CREATE TABLE t1 LIKE t2
      sql/sql_partition.cc:
        Introduced like name for CREATE TABLE t1 LIKE t2
      sql/sql_yacc.yy:
        Introduced like name for CREATE TABLE t1 LIKE t2
      01cce283
  19. 14 Mar, 2006 3 commits
  20. 13 Mar, 2006 1 commit
    • unknown's avatar
      Bug #17097: Partitions: failing ADD PRIMARY KEY leads to temporary rotten metadata,crash · 7e1627d0
      unknown authored
        When doing an ALTER TABLE on a table using partitioning, force the table
        definition to get reloaded, since it may become invalid whenever the ALTER
        TABLE fails (even for an ALTER TABLE without specific partitioning changes).
      
      
      mysql-test/r/partition.result:
        New results
      mysql-test/t/partition.test:
        New regression test
      sql/sql_partition.cc:
        Always force table to get reloaded when we ALTER a
        partitioned table
      7e1627d0
  21. 11 Mar, 2006 3 commits
    • unknown's avatar
      Ensure we discover also error in using subpartition parts in · 402ff552
      unknown authored
      non-subpartitioned tables in ALTER TABLE ADD/REORGANIZE PARTITION
      
      
      402ff552
    • unknown's avatar
      BUG#15961: SUBPARTITION defined in non-subpartitioned table no error · 29cd6ff6
      unknown authored
      Made sure that no subpartition stuff in non-subpartitioned table
      
      
      mysql-test/r/partition.result:
        New test case
      mysql-test/r/partition_mgm_err.result:
        Fixed bug in test case
      mysql-test/t/partition.test:
        New test case
      mysql-test/t/partition_mgm_err.test:
        Fixed bug in test case
      sql/sql_partition.cc:
        Made sure that no subpartition stuff in non-subpartitioned table
      29cd6ff6
    • unknown's avatar
      BUG#16370: Default subpartitioning not properly handled in conjunction · 56c24480
      unknown authored
      with ALTER TABLE ADD/REORGANIZE PARTITION
      Ensure that default subpartitioning is removed when subpartitions
      are defined in ADD/REORGANIZE PARTITION
      
      
      mysql-test/r/partition.result:
        New test cases
      mysql-test/t/partition.test:
        New test cases
      sql/sql_partition.cc:
        Ensure that default subpartitioning is removed when subpartitions
        are defined in ADD/REORGANIZE PARTITION
      56c24480
  22. 10 Mar, 2006 1 commit
  23. 09 Mar, 2006 1 commit
    • unknown's avatar
      BUG#17127: Crash if wrong use of VALUES for list partition · b7b8fd25
      unknown authored
      mysql-test/r/partition.result:
        Added a number of new test cases where errors in use of
        VALUES LESS THAN and VALUES IN is happening for ALTER TABLE
      mysql-test/t/partition.test:
        Added a number of new test cases where errors in use of
        VALUES LESS THAN and VALUES IN is happening for ALTER TABLE
      sql/sql_partition.cc:
        Check for errors with VALUES *
      sql/sql_yacc.yy:
        Add state to part_type when doing ALTER TABLE for partitioning
      b7b8fd25
  24. 07 Mar, 2006 1 commit
    • unknown's avatar
      Fix for bug#15447 Partitions: NULL is treated as zero · 807c7a6a
      unknown authored
        NULL value handling
      
      
      mysql-test/r/ndb_partition_error.result:
        Fix for bug#15447 Partitions: NULL is treated as zero
          test case
      mysql-test/r/partition.result:
        Fix for bug#15447 Partitions: NULL is treated as zero
          test case
      mysql-test/t/ndb_partition_error.test:
        Fix for bug#15447 Partitions: NULL is treated as zero
          test case
      mysql-test/t/partition.test:
        Fix for bug#15447 Partitions: NULL is treated as zero
          test case
      sql/partition_element.h:
        Fix for bug#15447 Partitions: NULL is treated as zero
          added null value flag to partition_element object
      sql/partition_info.h:
        Fix for bug#15447 Partitions: NULL is treated as zero
          added null value flag to partition_info object
          added has_null partition id variable
      807c7a6a
  25. 02 Mar, 2006 1 commit
    • unknown's avatar
      Bug#14527: Partitions: table unreadable if partition name = c-cedilla · 3d96d866
      unknown authored
      sql_partition.cc:
        Changeing THD charset to utf8 when parsing a frm file.
      partition_charset.test, partition_charset.result:
        new file
      
      
      sql/sql_partition.cc:
        Bug#14527: Partitions: table unreadable if partition name = c-cedilla
        Changering THD charset to utf8 when parsing
        a frm file.
      3d96d866
  26. 28 Feb, 2006 2 commits
    • unknown's avatar
      Bug #17499 continued · b70aaf38
      unknown authored
      - moved initialization of used_partitions
      - more tests
      
      + removed reference to fixed bugs
      
      
      mysql-test/r/ndb_partition_range.result:
        Bug #17499 continued
        - more testing
      mysql-test/t/disabled.def:
        removed reference to fixed bugs
      mysql-test/t/ndb_partition_range.test:
        Bug #17499 continued
        - more testing
      sql/ha_ndbcluster.cc:
        Bug #17499 continued
        - moved initialization of used_partitions
      sql/sql_partition.cc:
        Bug #17499 continued
        - moved initialization of used_partitions
      b70aaf38
    • unknown's avatar
      Bug #17701, ALTER TABLE t1 ADD PARTITION for PARTITION BY LIST hangs test · 46fc7653
      unknown authored
      - code wrongly tries to do a "fast alter partition", although not supported
      
      
      sql/handler.h:
        moved defines
      sql/sql_partition.h:
        moved defines
      46fc7653
  27. 25 Feb, 2006 1 commit
    • unknown's avatar
      WL#2977 and WL#2712 global and session-level variable to set the binlog format (row/statement), · 7cac0ddf
      unknown authored
      and new binlog format called "mixed" (which is statement-based except if only row-based is correct,
      in this cset it means if UDF or UUID is used; more cases could be added in later 5.1 release):
      SET GLOBAL|SESSION BINLOG_FORMAT=row|statement|mixed|default;
      the global default is statement unless cluster is enabled (then it's row) as in 5.1-alpha.
      It's not possible to use SET on this variable if a session is currently in row-based mode and has open temporary tables (because CREATE
      TEMPORARY TABLE was not binlogged so temp table is not known on slave),  or if NDB is enabled (because
      NDB does not support such change on-the-fly, though it will later), of if in a stored function (see below).
      The added tests test the possibility or impossibility to SET, their effects, and the mixed mode,
      including in prepared statements and in stored procedures and functions.
      Caveats:
      a) The mixed mode will not work for stored functions: in mixed mode, a stored function will
      always be binlogged as one call and in a statement-based way (e.g. INSERT VALUES(myfunc()) or SELECT myfunc()).
      b) for the same reason, changing the thread's binlog format inside a stored function is
      refused with an error message.
      c) the same problems apply to triggers; implementing b) for triggers will be done later (will ask
      Dmitri).
      Additionally, as the binlog format is now changeable by each user for his session, I remove the implication
      which was done at startup, where row-based automatically set log-bin-trust-routine-creators to 1
      (not possible anymore as a user can now switch to stmt-based and do nasty things again), and automatically
      set --innodb-locks-unsafe-for-binlog to 1 (was anyway theoretically incorrect as it disabled
      phantom protection).
      Plus fixes for compiler warnings.
      
      
      mysql-test/r/rpl_row_4_bytes.result:
        update
      mysql-test/t/rpl_row_4_bytes.test:
        don't influence next tests
      sql/ha_archive.cc:
        please pay attention to this structure when you change it...
      sql/ha_berkeley.cc:
        please pay attention to this structure when you change it...
      sql/ha_blackhole.cc:
        please pay attention to this structure when you change it...
      sql/ha_federated.cc:
        please pay attention to this structure when you change it...
      sql/ha_heap.cc:
        please pay attention to this structure when you change it...
      sql/ha_innodb.cc:
        please pay attention to this structure when you change it...
      sql/ha_myisam.cc:
        please pay attention to this structure when you change it...
      sql/ha_myisammrg.cc:
        please pay attention to this structure when you change it...
      sql/ha_ndbcluster_binlog.cc:
        no more global 'binlog_row_based'
      sql/ha_partition.cc:
        please pay attention to this structure when you change it...
      sql/handler.cc:
        please pay attention to this structure when you change it...
      sql/handler.h:
        it's good to initialize statically (to get no compiler warning) even if to a null value.
      sql/item_func.cc:
        UDFs require row-based if this is the "mixed" binlog format.
      sql/item_strfunc.cc:
        UUID() requires row-based binlogging if this is the "mixed" binlog format
      sql/log.cc:
        binlog_row_based -> thd->current_stmt_binlog_row_based
      sql/log.h:
        the enum enum_binlog_format moves to log.h from mysqld.cc as we need it in several places.
      sql/log_event.cc:
        binlog_row_based -> thd->current_stmt_binlog_row_based
      sql/log_event.h:
        this global variable not used anymore
      sql/mysql_priv.h:
        these global variables not used anymore
      sql/mysqld.cc:
        simplification in the handling of --binlog-format (but with no user-visible change), thanks to
        the new global system variable.
        RBR does not anymore turn on --log-bin-trust-function-creators and --innodb-locks-unsafe-for-binlog
        as these are global options and RBR is now settable per session.
      sql/partition_info.cc:
        compiler warnings
      sql/set_var.cc:
        new class of thread's variable, to handle the binlog_format (like sys_var_thd_enum except
        that is_readonly() is overriden for more checks before update).
        compiler warnings (ok'd by Serg)
      sql/set_var.h:
        new class for the thread's binlog_format (see set_var.cc)
      sql/share/errmsg.txt:
        some messages for when one can't toggle from one binlog format to another
      sql/sp_head.cc:
        binlog_row_based -> thd->current_stmt_binlog_row_based
      sql/sql_base.cc:
        binlog_row_based -> thd->current_stmt_binlog_row_based
      sql/sql_class.cc:
        When a THD is initialized, we set its current_stmt_binlog_row_based
      sql/sql_class.h:
        new THD::variables.binlog_format (the value of the session variable set by SET
        or inherited from the global value), and THD::current_stmt_binlog_row_based which tells if the
        current statement does row-based or statement-based binlogging. Both members are needed
        as the 2nd one cannot be derived only from the first one (the statement's type plays a role too),
        and the 1st one is needed to reset the 2nd one.
      sql/sql_delete.cc:
        binlog_row_based -> thd->current_stmt_binlog_row_based
      sql/sql_insert.cc:
        binlog_row_based -> thd->current_stmt_binlog_row_based
      sql/sql_load.cc:
        binlog_row_based -> thd->current_stmt_binlog_row_based.
      sql/sql_parse.cc:
        when we are done with a statement, we reset the current_stmt_binlog_row_based to the value
        derived from THD::variables.binlog_format.
      sql/sql_partition.cc:
        compiler warning
      sql/sql_show.cc:
        compiler warning
      sql/sql_table.cc:
        binlog_row_based -> thd->current_stmt_binlog_row_based
      tests/mysql_client_test.c:
        compiler warning
      mysql-test/r/ndb_binlog_basic2.result:
        new result
      mysql-test/r/rpl_switch_stm_row_mixed.result:
        new result
      mysql-test/t/ndb_binlog_basic2.test:
        new test to verify that if cluster is enabled, can't change binlog format on the fly.
      mysql-test/t/rpl_switch_stm_row_mixed.test:
        test to see if one can switch between SBR, RBR, and "mixed" mode, and when one cannot,
        and test to see if the switching, and the mixed mode, work properly (using UUID() to test,
        as using UDFs is not possible in the testsuite for portability reasons).
      7cac0ddf
  28. 24 Feb, 2006 1 commit
    • unknown's avatar
      BUG# 17430 Partitoins: crash on SELECT * FROM t1 WHERE f_int1 IS NULL · a9dab911
      unknown authored
      BUG# 17432: Partitions: wrong result, SELECT ... WHERE <column> is null
      
      
      mysql-test/r/partition.result:
        result block for tests
      mysql-test/t/partition.test:
        test cases for bug #17432 and 17430
      sql/sql_partition.cc:
        improve null handling by returning LONGLONG_MIN for values that are NULL
      a9dab911