1. 04 May, 2023 12 commits
  2. 03 May, 2023 9 commits
  3. 02 May, 2023 13 commits
  4. 30 Apr, 2023 1 commit
    • Igor Babaev's avatar
      MDEV-31143 Crash for query using ROWNUM() over view with ORDER BY · 7e2e9689
      Igor Babaev authored
      When processing a query over a mergeable view at some conditions checked
      at prepare stage it may be decided to materialize the view rather than
      to merge it. Before this patch in such case the field 'derived' of the
      TABLE_LIST structure created for the view remained set to 0. As a result
      the guard condition preventing range analysis for materialized views did
      not work properly. This led to a call of some handler method for the
      temporary table created to contain the view's records that was supposed
      to be used only for opened tables. However temporary tables created for
      materialization of derived tables or views are not opened yet when range
      analysis is performed.
      
      Approved by Oleksandr Byelkin <sanja@mariadb.com>
      7e2e9689
  5. 29 Apr, 2023 2 commits
  6. 28 Apr, 2023 3 commits
    • Angelique's avatar
      MDEV-30221: Move environmental macros to before master-slave · 1963a87b
      Angelique authored
      The fix was introduced, along with re-ordering to do other macros that check test environment capabilities before master/slave is set up.
      1963a87b
    • Sergei Petrunia's avatar
      MDEV-31067: selectivity_from_histogram >1.0 for a DOUBLE_PREC_HB histogram · 85cc8318
      Sergei Petrunia authored
      Variant #2.
      
      When Histogram::point_selectivity() sees that the point value of interest
      falls into one bucket, it tries to guess whether the bucket has many
      different (unpopular) values or a few popular values. (The number of
      rows is fixed, as it's a Height-balanced histogram).
      The basis for this guess is the "width" of the value range the bucket
      covers. Buckets covering wider value ranges are assumed to contain
      values with proportionally lower frequencies.
      
      This is just a [brave] guesswork. For a very narrow bucket, it may
      produce an estimate that's larger than total #rows in the bucket
      or even in the whole table.
      
      Remove the guesswork and replace it with basic logic: return
      either the per-table average selectivity of col=const, or selectivity
      of one bucket, whichever is lower.
      85cc8318
    • Sergei Petrunia's avatar
      MDEV-30812: Improve output cardinality estimates for hash join · 4329ec5d
      Sergei Petrunia authored
      Introduce @@optimizer_switch flag: hash_join_cardinality
      
      When it is on, use EITS statistics to produce tighter bounds for
      hash join output cardinality.
      
      Amended by Monty.
      
      Reviewed by: Monty <monty@mariadb.org>
      4329ec5d