Skip to content

Commit 27a3366

Browse files
committed
Merge 10.6 into 10.11
2 parents 77c465d + c9212b7 commit 27a3366

File tree

372 files changed

+7663
-6515
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

372 files changed

+7663
-6515
lines changed

cmake/maintainer.cmake

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,15 +27,17 @@ SET(MY_WARNING_FLAGS
2727
-Wenum-conversion
2828
-Wextra
2929
-Wformat-security
30+
-Winconsistent-missing-override
3031
-Wmissing-braces
3132
-Wno-format-truncation
3233
-Wno-init-self
3334
-Wno-nonnull-compare
3435
-Wno-null-conversion
3536
-Wno-unused-parameter
3637
-Wno-unused-private-field
37-
-Woverloaded-virtual
3838
-Wnon-virtual-dtor
39+
-Woverloaded-virtual
40+
-Wsuggest-override
3941
-Wvla
4042
-Wwrite-strings
4143
)

extra/perror.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -359,7 +359,8 @@ int main(int argc,char *argv[])
359359
{
360360
found= 1;
361361
if (verbose)
362-
printf("MariaDB error code %3d (%s): %s\n", code, name, msg);
362+
printf("MariaDB error code %3d (%s): %s\n"
363+
"Learn more: https://mariadb.com/kb/en/e%3d/\n", code, name, msg, code);
363364
else
364365
puts(msg);
365366
}

mysql-test/include/log_slow_grep.inc

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,5 +21,10 @@
2121
--source include/log_grep.inc
2222

2323
# InnoDB/Engines
24-
--let log_expected_matches = $log_slow_innodb_expected_matches
25-
--let grep_pattern = ^# Pages_accessed: \d+ Pages_read: \d+ Pages_updated: \d+ Old_rows_read: \d+\n# Pages_read_time: \d+\.\d+ Engine_time: \d+\.\d+\$
24+
--let log_expected_matches = $log_slow_verbosity_innodb_expected_matches
25+
--let grep_pattern = ^# Pages_accessed: \d+ Pages_read: \d+ Pages_updated: \d+ Old_rows_read: \d+\$
26+
--source include/log_grep.inc
27+
28+
--let grep_pattern = ^# Pages_read_time: \d+\.\d+ Engine_time: \d+\.\d+\$
29+
--source include/log_grep.inc
30+

mysql-test/main/ctype_uca.result

Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15370,3 +15370,39 @@ DROP TABLE t1;
1537015370
#
1537115371
# End of MariaDB-10.2 tests
1537215372
#
15373+
#
15374+
# Start of 10.5 tests
15375+
#
15376+
#
15377+
# MDEV-34417 Wrong result set with utf8mb4_danish_ci and BNLH join
15378+
#
15379+
CREATE TABLE t1 (a VARCHAR(500) CHARACTER SET utf8mb4 COLLATE utf8mb4_danish_ci);
15380+
INSERT INTO t1 VALUES ('aaaa'),('åå');
15381+
SELECT * FROM t1 WHERE a='aaaa';
15382+
a
15383+
aaaa
15384+
åå
15385+
SET join_cache_level=1;
15386+
SELECT * FROM t1 NATURAL JOIN t1 t2;
15387+
a
15388+
aaaa
15389+
åå
15390+
aaaa
15391+
åå
15392+
# Expect a BNHL join
15393+
SET join_cache_level=3;
15394+
EXPLAIN SELECT * FROM t1 NATURAL JOIN t1 t2;
15395+
id select_type table type possible_keys key key_len ref rows Extra
15396+
1 SIMPLE t1 ALL NULL NULL NULL NULL 2 Using where
15397+
1 SIMPLE t2 hash_ALL NULL #hash#$hj 2003 test.t1.a 2 Using where; Using join buffer (flat, BNLH join)
15398+
SELECT * FROM t1 NATURAL JOIN t1 t2;
15399+
a
15400+
aaaa
15401+
åå
15402+
aaaa
15403+
åå
15404+
DROP TABLE t1;
15405+
SET join_cache_level=DEFAULT;
15406+
#
15407+
# End of 10.5 tests
15408+
#

