diff options
author | Marko Mäkelä <marko.makela@mariadb.com> | 2022-01-04 10:30:45 +0200 |
---|---|---|
committer | Marko Mäkelä <marko.makela@mariadb.com> | 2022-01-04 10:30:45 +0200 |
commit | daf4fa5238a67fcf47075721d86d4348adab687b (patch) | |
tree | fff85b8f2e11607c93d806e787475ad82f5055f6 /mysql-test/main/order_by_innodb.test | |
parent | 756568f26c6a23c537f4d93ff00f485c6291c92e (diff) | |
parent | 7dfaded9625e832fade4ef1678bcb21c445dad2b (diff) | |
download | mariadb-git-st-10.8-merge.tar.gz |
Merge 10.7 into 10.8st-10.8-merge
Diffstat (limited to 'mysql-test/main/order_by_innodb.test')
-rw-r--r-- | mysql-test/main/order_by_innodb.test | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/mysql-test/main/order_by_innodb.test b/mysql-test/main/order_by_innodb.test index 97c043b8dbc..af12644c073 100644 --- a/mysql-test/main/order_by_innodb.test +++ b/mysql-test/main/order_by_innodb.test @@ -184,6 +184,28 @@ from order by dd.d1 desc, dd.d2 desc, dd.id desc limit 1 ); + +--echo # +--echo # MDEV-27270: Wrong query plan with Range Checked for Each Record and ORDER BY ... LIMIT +--echo # + +--echo # This must NOT have "Range checked for each record" without any +--echo # provisions to produce rows in the required ordering: +--replace_column 9 # +explain +select + t1.id,t2.id +from + t1 left join + t2 on t2.id2 = t1.id and + t2.id = (select dd.id + from t2 dd + where + dd.id2 = t1.id and + d1 > '2019-02-06 00:00:00' + order by + dd.d1, dd.d2, dd.id limit 1 + ); drop table t1,t2; --echo # End of 10.2 tests |