1. 08 Oct, 2015 3 commits
    • Alexander Barkov's avatar
      MDEV-8918 Wrong result for CAST(AVG(bigint_column) AS SIGNED) · 7091b785
      Alexander Barkov authored
      - Moving Item_xxx_field declarations after Item_sum_xxx declarations,
        so Item_xxx_field constructors can be defined directly in item_sum.h
        rather than item_sum.cc. This removes some duplicate code, e.g.
        initialization of the following members at constructor time:
        name, decimals, max_length, unsigned_flag, field, maybe_null.
      - Adding Item_sum_field as a common parent for Item_avg_field and
        Item_variance_field
      - Deriving Item_sum_field directly from Item rather that Item_result_field,
        as Item_sum_field descendants do not need anything from Item_result_field.
      - Removing hybrid infrastructure from Item_avg_field,
        adding Item_avg_field_decimal and Item_avg_field_double instead,
        as desired result type is already known at constructor time
        (not only at fix_fields time). This simplifies the code.
      - Changing Item_avg_field_decimal::val_int() to call val_int_from_decimal()
        instead of doing { return (longlong) rint(val_real()); }
        This is the fix itself.
      7091b785
    • Alexander Barkov's avatar
      Clean-up: Item_sum_variance and Item_variance_field had hybrid type · 174a0b9e
      Alexander Barkov authored
      infrastructure, though in fact they always return REAL result.
      Removing hybrid type artifacts.
      174a0b9e
    • Alexander Barkov's avatar
      A clean-up for a few recent result set metadata related bug fixes: · de1a48e7
      Alexander Barkov authored
      - MDEV-8875 Wrong metadata for MAX(CAST(time_column AS DATETIME))
      - MDEV-8873 Wrong field type or metadata for LEAST(int_column,string_column)
      - MDEV-8912 Wrong metadata or type for @c:=string_or_blob_field
      
      Adding Item_hybrid_func as a common parent for Item_func_hybrid_field_type,
      Item_func_min_max, Item_func_user_var. This removes some duplicate code.
      de1a48e7
  2. 07 Oct, 2015 2 commits
  3. 06 Oct, 2015 3 commits
    • Oleksandr Byelkin's avatar
      MDEV-8380: Subquery parse error · bed4e847
      Oleksandr Byelkin authored
      backport mysql parser fixes
      0034963fbf199696792491bcb79d5f0731c98804
      5948561812bc691bd0c13cf518a3fe77d9daf920
      bed4e847
    • Sergei Petrunia's avatar
      Combined fix for MDEV-7267 and MDEV-8864 · d6371d3a
      Sergei Petrunia authored
      The problem was that GROUP BY code created Item_field objects
      that referred to fields in the temp. tables used for GROUP BY.
      
      Item_ref and set_items_ref_array() call caused pointers to temp.
      table fields to occur in many places.
      
      This patch introduces Item_temptable_field, which can handle
      item->print() calls made after the underlying table is freed.
      d6371d3a
    • Jan Lindström's avatar
      MDEV-8901: InnoDB: Punch hole is incorrecty done also to log files causing... · 21adad00
      Jan Lindström authored
      MDEV-8901: InnoDB: Punch hole is incorrecty done also to log files causing assertion and database corruption
      
      Analysis: Problem is that punch hole does not know the actual page size
      of the page and does the page belong to an data file or to a log file.
      
      Fix: Pass down the file type and page size to os layer to be used
      when trim is called. Also fix unsafe null pointer access to
      actual write_size.
      21adad00
  4. 05 Oct, 2015 24 commits
  5. 04 Oct, 2015 1 commit
    • Alexander Barkov's avatar
      A clean-up for MDEV-7950: · ba0b6685
      Alexander Barkov authored
      - Turning get_mm_tree_for_const() from a static function into
        a protected method in Item.
      - Adding a new class Item_bool_func2_with_rev, for the functions and operators
        that have a reverse function and can use the range optimizer for
        to optimize "value OP field" as "field REV_OP value". Deriving
        Item_bool_rowready_func2 and Item_funt_spatial_rel from the new class.
      - Removing Item_bool_func2::have_rev_func().
      ba0b6685
  6. 02 Oct, 2015 5 commits
  7. 01 Oct, 2015 2 commits