mysql-test/main/ctype_uca.test

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -696,3 +696,32 @@ DROP TABLE t1;
696696
--echo #
697697
--echo # End of MariaDB-10.2 tests
698698
--echo #
699+
700+
701+
--echo #
702+
--echo # Start of 10.5 tests
703+
--echo #
704+
705+
--echo #
706+
--echo # MDEV-34417 Wrong result set with utf8mb4_danish_ci and BNLH join
707+
--echo #
708+
709+
CREATE TABLE t1 (a VARCHAR(500) CHARACTER SET utf8mb4 COLLATE utf8mb4_danish_ci);
710+
INSERT INTO t1 VALUES ('aaaa'),('åå');
711+
SELECT * FROM t1 WHERE a='aaaa';
712+
713+
SET join_cache_level=1;
714+
SELECT * FROM t1 NATURAL JOIN t1 t2;
715+
716+
--echo # Expect a BNHL join
717+
SET join_cache_level=3;
718+
EXPLAIN SELECT * FROM t1 NATURAL JOIN t1 t2;
719+
SELECT * FROM t1 NATURAL JOIN t1 t2;
720+
721+
DROP TABLE t1;
722+
SET join_cache_level=DEFAULT;
723+
724+
725+
--echo #
726+
--echo # End of 10.5 tests
727+
--echo #

mysql-test/main/func_misc.result

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1746,3 +1746,16 @@ RELEASE_ALL_LOCKS()
17461746
SELECT LOCK_MODE, LOCK_TYPE, TABLE_SCHEMA
17471747
FROM information_schema.metadata_lock_info WHERE thread_id>0 ORDER BY TABLE_SCHEMA;
17481748
LOCK_MODE LOCK_TYPE TABLE_SCHEMA
1749+
#
1750+
# MDEV-32583 UUID() should be treated as stochastic for the purposes of
1751+
# forcing query materialization
1752+
#
1753+
create table t1 as WITH cte AS (SELECT UUID() as r FROM seq_1_to_10)
1754+
SELECT r as r1, r FROM cte;
1755+
select count(*) from t1 where r1!=r;
1756+
count(*)
1757+
0
1758+
drop table t1;
1759+
#
1760+
# End of 10.5 tests
1761+
#

mysql-test/main/func_misc.test

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1367,3 +1367,18 @@ FROM information_schema.metadata_lock_info WHERE thread_id>0 ORDER BY TABLE_SCHE
13671367

13681368
--enable_ps2_protocol
13691369
--enable_view_protocol
1370+
1371+
--echo #
1372+
--echo # MDEV-32583 UUID() should be treated as stochastic for the purposes of
1373+
--echo # forcing query materialization
1374+
--echo #
1375+
1376+
--source include/have_sequence.inc
1377+
create table t1 as WITH cte AS (SELECT UUID() as r FROM seq_1_to_10)
1378+
SELECT r as r1, r FROM cte;
1379+
select count(*) from t1 where r1!=r;
1380+
drop table t1;
1381+
1382+
--echo #
1383+
--echo # End of 10.5 tests
1384+
--echo #

mysql-test/main/having_cond_pushdown.result

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5565,4 +5565,16 @@ SELECT a,b FROM t1 GROUP BY a,b HAVING a = (b IS NULL);
55655565
a b
55665566
0 11
55675567
DROP TABLE t1;
5568+
#
5569+
# MDEV-19520 Extend condition normalization to include 'NOT a'
5570+
# having Item_func_not in item tree breaks assumptions during the
5571+
# optimization phase about transformation possibilities in fix_fields().
5572+
# Remove Item_func_not by extending normalization during parsing.
5573+
#
5574+
CREATE TABLE t1 (a INT);
5575+
INSERT INTO t1 VALUES (0),(1);
5576+
SELECT a FROM t1 GROUP BY a HAVING NOT a;
5577+
a
5578+
0
5579+
DROP TABLE t1;
55685580
End of 10.4 tests

