1. 29 Jul, 2008 1 commit
    • Sven Sandberg's avatar
      BUG#38068: binlog_stm_binlog fails sporadically in pushbuild · 93336ff0
      Sven Sandberg authored
      Post-push fix: updated some result files that were affected
      by the previous fix to this bug.
      
      
      mysql-test/suite/binlog/r/binlog_killed_simulate.result:
        Updated result file.
      mysql-test/suite/binlog/r/binlog_row_binlog.result:
        Updated result file.
      mysql-test/suite/binlog/r/binlog_row_mix_innodb_myisam.result:
        Updated result file.
      mysql-test/suite/binlog/r/binlog_statement_insert_delayed.result:
        Updated result file.
      mysql-test/suite/binlog/r/binlog_stm_mix_innodb_myisam.result:
        Updated result file.
      mysql-test/suite/rpl/r/rpl_stm_log.result:
        Updated result file.
      93336ff0
  2. 23 Jul, 2008 2 commits
    • Sven Sandberg's avatar
      BUG#38068: binlog_stm_binlog fails sporadically in pushbuild · a73626ad
      Sven Sandberg authored
      Problem: binlog_stm_binlog runs INSERT DELAYED queries, and
      then prints the contents of the binlog. Before checking the
      contents of the binlog, the test waits until the rows have
      appeared in the table. However, this is not enough, since
      INSERT DELAYED does not write rows to the binlog at the same
      time as it writes them to the table. So there is a race.
      Fix: Add a FLUSH TABLES before SHOW BINLOG EVENTS. That
      waits until the insert_delayed thread is done.
      
      
      mysql-test/extra/binlog_tests/binlog_insert_delayed.test:
        - Added FLUSH TABLES, so that SHOW BINLOG EVENTS becomes
        deterministic.
        - Added comments.
        - Removed unnecessary 'set @@session.auto_increment_increment'
        statements.
        - Removed unnecessary check that the number of rows inserted
        to the table is 11.
      mysql-test/suite/binlog/r/binlog_stm_binlog.result:
        updated result file
      a73626ad
    • Sven Sandberg's avatar
      BUG#37493: rpl_trunc_temp.test nondeterministic · 704cafe6
      Sven Sandberg authored
      Problem: the test waits for a 'DROP TEMPORARY TABLE' event to
      appear in the master's binlog, then checks on the slave whether
      the number of temporary tables has decreased. The slave does
      not sync, causing a race.
      Fix: check for the 'DROP TEMPORARY TABLE' event on slave
      instead of on master.
      
      
      mysql-test/suite/rpl/t/rpl_trunc_temp.test:
        - Fixed BUG#37493 by waiting for the event on the slave
        instead of on the master.
        - Added comments.
      704cafe6
  3. 18 Jul, 2008 2 commits
    • Sven Sandberg's avatar
      BUG#38077: rpl_incident At line 22: query 'SELECT * ...' Table 'test.t1' doesn't exist · cf3afac1
      Sven Sandberg authored
      This is not a fix to the bug. It only adds debug info, so
      that we can analyze the bug better next time it happens.
      Please revert the patch after the bug is fixed.
      
      
      mysql-test/suite/rpl/t/rpl_incident.test:
        Added debug info. This will only be printed if the
        test fails.
      cf3afac1
    • Sven Sandberg's avatar
      BUG#38178: rpl_loaddata_map fails sporadically in pushbuild · ce1f3f94
      Sven Sandberg authored
      Problem: master binlog has 'create table t1'. Master binlog
      was removed before slave could replicate it. In test's cleanup
      code, master did 'drop table t1', which caused slave sql
      thread to stop with an error since slave sql thread did not
      know about t1.
      Fix: t1 is just an auxiliary construction, only needed on
      master. Hence, we turn off binlogging before t1 is created,
      drop t1 as soon as we don't need it anymore, and then turn
      on binlogging again.
      
      
      mysql-test/include/show_binlog_events.inc:
        Filter out directories and block_len from
        LOAD DATA INFILE events.
      mysql-test/suite/rpl/r/rpl_loaddata_map.result:
        updated result file
      mysql-test/suite/rpl/t/rpl_loaddata_map.test:
        Turn off binlogging while t1 is used, drop t1 as soon
        as we don't need it anymore, and turn on binlogging again.
        Also added some comments and replaced 'show binlog events'
        by 'source include/show_binlog_events.inc'.
      ce1f3f94
  4. 17 Jul, 2008 1 commit
    • Sven Sandberg's avatar
      BUG#38170: rpl_variables failed on pushbuild: could not sync with master · daa7c0aa
      Sven Sandberg authored
      Problem: the test set @@global.init_slave to garbage at a time
      which was not guaranteed to be after the time when the slave's
      SQL thread used it. That would cause the slave's SQL thread to
      stop in rare cases.
      Fix: The test does not care about the value of
      @@global.init_slave, except that it should be different on
      master and slave. Hence, we set @@global.init_slave to
      something that is valid SQL.
      
      
      mysql-test/suite/rpl/r/rpl_variables.result:
        updated result file.
      mysql-test/suite/rpl/t/rpl_variables.test:
        Set @@global.init_slave to something that is valid SQL.
      daa7c0aa
  5. 11 Jul, 2008 1 commit
  6. 10 Jul, 2008 9 commits
    • Gleb Shchepa's avatar
      merge 5.0-bugteam --> 5.1-bugteam · ed3bd49a
      Gleb Shchepa authored
      ed3bd49a
    • Gleb Shchepa's avatar
      warning elimination · f1761fba
      Gleb Shchepa authored
      f1761fba
    • Gleb Shchepa's avatar
      merge 5.0-bugteam -> 5.1-bugteam · 68a19686
      Gleb Shchepa authored
      68a19686
    • Gleb Shchepa's avatar
      warning elimination · c25208ba
      Gleb Shchepa authored
      c25208ba
    • Marc Alff's avatar
      Fixed build warning on Windows (emb_qcache.cc) · 74f16bc2
      Marc Alff authored
      libmysqld/emb_qcache.cc:
        Fixed build warning on Windows:
        ported the fix from 6.0 in 5.1
      74f16bc2
    • Tatiana A. Nurnberg's avatar
      auto-merge · 21eb9fd0
      Tatiana A. Nurnberg authored
      21eb9fd0
    • Tatiana A. Nurnberg's avatar
      auto-merge · 7a65532f
      Tatiana A. Nurnberg authored
      7a65532f
    • Tatiana A. Nurnberg's avatar
      Bug#35848: UUID() returns UUIDs with the wrong time · b77ac4a0
      Tatiana A. Nurnberg authored
      offset for time part in UUIDs was 1/1000 of what it
      should be. In other words, offset was off.
      
      Also handle the case where we count into the future
      when several UUIDs are generated in one "tick", and
      then the next call is late enough for us to unwind
      some but not all of those borrowed ticks.
      
      Lastly, handle the case where we keep borrowing and
      borrowing until the tick-counter overflows by also
      changing into a new "numberspace" by creating a new
      random suffix.
      
      mysql-test/r/func_misc.result:
        Show that time-part of UUIDs is correct now.
      mysql-test/t/func_misc.test:
        Show that time-part of UUIDs is correct now
        by replicating the C-code's resultin SQL.
        Results also decode to expect date-data on
        command-line (external validation).
        
        No test for unwinding of borrowed ticks as
        this a) is a race and b) depends on what timer
        we get.
      sql/item_strfunc.cc:
        correct offset for date/time-part of UUID.
        also make sure that when we counted into
        the future earlier (several UUIDs generated
        in same tick), we only give back as many
        "borrowed" ticks as we can without duplicating
        past timestamps. If our tick-counter overflows
        before we can give back, or if the system-clock
        is set back (by user or Daylight Saving Time),
        we create a new random suffix to avoid
        collisions and clear the tick-counter.
      b77ac4a0
    • Tatiana A. Nurnberg's avatar
      Bug#35848: UUID() returns UUIDs with the wrong time · c054c744
      Tatiana A. Nurnberg authored
      offset for time part in UUIDs was 1/1000 of what it
      should be. In other words, offset was off.
      
      Also handle the case where we count into the future
      when several UUIDs are generated in one "tick", and
      then the next call is late enough for us to unwind
      some but not all of those borrowed ticks.
      
      Lastly, handle the case where we keep borrowing and
      borrowing until the tick-counter overflows by also
      changing into a new "numberspace" by creating a new
      random suffix.
      
      
      mysql-test/r/func_misc.result:
        Show that time-part of UUIDs is correct now.
      mysql-test/t/func_misc.test:
        Show that time-part of UUIDs is correct now
        by replicating the C-code's resultin SQL.
        Results also decode to expect date-data on
        command-line (external validation).
        
        No test for unwinding of borrowed ticks as
        this a) is a race and b) depends on what timer
        we get.
      sql/item_strfunc.cc:
        correct offset for date/time-part of UUID.
        also make sure that when we counted into
        the future earlier (several UUIDs generated
        in same tick), we only give back as many
        "borrowed" ticks as we can without duplicating
        past timestamps. If our tick-counter overflows
        before we can give back, or if the system-clock
        is set back (by user or Daylight Saving Time),
        we create a new random suffix to avoid
        collisions and clear the tick-counter.
      c054c744
  7. 09 Jul, 2008 8 commits
    • Gleb Shchepa's avatar
      null merge 5.0-bugteam --> 5.1-bugteam · d03b0d8e
      Gleb Shchepa authored
      d03b0d8e
    • Gleb Shchepa's avatar
      merge 5.1-main --> 5.1-bugteam · 8ac5d5a4
      Gleb Shchepa authored
      8ac5d5a4
    • Gleb Shchepa's avatar
      merge 5.0-main --> 5.0-bugteam · 075036fe
      Gleb Shchepa authored
      075036fe
    • Matthias Leich's avatar
      Upmerge 5.0 -> 5.1 · f7be79e8
      Matthias Leich authored
      f7be79e8
    • Mattias Jonsson's avatar
      merge · d7caae77
      Mattias Jonsson authored
      d7caae77
    • Matthias Leich's avatar
      1. Fix for Bug#37160 · d635f514
      Matthias Leich authored
         "funcs_2: The tests do not check if optional character
                     sets exist."
      2. Minor cleanup
      d635f514
    • Mattias Jonsson's avatar
      Bug#35736 Test 'parts.partition_basic_symlink_myisam' depends on output of 'ls' · 33c3e3b3
      Mattias Jonsson authored
      The problem is that relying on the output of the 'ls' command is not
      portable as its behavior is not the same between systems and it might
      even not be available at all in (Windows).
      
      So I added list_files that relies on the portable mysys library instead.
      (and also list_files_write_file and list_files_append_file,
      since the test was using '--exec ls' in that way.)
      
      client/mysqltest.c:
        Bug#35736 Test 'parts.partition_basic_symlink_myisam' depends on output of 'ls'
        
        To be able to replace the use of '--exec ls' I have added
        list_files, list_files_write_file and list_files_append_file.
        
        list_files <dirname> [<filename incl. wild-cards>]
        is equivalent to 'ls <dirname>/[<filename incl. wild-cards>]'
        
        list_files_write_file creates/overwrites a file with the content
        list_files_append_file creates/appends a file with the content
        list_files* return a sorted output.
      mysql-test/r/mysqltest.result:
        Bug#35736 Test 'parts.partition_basic_symlink_myisam' depends on output of 'ls'
        
        result file change, due to added test of the new list_files command.
      mysql-test/suite/parts/inc/partition_check_drop.inc:
        Bug#35736 Test 'parts.partition_basic_symlink_myisam' depends on output of 'ls'
        
        Using the new list_files instead of 'ls'.
        
        Changed the use of local variables (ls_file, file_list)
        and server variable (@aux).
      mysql-test/suite/parts/inc/partition_layout.inc:
        Bug#35736 Test 'parts.partition_basic_symlink_myisam' depends on output of 'ls'
        
        Using the new list_files instead of 'ls'.
      mysql-test/suite/parts/inc/partition_layout_check1.inc:
        Bug#35736 Test 'parts.partition_basic_symlink_myisam' depends on output of 'ls'
        
        Using the new list_files instead of 'ls'.
      mysql-test/suite/parts/inc/partition_layout_check2.inc:
        Bug#35736 Test 'parts.partition_basic_symlink_myisam' depends on output of 'ls'
        
        Replaces '--exec ls' with list_files.
        Removal of the directory part of file listing.
      mysql-test/suite/parts/r/partition_alter1_1_2_myisam.result:
        Bug#35736 Test 'parts.partition_basic_symlink_myisam' depends on output of 'ls'
        
        Replaces '--exec ls' with list_files.
        Removal of the directory part of file listing.
      mysql-test/suite/parts/r/partition_alter1_1_myisam.result:
        Bug#35736 Test 'parts.partition_basic_symlink_myisam' depends on output of 'ls'
        
        Replaces '--exec ls' with list_files.
        Removal of the directory part of file listing.
      mysql-test/suite/parts/r/partition_alter1_2_myisam.result:
        Bug#35736 Test 'parts.partition_basic_symlink_myisam' depends on output of 'ls'
        
        Replaces '--exec ls' with list_files.
        Removal of the directory part of file listing.
      mysql-test/suite/parts/r/partition_alter2_myisam.result:
        Bug#35736 Test 'parts.partition_basic_symlink_myisam' depends on output of 'ls'
        
        Replaces '--exec ls' with list_files.
        Removal of the directory part of file listing.
      mysql-test/suite/parts/r/partition_alter3_innodb.result:
        Bug#35736 Test 'parts.partition_basic_symlink_myisam' depends on output of 'ls'
        
        Replaces '--exec ls' with list_files.
        Removal of the directory part of file listing.
      mysql-test/suite/parts/r/partition_alter3_myisam.result:
        Bug#35736 Test 'parts.partition_basic_symlink_myisam' depends on output of 'ls'
        
        Replaces '--exec ls' with list_files.
        Removal of the directory part of file listing.
      mysql-test/suite/parts/r/partition_basic_innodb.result:
        Bug#35736 Test 'parts.partition_basic_symlink_myisam' depends on output of 'ls'
        
        Replaces '--exec ls' with list_files.
        Removal of the directory part of file listing.
      mysql-test/suite/parts/r/partition_basic_myisam.result:
        Bug#35736 Test 'parts.partition_basic_symlink_myisam' depends on output of 'ls'
        
        Replaces '--exec ls' with list_files.
        Removal of the directory part of file listing.
      mysql-test/suite/parts/r/partition_basic_symlink_myisam.result:
        Bug#35736 Test 'parts.partition_basic_symlink_myisam' depends on output of 'ls'
        
        Replaces '--exec ls' with list_files.
        Removal of the directory part of file listing.
      mysql-test/suite/parts/r/partition_engine_myisam.result:
        Bug#35736 Test 'parts.partition_basic_symlink_myisam' depends on output of 'ls'
        
        Replaces '--exec ls' with list_files.
        Removal of the directory part of file listing.
      mysql-test/suite/parts/r/partition_syntax_myisam.result:
        Bug#35736 Test 'parts.partition_basic_symlink_myisam' depends on output of 'ls'
        
        Replaces '--exec ls' with list_files.
        Removal of the directory part of file listing.
      mysql-test/t/mysqltest.test:
        Bug#35736 Test 'parts.partition_basic_symlink_myisam' depends on output of 'ls'
        
        Adding test for the new mysqltest commands list_files,
        list_files_write_file and list_files_append_file.
      33c3e3b3
    • unknown's avatar
      Raise version number after cloning 5.0.66 · 485e5ba2
      unknown authored
      485e5ba2
  8. 08 Jul, 2008 6 commits
  9. 07 Jul, 2008 8 commits
    • Mattias Jonsson's avatar
    • Marc Alff's avatar
      Manual merge of bug#26030 in mysql-5.1-bugteam · e59c5656
      Marc Alff authored
      e59c5656
    • Mattias Jonsson's avatar
      merge · dd5966a8
      Mattias Jonsson authored
      dd5966a8
    • Mattias Jonsson's avatar
      Bug#35745: SELECT COUNT(*) is not correct for some partitioned tables. · 19a48cdf
      Mattias Jonsson authored
      problem was that ha_partition::records was not implemented, thus
      using the default handler::records, which is not correct if the engine
      does not support HA_STATS_RECORDS_IS_EXACT.
      Solution was to implement ha_partition::records as a wrapper around
      the underlying partitions records.
      
      The rows column in explain partitions will now include the total
      number of records in the partitioned table.
      
      (recommit after removing out-commented code)
      19a48cdf
    • Marc Alff's avatar
      Merge · ce79abc1
      Marc Alff authored
      ce79abc1
    • Marc Alff's avatar
      Bug#26030 (Parsing fails for stored routine w/multi-statement execution · 2b285467
      Marc Alff authored
      enabled)
      
      Before this fix, the lexer and parser would treat the ';' character as a
      different token (either ';' or END_OF_INPUT), based on convoluted logic,
      which failed in simple cases where a stored procedure is implemented as a
      single statement, and used in a multi query.
      
      With this fix:
      - the character ';' is always parsed as a ';' token in the lexer,
      - parsing multi queries is implemented in the parser, in the 'query:' rules,
      - the value of thd->client_capabilities, which is the capabilities
        negotiated between the client and the server during bootstrap,
        is immutable and not arbitrarily modified during parsing (which was the
        root cause of the bug)
      
      2b285467
    • Georgi Kodinov's avatar
      Bug#37627: addendum : · 574eefeb
      Georgi Kodinov authored
       - moved the test into a separate file to check for presence of the test variable
      
      mysql-test/r/subselect.result:
        Bug#37627: moved the test to a separate file
      mysql-test/r/subselect_debug.result:
        Bug#37627: moved the test to a separate file
      mysql-test/t/subselect.test:
        Bug#37627: moved the test to a separate file
      mysql-test/t/subselect_debug.test:
        Bug#37627: moved the test to a separate file
      574eefeb
    • Mats Kindahl's avatar
      Bug #37150 Risk for crash in User_var_log_event::exec_event() · dd6537c1
      Mats Kindahl authored
      On certain kinds of errors (e.g., out of stack), a call to Item_func_
      set_user_var::fix_fields() might fail.  Since the return value of this
      call was not checked inside User_var_log_event::exec_event(), continuing
      execution after this will cause a crash inside Item_func_set_user_var::
      update_hash().
      
      The bug is fixed by aborting execution of the event with an error if
      fix_fields() fails, since it is not possible to continue execution anyway.
      
      
      sql/log_event.cc:
        Aborting execution of event if fix_fields() fails since execution
        of update_hash() might cause a crash.
      dd6537c1
  10. 04 Jul, 2008 2 commits