1. 22 Dec, 2006 1 commit
    • unknown's avatar
      Bug#22555: STDDEV yields positive result for groups with only one row · 82bd9b6b
      unknown authored
      When only one row was present, the subtraction of nearly the same number 
      resulted in catastropic cancellation, introducing an error in the 
      VARIANCE calculation near 1e-15.  That was sqrt()ed to get STDDEV, the 
      error was escallated to near 1e-8.  
      
      The simple fix of testing for a row count of 1 and forcing that to yield 
      0.0 is insufficient, as two rows of the same value should also have a
      variance of 0.0, yet the error would be about the same.
      
      So, this patch changes the formula that computes the VARIANCE to be one
      that is not subject to catastrophic cancellation.
      
      In addition, it now uses only (faster-than-decimal) floating point numbers
      to calculate, and renders that to other types on demand.
      
      
      mysql-test/r/func_group.result:
        Test that the bug is fixed, and that no unexpected behavior arises from the 
        changes.
      mysql-test/t/func_group.test:
        Test that the bug is fixed, and that no unexpected behavior arises from the 
        changes.
      sql/item_sum.cc:
        Serg's suggestion: Force all VARIANCE calculations to be done with floating-
        point types.  It's faster, and the SQL standard says we may implement these
        functions any way we want.
        
        Additionally, use a form of variance calculation that is not subject to 
        catastrophic cancellation.   
        http://static.flickr.com/108/311308512_5c4e1c0c3d_b.jpg
      sql/item_sum.h:
        Remove unused members and add a comment describing the recurrence relation.
      82bd9b6b
  2. 11 Nov, 2006 1 commit
  3. 10 Nov, 2006 1 commit
    • unknown's avatar
      Bug #22860: Option --memlock should be revisited · 93e1030d
      unknown authored
      Support says that memlock doesn't work on OSes other than Solaris.  
      Add a warning about --memlock to the crash monologue.
      
      
      sql/mysqld.cc:
        On a crash when --memlock was active, emit advice about the insta-
        bility of that parameter.
      93e1030d
  4. 08 Nov, 2006 1 commit
    • unknown's avatar
      Bug#10963: LEFT/RIGHT/SUBSTR/.. string functions returns wrong result \ · 3a867382
      unknown authored
        on large length
        
      Problem:  Most (all) of the numeric inputs were being coerced into
      int (32 bit) sized variables.  Works OK for sane inputs; any input
      larger than 2^32 (or 2^31 for signed vars) exihibited predictable
      wrapping behavior (up to about 10^18) and then started having really
      strange behaviour past that point (since the conversion to 64 bit int
      from the DECIMAL type can do weird things on out of range numbers).
      
      Solution: 1)  Add many tests.  2)  Convert input from (u)long type to
      (u)longlong.  3)  Do (sometimes multiple) sanity checks on input,
      keeping in mind that sometimes a negative longlong is not a negative
      longlong (if the unsigned_flag is set).  4) Emulate existing behavior
      w/rt negative and "small" out-of-bounds values.
      
      
      mysql-test/r/func_str.result:
        Additional test results for #10963
      mysql-test/t/func_str.test:
        Additional test results for #10963
      sql/item_func.cc:
        Used larger type for counting, to avoid truncation.
      sql/item_strfunc.cc:
        Fix for #10963, including comments and cleaned up logic
      3a867382
  5. 07 Nov, 2006 2 commits
  6. 06 Nov, 2006 3 commits
    • unknown's avatar
      Merge zippy.cornsilk.net:/home/cmiller/work/mysql/bug23411/my41-bug23411 · 02e764bd
      unknown authored
      into  zippy.cornsilk.net:/home/cmiller/work/mysql/mysql-4.1-maint
      
      
      02e764bd
    • unknown's avatar
      Merge zippy.cornsilk.net:/home/cmiller/work/mysql/bug23411/my41-bug23411 · 8f8ee04b
      unknown authored
      into  zippy.cornsilk.net:/home/cmiller/work/mysql/bug23411/my50-bug23411
      
      
      BitKeeper/deleted/.del-collapsed~fbec3523369aae99:
        Delete: BitKeeper/etc/collapsed
      BitKeeper/etc/collapsed:
        'Auto converge'
      mysql-test/r/func_test.result:
        Manual merge.
      mysql-test/t/func_test.test:
        Manual merge.
      sql/item_func.cc:
        Manual merge.
      8f8ee04b
    • unknown's avatar
      Bug#23411: ... MOD-ing zero returns strange result · 2b35fee8
      unknown authored
        
      The Item_func_mod objects never had maybe_null set, so users had no reason 
      to expect that they can be NULL, and may therefore deduce wrong results.
      Now, set maybe_null.
      
      
      mysql-test/r/func_test.result:
        Verify that the predictions are true.
      mysql-test/t/func_test.test:
        Verify that the predictions are true.
      sql/item_func.cc:
        MOD functions may be NULL.
      2b35fee8
  7. 04 Nov, 2006 4 commits
  8. 03 Nov, 2006 12 commits
  9. 02 Nov, 2006 15 commits
    • unknown's avatar
      Fix merge collision. · 65e36462
      unknown authored
      65e36462
    • unknown's avatar
      Merge bk-internal.mysql.com:/home/bk/mysql-5.0 · f0364b7b
      unknown authored
      into  zippy.cornsilk.net:/home/cmiller/work/mysql/mysql-5.0-maint
      
      
      mysql-test/r/innodb_mysql.result:
        Auto merged
      mysql-test/r/view.result:
        Auto merged
      mysql-test/t/ctype_utf8.test:
        Auto merged
      mysql-test/t/im_daemon_life_cycle.imtest:
        Auto merged
      mysql-test/t/innodb_mysql.test:
        Auto merged
      mysql-test/t/sp-error.test:
        Auto merged
      mysql-test/t/sp.test:
        Auto merged
      mysql-test/t/view.test:
        Auto merged
      sql/ha_innodb.cc:
        Auto merged
      sql/handler.cc:
        Auto merged
      sql/item_func.cc:
        Auto merged
      sql/mysqld.cc:
        Auto merged
      sql/set_var.cc:
        Auto merged
      sql/sp.cc:
        Auto merged
      sql/sql_class.h:
        Auto merged
      sql/sql_delete.cc:
        Auto merged
      sql/sql_lex.cc:
        Auto merged
      sql/sql_lex.h:
        Auto merged
      sql/sql_parse.cc:
        Auto merged
      sql/sql_prepare.cc:
        Auto merged
      sql/sql_select.cc:
        Auto merged
      sql/sql_table.cc:
        Auto merged
      sql/sql_trigger.cc:
        Auto merged
      sql/sql_union.cc:
        Auto merged
      sql/sql_view.cc:
        Auto merged
      sql/sql_yacc.yy:
        Auto merged
      sql/table.cc:
        Auto merged
      tests/mysql_client_test.c:
        Auto merged
      mysql-test/mysql-test-run.pl:
        Manual merge.
      mysql-test/r/ps.result:
        Manual merge.
      mysql-test/t/ps.test:
        Manual merge.
      f0364b7b
    • unknown's avatar
      Merge bk-internal.mysql.com:/home/bk/mysql-4.1 · e1a722b2
      unknown authored
      into  zippy.cornsilk.net:/home/cmiller/work/mysql/mysql-4.1-maint
      
      
      configure.in:
        Auto merged
      mysql-test/t/ps.test:
        Auto merged
      sql/handler.cc:
        Auto merged
      sql/sql_delete.cc:
        Auto merged
      sql/sql_select.cc:
        Auto merged
      sql/table.cc:
        Auto merged
      tests/mysql_client_test.c:
        Auto merged
      myisam/sort.c:
        Manual merge.
      mysql-test/r/innodb_mysql.result:
        Manual merge.
      mysql-test/t/innodb_mysql.test:
        Manual merge.
      mysys/mf_iocache.c:
        Manual merge.
      e1a722b2
    • unknown's avatar
      Merge bk-internal:/home/bk/mysql-4.1-maint · 2772d9e1
      unknown authored
      into  shellback.(none):/home/msvensson/mysql/mysql-4.1-maint
      
      
      2772d9e1
    • unknown's avatar
      configure.in: · 24232ff0
      unknown authored
        Raise version number to 4.1.23
      
      
      configure.in:
        Raise version number to 4.1.23
      24232ff0
    • unknown's avatar
      Merge rolltop.ignatz42.dyndns.org:/mnt/storeage/mtr_vs_config/my50-mtr_vs_config · a04d3827
      unknown authored
      into  rolltop.ignatz42.dyndns.org:/mnt/storeage/mysql-5.0-maint
      
      
      mysql-test/mysql-test-run.pl:
        Auto merged
      a04d3827
    • unknown's avatar
      Merge rolltop.ignatz42.dyndns.org:/mnt/storeage/mtr_vs_config/my41-mtr_vs_config · 75bde223
      unknown authored
      into  rolltop.ignatz42.dyndns.org:/mnt/storeage/mtr_vs_config/my50-mtr_vs_config
      
      
      mysql-test/mysql-test-run.pl:
        Auto merged
      mysql-test/lib/mtr_misc.pl:
        manual merge
      75bde223
    • unknown's avatar
      Bug#23865 mysql-test-run.pl on Windows only supports debug and release configurations · 8e6b1e38
      unknown authored
      Visual Studio builds each configuration in a different sub-directory.  Only the sub-
      directories for release and debug are currently searched.
      
      
      mysql-test/lib/mtr_misc.pl:
        Bug#23865 mysql-test-run.pl on Windows only supports debug and release configurations
        - Added usage comments.
      mysql-test/mysql-test-run.pl:
        Bug#23865 mysql-test-run.pl on Windows only supports debug and release configurations
        - Moved Initial_Setup function to the command_line_setup function.
        - Defined new argument vs-config which can be used to inidicate the VS Configuration
        used to create the test executables. Argument can also be controlled with
        MTR_VS_CONFIG environment variable.
      8e6b1e38
    • unknown's avatar
      Merge kpettersson@bk-internal:/home/bk/mysql-5.0-maint · fef32d41
      unknown authored
      into  kpdesk.mysql.com:/home/thek/dev/mysql-5.0-maint
      
      
      fef32d41
    • unknown's avatar
      Merge kpettersson@bk-internal:/home/bk/mysql-4.1-maint · aae0caf6
      unknown authored
      into  kpdesk.mysql.com:/home/thek/dev/mysql-4.1-maint
      
      
      aae0caf6
    • unknown's avatar
      Bug#22828 complementary patch: · 4868875c
      unknown authored
      - 'false' not defined in C, use FALSE instead.
      
      
      mysys/my_lock.c:
        Fixed error in windows built:
        'false' not defined in C, use FALSE instead.
      4868875c
    • unknown's avatar
      Bug#22828 complementary patch: · d6e7fa92
      unknown authored
      - 'false' not defined in C, use FALSE instead.
      
      
      mysys/my_lock.c:
        Fixed error for windwos built:
        'false' not defined in C, use FALSE instead.
      d6e7fa92
    • unknown's avatar
      Merge rkalimullin@bk-internal.mysql.com:/home/bk/mysql-4.1-maint · e9f182b3
      unknown authored
      into  mysql.com:/usr/home/ram/work/bug22913/my41-bug22913
      
      
      client/mysql.cc:
        Auto merged
      e9f182b3
    • unknown's avatar
      Merge rkalimullin@bk-internal.mysql.com:/home/bk/mysql-5.0-maint · fb81240f
      unknown authored
      into  mysql.com:/usr/home/ram/work/bug22913/my50-bug22913
      
      
      client/mysql.cc:
        Auto merged
      fb81240f
    • unknown's avatar
      Merge mysql.com:/usr/home/ram/work/bug22913/my41-bug22913 · 9d85df0b
      unknown authored
      into  mysql.com:/usr/home/ram/work/bug22913/my50-bug22913
      
      
      client/mysql.cc:
        Auto merged
      9d85df0b