mysql-test/main/having_cond_pushdown.test

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1489,4 +1489,16 @@ SELECT a,b FROM t1 GROUP BY a,b HAVING a = (b IS NULL);
14891489

14901490
DROP TABLE t1;
14911491

1492+
--echo #
1493+
--echo # MDEV-19520 Extend condition normalization to include 'NOT a'
1494+
--echo # having Item_func_not in item tree breaks assumptions during the
1495+
--echo # optimization phase about transformation possibilities in fix_fields().
1496+
--echo # Remove Item_func_not by extending normalization during parsing.
1497+
--echo #
1498+
1499+
CREATE TABLE t1 (a INT);
1500+
INSERT INTO t1 VALUES (0),(1);
1501+
SELECT a FROM t1 GROUP BY a HAVING NOT a;
1502+
DROP TABLE t1;
1503+
14921504
--echo End of 10.4 tests

mysql-test/main/log_slow_innodb.result

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,10 @@ UPDATE t1 set b=b+1 where a=1 or a=999;
2323
[log_grep.inc] lines: 0
2424
[log_grep.inc] file: log_slow_innodb-verbosity_1 pattern: ^# Tmp_tables: \d+ Tmp_disk_tables: \d+$
2525
[log_grep.inc] lines: 0
26+
[log_grep.inc] file: log_slow_innodb-verbosity_1 pattern: ^# Pages_accessed: \d+ Pages_read: \d+ Pages_updated: \d+ Old_rows_read: \d+$ expected_matches: 2
27+
[log_grep.inc] found expected match count: 2
28+
[log_grep.inc] file: log_slow_innodb-verbosity_1 pattern: ^# Pages_read_time: \d+\.\d+ Engine_time: \d+\.\d+$ expected_matches: 2
29+
[log_grep.inc] found expected match count: 2
2630
SET SESSION log_slow_verbosity='innodb,query_plan';
2731
[slow_log_start.inc] log_slow_innodb-verbosity_2
2832
SELECT 1;
@@ -43,6 +47,10 @@ SELECT 1;
4347
[log_grep.inc] lines: 0
4448
[log_grep.inc] file: log_slow_innodb-verbosity_2 pattern: ^# Tmp_tables: \d+ Tmp_disk_tables: \d+$
4549
[log_grep.inc] lines: 0
50+
[log_grep.inc] file: log_slow_innodb-verbosity_2 pattern: ^# Pages_accessed: \d+ Pages_read: \d+ Pages_updated: \d+ Old_rows_read: \d+$
51+
[log_grep.inc] lines: 0
52+
[log_grep.inc] file: log_slow_innodb-verbosity_2 pattern: ^# Pages_read_time: \d+\.\d+ Engine_time: \d+\.\d+$
53+
[log_grep.inc] lines: 0
4654
SET SESSION log_slow_verbosity='query_plan';
4755
[log_slow_stop.inc] log_slow_innodb-verbosity_3
4856
--source include/log_slow_start.inc
@@ -75,4 +83,12 @@ INSERT INTO t1 VALUE(1000) pattern: ^# Filesort: (Yes|No) Filesort_on_disk: (Ye
7583
--source include/log_slow_start.inc
7684
INSERT INTO t1 VALUE(1000) pattern: ^# Tmp_tables: \d+ Tmp_disk_tables: \d+$
7785
[log_grep.inc] lines: 0
86+
[log_grep.inc] file: log_slow_innodb-verbosity_3
87+
--source include/log_slow_start.inc
88+
INSERT INTO t1 VALUE(1000) pattern: ^# Pages_accessed: \d+ Pages_read: \d+ Pages_updated: \d+ Old_rows_read: \d+$
89+
[log_grep.inc] lines: 0
90+
[log_grep.inc] file: log_slow_innodb-verbosity_3
91+
--source include/log_slow_start.inc
92+
INSERT INTO t1 VALUE(1000) pattern: ^# Pages_read_time: \d+\.\d+ Engine_time: \d+\.\d+$
93+
[log_grep.inc] lines: 0
7894
DROP TABLE t1;

0 commit comments

Comments
 (0)