diff options
author | Alexey Botchkov <holyfoot@askmonty.org> | 2017-12-18 15:21:50 +0400 |
---|---|---|
committer | Alexey Botchkov <holyfoot@askmonty.org> | 2017-12-18 15:21:50 +0400 |
commit | 6ee9cba74502e2da628ac72b21ce42570ff361b9 (patch) | |
tree | e66fbd85b9513035eca06662a4ad59c4bf0596bc /mysql-test/suite | |
parent | ef9e78c9d41a5ac644f08068e3dabad948b0e30a (diff) | |
download | mariadb-git-6ee9cba74502e2da628ac72b21ce42570ff361b9.tar.gz |
MDEV-10486 MariaDB 10.x does not update rows_examined in performance_schema tables.
Save the rows_examined counter before it gets emptied.
Diffstat (limited to 'mysql-test/suite')
-rw-r--r-- | mysql-test/suite/perfschema/r/misc.result | 16 | ||||
-rw-r--r-- | mysql-test/suite/perfschema/t/misc.test | 15 |
2 files changed, 31 insertions, 0 deletions
diff --git a/mysql-test/suite/perfschema/r/misc.result b/mysql-test/suite/perfschema/r/misc.result index 2adf2cba851..7a097a27576 100644 --- a/mysql-test/suite/perfschema/r/misc.result +++ b/mysql-test/suite/perfschema/r/misc.result @@ -118,3 +118,19 @@ B select count(*) from events_statements_history where sql_text like "%..."; count(*) 2 +use test; +create table t1 (id int); +insert into t1 values (1), (2), (3); +truncate performance_schema.events_statements_history; +select * from t1; +id +1 +2 +3 +insert into t1 select RAND()*10000 from t1; +select sql_text, rows_examined from performance_schema.events_statements_history; +sql_text rows_examined +truncate performance_schema.events_statements_history 0 +select * from t1 3 +insert into t1 select RAND()*10000 from t1 6 +drop table t1; diff --git a/mysql-test/suite/perfschema/t/misc.test b/mysql-test/suite/perfschema/t/misc.test index bf3e8afffdc..c9f7dc6bfc0 100644 --- a/mysql-test/suite/perfschema/t/misc.test +++ b/mysql-test/suite/perfschema/t/misc.test @@ -207,3 +207,18 @@ select 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa select _utf8mb4 'ваÑÑваÑÑваÑÑваÑÑваÑÑваÑÑваÑÑваÑÑваÑÑваÑÑваÑÑваÑÑваÑÑваÑÑваÑÑваÑÑваÑÑваÑÑваÑÑваÑÑваÑÑваÑÑваÑÑваÑÑваÑÑваÑÑваÑÑваÑÑваÑÑваÑÑваÑÑваÑÑваÑÑваÑÑваÑÑваÑÑваÑÑваÑÑваÑÑваÑÑваÑÑваÑÑваÑÑваÑÑваÑÑваÑÑваÑÑваÑÑваÑÑваÑÑваÑÑваÑÑваÑÑваÑÑваÑÑваÑÑваÑÑваÑÑваÑÑваÑÑваÑÑваÑÑваÑÑваÑÑваÑÑваÑÑваÑÑваÑÑваÑÑваÑÑваÑÑваÑÑ' as B; select count(*) from events_statements_history where sql_text like "%..."; + + +# +# MDEV-10486 MariaDB 10.x does not update rows_examined in performance_schema tables +# Verify that the rows_examined counter is set properly. + +use test; +create table t1 (id int); +insert into t1 values (1), (2), (3); +truncate performance_schema.events_statements_history; +select * from t1; +insert into t1 select RAND()*10000 from t1; +select sql_text, rows_examined from performance_schema.events_statements_history; +drop table t1; + |