1. 09 Oct, 2006 1 commit
    • unknown's avatar
      Bug#8283 - OPTIMIZE TABLE causes data loss · 3109da77
      unknown authored
      OPTIMIZE TABLE with myisam_repair_threads > 1 performs a non-quick 
      parallel repair. This means that it does not only rebuild all 
      indexes, but also the data file.
      
      Non-quick parallel repair works so that there is one thread per 
      index. The first of the threads rebuilds also the new data file.
      
      The problem was that all threads shared the read io cache on the
      old data file. If there were holes (deleted records) in the table,
      the first thread skipped them, writing only contiguous, non-deleted
      records to the new data file. Then it built the new index so that
      its entries pointed to the correct record positions. But the other
      threads didn't know the new record positions, but put the positions
      from the old data file into the index.
      
      The new design is so that there is a shared io cache which is filled
      by the first thread (the data file writer) with the new contiguous
      records and read by the other threads. Now they know the new record
      positions.
      
      Another problem was that for the parallel repair of compressed
      tables a common bit_buff and rec_buff was used. I changed it so
      that thread specific buffers are used for parallel repair.
      
      A similar problem existed for checksum calculation. I made this
      multi-thread safe too.
      
      
      include/my_sys.h:
        Bug#8283 - OPTIMIZE TABLE causes data loss
        Redesign of io_cache_share.
      include/myisam.h:
        Bug#8283 - OPTIMIZE TABLE causes data loss
        Redesign of checksum calculation in mi_check.c.
        'calc_checksum' is now in myisamdef.h:st_mi_sort_param.
      myisam/mi_check.c:
        Bug#8283 - OPTIMIZE TABLE causes data loss
        Implemented a new parallel repair design.
        Using a synchronized shared read/write cache.
        Allowed for thread specific bit_buff, rec_buff, and calc_checksum.
      myisam/mi_open.c:
        Bug#8283 - OPTIMIZE TABLE causes data loss
        Added DBUG output.
      myisam/mi_packrec.c:
        Bug#8283 - OPTIMIZE TABLE causes data loss
        Allowed for thread specific bit_buff and rec_buff.
      myisam/myisamdef.h:
        Bug#8283 - OPTIMIZE TABLE causes data loss
        Commented on checksum calculation variables.
        Allowed for thread specific bit_buff.
        Added DBUG output for better table crash detection.
      myisam/sort.c:
        Bug#8283 - OPTIMIZE TABLE causes data loss
        Added implications of the new parallel repair design.
        Renamed 'info' -> 'sort_param'.
        Added DBUG output.
      mysql-test/r/myisam.result:
        Bug#8283 - OPTIMIZE TABLE causes data loss
        Added test results.
      mysql-test/t/myisam.test:
        Bug#8283 - OPTIMIZE TABLE causes data loss
        Added test cases.
      mysys/mf_iocache.c:
        Bug#8283 - OPTIMIZE TABLE causes data loss
        Redesign of io_cache_share.
        We do now allow a writer to synchronize himself with the
        readers of a shared cache. When all threads join in the lock,
        the writer copies the data from his write buffer to the shared
        read buffer.
      3109da77
  2. 09 Jul, 2006 1 commit
    • unknown's avatar
      BUG#20919 temp tables closing fails when binlog is off · 868fee4d
      unknown authored
      closing temp tables through end_thread
      had a flaw in binlog-off branch of close_temporary_tables where
      next table to close was reset via table->next
       for (table= thd->temporary_tables; table; table= table->next)
      which was wrong since the current table instance got destoyed at
      	close_temporary(table, 1);
      
      The fix adapts binlog-on branch method to engage the loop's internal 'next' variable which holds table->next prior table's destoying.
      
      
      
      sql/sql_base.cc:
        no-binlog branch is fixed: scanning across temporary_tables must be careful to save next table since the current is being destroyed inside of close_temporary. 
        binlog-is-open case is ok.
      868fee4d
  3. 29 Jun, 2006 1 commit
  4. 21 Jun, 2006 1 commit
  5. 20 Jun, 2006 5 commits
    • unknown's avatar
      Merge epotemkin@bk-internal.mysql.com:/home/bk/mysql-4.1 · 49042de5
      unknown authored
      into moonbone.local:/work/tmp_merge-4.1-opt-mysql
      
      
      49042de5
    • unknown's avatar
      select.result: · 3e7d68b1
      unknown authored
        Added test case for bug#18759 Incorrect string to numeric conversion.  
      select.test:
        Added test case for bug#18759 Incorrect string to numeric conversion.
      item_cmpfunc.cc:
        Cleanup after fix for bug#18360 removal
      
      
      sql/item_cmpfunc.cc:
        Cleanup after fix for bug#18360 removal
      mysql-test/t/select.test:
        Added test case for bug#18759 Incorrect string to numeric conversion.
      mysql-test/r/select.result:
        Added test case for bug#18759 Incorrect string to numeric conversion.
      3e7d68b1
    • unknown's avatar
      Merge mysql.com:/usr/home/ram/work/mysql-4.0 · 9a7da931
      unknown authored
      into  mysql.com:/usr/home/ram/work/mysql-4.1
      
      
      mysql-test/r/func_str.result:
        merge (ul)
      mysql-test/t/func_str.test:
        merge (ul)
      sql/item_strfunc.cc:
        merge (ul)
      sql/item_strfunc.h:
        merge (ul)
      9a7da931
    • unknown's avatar
      Merge rkalimullin@bk-internal.mysql.com:/home/bk/mysql-4.1 · 91a76683
      unknown authored
      into  mysql.com:/usr/home/ram/work/mysql-4.1
      
      
      91a76683
    • unknown's avatar
      Merge mysql.com:/users/lthalmann/bkroot/mysql-4.1 · 953ffa7d
      unknown authored
      into  mysql.com:/users/lthalmann/bk/MERGE/mysql-4.1-merge
      
      
      953ffa7d
  6. 19 Jun, 2006 9 commits
    • unknown's avatar
      Merge epotemkin@bk-internal.mysql.com:/home/bk/mysql-4.1-opt · 846c46ea
      unknown authored
      into moonbone.local:/work/tmp_merge-4.1-opt-mysql
      
      
      846c46ea
    • unknown's avatar
      Merge epotemkin@bk-internal.mysql.com:/home/bk/mysql-4.1 · 495c6b13
      unknown authored
      into moonbone.local:/work/tmp_merge-4.1-opt-mysql
      
      
      495c6b13
    • unknown's avatar
      item_cmpfunc.cc, func_in.result, func_in.test: · 028fa1e4
      unknown authored
        Reverted fix for bug#18360
      
      
      mysql-test/t/func_in.test:
        Reverted fix for bug#18360
      mysql-test/r/func_in.result:
        Reverted fix for bug#18360
      sql/item_cmpfunc.cc:
        Reverted fix for bug#18360
      028fa1e4
    • unknown's avatar
      Merge mysql.com:/home/kgeorge/mysql/4.1/teamclean · 6cf425b8
      unknown authored
      into  mysql.com:/home/kgeorge/mysql/4.1/B9676
      
      
      6cf425b8
    • unknown's avatar
      * Bug #9676: INSERT INTO x SELECT .. FROM x LIMIT 1; slows down with big · 124cb126
      unknown authored
                    tables
      Currently in INSERT ... SELECT ... LIMIT ... the compiler uses a 
      temporary table to store the results of SELECT ... LIMIT .. and then
      uses that table as a source for INSERT. The problem is that in some cases
      it actually skips the LIMIT clause in doing that and materializes the 
      whole SELECT result set regardless of the LIMIT.
      This fix is limiting the process of filling up the temp table with only 
      that much rows that will be actually used by propagating the LIMIT value.
      
      
      mysql-test/r/insert_select.result:
        * Bug #9676: INSERT INTO x SELECT .. FROM x LIMIT 1; slows down with big
                      tables
        - a test demonstrating the code path
      mysql-test/t/insert_select.test:
        * Bug #9676: INSERT INTO x SELECT .. FROM x LIMIT 1; slows down with big
                      tables
        - a test demonstrating the code path
      sql/sql_select.cc:
        * Bug #9676: INSERT INTO x SELECT .. FROM x LIMIT 1; slows down with big
                      tables
        - pass through the real LIMIT number if the temp table is created for
          buffering results.
        - set the counter for all the cases when the temp table is not used for
          grouping
      124cb126
    • unknown's avatar
      Merge mysql.com:/users/lthalmann/bkroot/mysql-4.1-rpl · e61fcf7c
      unknown authored
      into  mysql.com:/users/lthalmann/bk/MERGE/mysql-4.1-merge
      
      
      e61fcf7c
    • unknown's avatar
      Merge april:devel/BitKeeper/mysql-4.1 · 5375bcad
      unknown authored
      into  may.pils.ru:/home/svoj/devel/mysql/BUG18036/mysql-4.1
      
      
      5375bcad
    • unknown's avatar
      BUG#18036 - update of table joined to self reports table as crashed · 46cdd39e
      unknown authored
      Certain updates of table joined to self results in unexpected
      behavior.
      
      The problem was that record cache was mistakenly enabled for
      self-joined table updates. Normally record cache must be disabled
      for such updates.
      
      Fixed wrong condition in code that determines whether to use
      record cache for self-joined table updates.
      
      Only MyISAM tables were affected.
      
      
      mysql-test/r/myisam.result:
        Test case for BUG#18036.
      mysql-test/t/myisam.test:
        Test case for BUG#18036.
      sql/sql_update.cc:
        Fixed wrong condition in code that determines whether to use
        record cache for self-joined table updates.
      46cdd39e
    • unknown's avatar
      Fix for bug #20496: func_time.test failure · 95939476
      unknown authored
      
      mysql-test/r/func_time.result:
        Fix for bug #20496: func_time.test failure                                      
          - floating point calculations removed.
      mysql-test/t/func_time.test:
        Fix for bug #20496: func_time.test failure                                      
          - floating point calculations removed.
      95939476
  7. 18 Jun, 2006 1 commit
  8. 17 Jun, 2006 3 commits
    • unknown's avatar
      Makefile.am: · 4d366600
      unknown authored
        Avoid error message trying 'windoze-dsp' in obsolete directory
      compile-dist:
        Avoid error message for target 'distclean' and no Makefile
      
      
      BUILD/compile-dist:
        Avoid error message for target 'distclean' and no Makefile
      ndb/Makefile.am:
        Avoid error message trying 'windoze-dsp' in obsolete directory
      4d366600
    • unknown's avatar
      make_win_src_distribution.sh: · d1e21c2c
      unknown authored
        Make output less verbose
        Make temporary directory name unique
        Remove temporary directory on interrupt
      
      
      scripts/make_win_src_distribution.sh:
        Make output less verbose
        Make temporary directory name unique
        Remove temporary directory on interrupt
      d1e21c2c
    • unknown's avatar
      make_win_src_distribution.sh: · 4a4a82a4
      unknown authored
        Include "sql_yacc.yy" for completeness (bug#20387)
      
      
      scripts/make_win_src_distribution.sh:
        Include "sql_yacc.yy" for completeness (bug#20387)
        Improved error handling
        Don't list all files packed with tar/zip unless debugging
      4a4a82a4
  9. 16 Jun, 2006 3 commits
    • unknown's avatar
      Manually merged · d0f39b6a
      unknown authored
      
      sql/item_timefunc.cc:
        Auto merged
      sql/item_timefunc.h:
        Auto merged
      d0f39b6a
    • unknown's avatar
      .del-mysql_install.def~8da659e7c0f7e571: · e2d3943c
      unknown authored
        Delete: netware/mysql_install.def
      Makefile.am:
        Removed obsolete "mysql_install.def"
      
      
      netware/Makefile.am:
        Removed obsolete "mysql_install.def"
      BitKeeper/deleted/.del-mysql_install.def~8da659e7c0f7e571:
        Delete: netware/mysql_install.def
      e2d3943c
    • unknown's avatar
      item_strfunc.cc: · ca22a81b
      unknown authored
        Fix for bug#16716 for --ps-protocol mode.
      item_cmpfunc.cc:
        Fix for a memory allocation/freeing problem in agg_cmp_type() after fix
      for bug#16377. Few language corrections.
      
      
      sql/item_cmpfunc.cc:
        Fix for a memory allocation/freeing problem in agg_cmp_type(). Few language corrections.
      sql/item_strfunc.cc:
        Fix for bug#16716 for --ps-protocol mode.
      ca22a81b
  10. 15 Jun, 2006 5 commits
  11. 14 Jun, 2006 10 commits