mirror of
https://github.com/MariaDB/server.git
synced 2025-08-01 03:47:19 +03:00
fixing wrong value for "examined rows" when UNION's are used.
mysql-test/r/union.result: result for a test case for the wrong examined rows with UNION's mysql-test/t/union.test: test case for the wrong examined rows with UNION's sql/sql_union.cc: a patch for the wrong examined rows with UNION's
This commit is contained in:
@ -872,6 +872,22 @@ count(*)
|
||||
show status like 'Slow_queries';
|
||||
Variable_name Value
|
||||
Slow_queries 3
|
||||
flush status;
|
||||
select a from t1 where b not in (1,2,3) union select a from t1 where b not in (4,5,6);
|
||||
a
|
||||
4
|
||||
5
|
||||
3
|
||||
6
|
||||
7
|
||||
8
|
||||
9
|
||||
10
|
||||
1
|
||||
2
|
||||
show status like 'Slow_queries';
|
||||
Variable_name Value
|
||||
Slow_queries 1
|
||||
drop table t1;
|
||||
create table t1 ( RID int(11) not null default '0', IID int(11) not null default '0', nada varchar(50) not null,NAME varchar(50) not null,PHONE varchar(50) not null) engine=MyISAM;
|
||||
insert into t1 ( RID,IID,nada,NAME,PHONE) values (1, 1, 'main', 'a', '111'), (2, 1, 'main', 'b', '222'), (3, 1, 'main', 'c', '333'), (4, 1, 'main', 'd', '444'), (5, 1, 'main', 'e', '555'), (6, 2, 'main', 'c', '333'), (7, 2, 'main', 'd', '454'), (8, 2, 'main', 'e', '555'), (9, 2, 'main', 'f', '666'), (10, 2, 'main', 'g', '777');
|
||||
|
Reference in New Issue
Block a user