1. 18 Jun, 2012 3 commits
  2. 17 Jun, 2012 1 commit
  3. 16 Jun, 2012 2 commits
  4. 15 Jun, 2012 12 commits
    • Vladislav Vaintroub's avatar
      merge · a71b65d2
      Vladislav Vaintroub authored
      a71b65d2
    • Sergei Golubchik's avatar
      MDEV-316 lp:1009085 Assertion failed: warn_item, file item_cmpfunc.cc, line 3613 · a247b12f
      Sergei Golubchik authored
      make sure that find_date_time_item() is called before agg_arg_charsets_for_comparison().
      optimize Item_func_conv_charset to avoid conversion if no string result is needed
      a247b12f
    • Vladislav Vaintroub's avatar
      MDEV-339, LP1001340 - system_time_zone is wrong on Windows · 99edca97
      Vladislav Vaintroub authored
      On localized Windows versions, Windows uses localized time zone names and contain non-ASCII characters.  non-ASCII characters appear broken when displayed by clients
      The fix is to declare system_time_zone variable to have UTF8 encoding and to convert tzname to UTF8.
      99edca97
    • Sergei Golubchik's avatar
      merged with XtraDB 1.1.8-26.0 · 37f56322
      Sergei Golubchik authored
      37f56322
    • Michael Widenius's avatar
      Automatic merge · 8ad377aa
      Michael Widenius authored
      8ad377aa
    • Michael Widenius's avatar
      Removed one variable from the test output that was depending on timing. · 4a23bb90
      Michael Widenius authored
      mysql-test/suite/sphinx/sphinx.result:
        Removed sphinx_time, as it was depending on timing.
      mysql-test/suite/sphinx/sphinx.test:
        Removed sphinx_time, as it was depending on timing.
      4a23bb90
    • Michael Widenius's avatar
      Fix for: lp:1013432 and MySQL#64800: · 7cd1dc5d
      Michael Widenius authored
      mysqldump with --include-master-host-port putting quotes around port number
      Patch from Stewart Smith
      
      client/mysqldump.c:
        Remove quotes from MASTER_PORT
      7cd1dc5d
    • Michael Widenius's avatar
      Fixed MDEV-306 / LP:1007967 - Assertion `table->file->stats.records > 0 ||... · acba7d2f
      Michael Widenius authored
      Fixed MDEV-306 / LP:1007967 - Assertion `table->file->stats.records > 0 || error' failed join_read_const_table on concurrent SELECT and DROP/ADD INDEX
      
      
      sql/sql_table.cc:
        Added comment
      storage/maria/ma_close.c:
        Don't store history if it's visible to all.
        This fixed the MDEV-306 bug
      storage/maria/ma_delete_table.c:
        Removed old comment
        Delete history state for deleted tables
      storage/maria/ma_info.c:
        More DBUG_PRINT
      storage/maria/ma_open.c:
        More DBUG_PRINT
      acba7d2f
    • unknown's avatar
      Fix bug lp:1008686 · db6dbadb
      unknown authored
      Analysis:
      The fix for bug lp:985667 implements the method Item_subselect::no_rows_in_result()
      for all main kinds of subqueries. The purpose of this method is to be called from
      return_zero_rows() and set Items to some default value in the case when a query
      returns no rows. Aggregates and subqueries require special treatment in this case.
      
      Every implementation of Item_subselect::no_rows_in_result() called
      Item_subselect::make_const() to set the subquery predicate to its default value
      irrespective of where the predicate was located in the query. Once the predicate
      was set to a constant it was never executed.
      
      At the same time, the JOIN object of the fake select for UNIONs (the one used for
      the final result of the UNION), was set after all subqueries in the union were
      executed. Since we set the subquery as constant, it was never executed, and the
      corresponding JOIN was never created.
      
      In order to decide whether the result of NOT IN is NULL or FALSE, Item_in_optimizer
      needs to check if the subquery result was empty or not. This is where we got the
      crash, because subselect_union_engine::no_rows() checks for
      unit->fake_select_lex->join->send_records, and the join object was NULL.
      
      Solution:
      If a subquery is in the HAVING clause it must be evaluated in order to know its
      result, so that we can properly filter the result records. Once subqueries in the
      HAVING clause are executed even in the case of no result rows, this specific
      crash will be solved, because the UNION will be executed, and its JOIN will be
      constructed. Therefore the fix for this crash is to narrow the fix for lp:985667,
      and to apply Item_subselect::no_rows_in_result() only when the subquery predicate
      is in the SELECT clause.
      db6dbadb
    • Sergei Golubchik's avatar
      comments · 13982b5a
      Sergei Golubchik authored
      13982b5a
    • Sergei Golubchik's avatar
      XtraDB 1.1.8-20.1 from · 6de57924
      Sergei Golubchik authored
      Percona-Server 5.5.24-rel26.0
      6de57924
    • Igor Babaev's avatar
      Fixed LP bug #1002157. · 1d74ae6b
      Igor Babaev authored
      The class Item_func missed an implementation of the virtual 
      function update_null_value.
      Back-ported the fix for bug 62125 from mysql 5.6 code line.
      The test case was also back-ported. 
      1d74ae6b
  5. 14 Jun, 2012 2 commits
    • Sergei Golubchik's avatar
      mysql-5.5 merge · 0522307e
      Sergei Golubchik authored
      0522307e
    • unknown's avatar
      Fix bug lp:1008773 · 88d3d853
      unknown authored
      Analysis:
      Queries with implicit grouping (there is aggregate, but no group by)
      follow some non-obvious semantics in the case of empty result set.
      Aggregate functions produce some special "natural" value depending on
      the function. For instance MIN/MAX return NULL, COUNT returns 0.
      
      The complexity comes from non-aggregate expressions in the select list.
      If the non-aggregate expression is a constant, it can be computed, so
      we should return its value, however if the expression is non-constant,
      and depends on columns from the empty result set, then the only meaningful
      value is NULL.
      
      The cause of the wrong result was that for subqueries the optimizer didn't
      make a difference between constant and non-constant ones in the case of
      empty result for implicit grouping.
      
      Solution:
      In all implementations of Item_subselect::no_rows_in_result() check if the
      subquery predicate is constant. If it is constant, do not set it to the
      default value for implicit grouping, instead let it be evaluated.
      88d3d853
  6. 13 Jun, 2012 2 commits
  7. 10 Jun, 2012 4 commits
  8. 09 Jun, 2012 1 commit
    • Igor Babaev's avatar
      Fixed LP bug #1010729. · 10f42e2c
      Igor Babaev authored
      The bug prevented acceptance of UNION queries whose non-first select 
      clauses contained join expressions with degenerated single-table nests
      as valid queries.
      The bug was introduced into mysql-5.5 code line by the patch for
      bug 33204.
      10f42e2c
  9. 08 Jun, 2012 5 commits
    • Michael Widenius's avatar
    • Michael Widenius's avatar
      Changed last_insert_id() to be unsigned. · 438e9eca
      Michael Widenius authored
      Fixed MDEV-331: last_insert_id() returns a signed number
      
      mysql-test/r/auto_increment.result:
        Added test case
      mysql-test/t/auto_increment.test:
        Added test case
      sql/item_func.h:
        Changed last_insert_id() to be unsigned.
      438e9eca
    • Vladislav Vaintroub's avatar
      LP1008334 : Speedup specific datetime queries that got slower with... · afe1ef5e
      Vladislav Vaintroub authored
      LP1008334 : Speedup specific datetime queries that got slower with introduction of microseconds in 5.3
      
      - Item::get_seconds() now skips decimal arithmetic, if decimals is 0. This significantly speeds up from_unixtime() if no fractional part is passed.
      - replace sprintfs used to format temporal values  by hand-coded formatting 
        
      Query1 (original query in the bug report)
      BENCHMARK(10000000,DATE_SUB(FROM_UNIXTIME(RAND() * 2147483648), INTERVAL (FLOOR(1 + RAND() * 365)) DAY)) 
        
      Query2 (Variation of query1 that does not use fractional part in FROM_UNIXTIME parameter)
      BENCHMARK(10000000,DATE_SUB(FROM_UNIXTIME(FLOOR(RAND() * 2147483648)), INTERVAL (FLOOR(1 + RAND() * 365)) DAY)) 
        
      Prior to the patch, the runtimes were (32 bit compilation/AMD machine)
      Query1: 41.53 sec 
      Query2: 23.90 sec
        
      With the patch, the runtimes are
      Query1: 32.32 sec (speed up due to removing sprintf)
      Query2: 12.06 sec (speed up due to skipping decimal arithmetic)
      afe1ef5e
    • Sergei Golubchik's avatar
      apply mysql fix for bug#58421 to XtraDB · d2ca6d2e
      Sergei Golubchik authored
      d2ca6d2e
    • unknown's avatar
      MDEV-329: MariaDB 5.5 does not use fdatasync(). · cb6109cd
      unknown authored
      The --debug-no-sync incorrectly defaulted to ON, disabling sync calls
      by default which can loose data or cause corruption. Also, the code
      used fsync() instead of the sometimes more efficient fdatasync().
      cb6109cd
  10. 07 Jun, 2012 1 commit
  11. 06 Jun, 2012 5 commits
  12. 05 Jun, 2012 1 commit
    • unknown's avatar
      Fixed bug lp:1000649 · f1ab0089
      unknown authored
      Analysis:
      
      When the method JOIN::choose_subquery_plan() decided to apply
      the IN-TO-EXISTS strategy, it set the unit and select_lex
      uncacheable flag to UNCACHEABLE_DEPENDENT_INJECTED unconditionally.
      As result, even if IN-TO-EXISTS injected non-correlated predicates,
      the subquery was still treated as correlated.
      
      Solution:
      Set the subquery as correlated only if the injected predicate(s) depend
      on the outer query.
      f1ab0089
  13. 04 Jun, 2012 1 commit