maria:bb-10.5-mdev-33174-gold

Last commit made on 2024-01-29
Get this branch:
git clone -b bb-10.5-mdev-33174-gold https://git.launchpad.net/maria

Branch merges

Branch information

Name:
bb-10.5-mdev-33174-gold
Repository:
lp:maria

Recent commits

b8acdfe... by Yuchen Pei <email address hidden>

MDEV-33174 Fixing nondeterministic self-referencing test result

354e97c... by VladislavVaintroub

Fix mtr for builds without perfschema.

97fcafb... by Alexander Barkov

MDEV-32837 long unique does not work like unique key when using replace

write_record() when performing REPLACE has an optimization:
- if the unique violation happened in the last unique key, then do UPDATE
- otherwise, do DELETE+INSERT

This patch changes the way of detecting if this optimization
can be applied if the table has long (hash based) unique
(i.e. UNIQUE..USING HASH) constraints.

Problem:

The old condition did not take into account that
TABLE_SHARE and TABLE see long uniques differently:
- TABLE_SHARE sees as HA_KEY_ALG_LONG_HASH and HA_NOSAME
- TABLE sees as usual non-unique indexes
So the old condition could erroneously decide that the UPDATE optimization
is possible when there are still some unique hash constraints in the table.

Fix:

- If the current key is a long unique, it now works as follows:

  UPDATE can be done if the current long unique is the last
  long unique, and there are no in-engine (normal) uniques.

- For in-engine uniques nothing changes, it still works as before:

  If the current key is an in-engine (normal) unique:
  UPDATE can be done if it is the last normal unique.

a7ee3bc... by Sergei Golubchik

MDEV-29954 Unique hash key on column prefix is computed incorrectly

use the original, not the truncated, field in the long unique prefix,
that is, in the hash(left(field, length)) expression.

because MyISAM CHECK/REPAIR in compute_vcols() moves table->field
but not prefix fields from keyparts.

Also, implement Field_string::cmp_prefix() for prefix comparison
of CHAR columns to work.

14d00fd... by Sergei Golubchik

cleanup: MY_STRNNCOLLSP_NCHARS_EMULATE_TRIMMED_TRAILING_SPACES

no need to use it when both arguments have the same length

8bb4648... by Sergei Golubchik

cleanup: unused and undefined methods

dcb814c... by Sergei Golubchik

MDEV-11628 mysql.slow_log reports incorrect start time

use thd->start_time for the "start_time" column of the slow_log table.
"current_time" here refers to the current_time() function return value
not to the actual *current* time.

also fixes
MDEV-33267 User with minimal permissions can intentionally corrupt mysql.slow_log table

db9fad1... by Sergei Golubchik

cleanup: main.log_tables test

2bc940f... by Sergei Golubchik

disable perfschema in mtr bootstrap

should fix numerous failures of main.bootstrap tets

81d0185... by Alexander Barkov

MDEV-28651 quote(NULL) returns incorrect result in view ('NU' instead of 'NULL')

Item_func_quote did not calculate its max_length correctly for nullable
arguments.

Fix:

In case if the argument is nullable, reserve at least 4 characters
so the string "NULL" fits.