mirror of
				https://github.com/MariaDB/server.git
				synced 2025-11-03 14:33:32 +03:00 
			
		
		
		
	Test case for the bug#31048 is moved to the subselect_notembedded tests as the embedded server isn't affected by this bug. mysql-test/r/subselect.result: Test case for the bug#31048 is moved to the subselect_notembedded tests as the embedded server isn't affected by this bug. mysql-test/r/subselect_notembedded.result: Test case for the bug#31048 is moved to the subselect_notembedded tests as the embedded server isn't affected by this bug. mysql-test/t/subselect.test: Test case for the bug#31048 is moved to the subselect_notembedded tests as the embedded server isn't affected by this bug. mysql-test/t/subselect_notembedded.test: Test case for the bug#31048 is moved to the subselect_notembedded tests as the embedded server isn't affected by this bug.
		
			
				
	
	
		
			106 lines
		
	
	
		
			5.4 KiB
		
	
	
	
		
			Plaintext
		
	
	
	
	
	
			
		
		
	
	
			106 lines
		
	
	
		
			5.4 KiB
		
	
	
	
		
			Plaintext
		
	
	
	
	
	
-- source include/not_embedded.inc
 | 
						|
 | 
						|
#
 | 
						|
# BUG#10308: purge log with subselect
 | 
						|
# Bug#28553: mysqld crash in "purge master log before(select time from information_schema)"
 | 
						|
#
 | 
						|
--error 1064
 | 
						|
purge master logs before (select adddate(current_timestamp(), interval -4 day));
 | 
						|
purge master logs before adddate(current_timestamp(), interval -4 day);
 | 
						|
 | 
						|
#
 | 
						|
# Bug31048: Many nested subqueries may cause server crash.
 | 
						|
#
 | 
						|
create table t1(a int,b int,key(a),key(b));
 | 
						|
insert into t1(a,b) values (1,2),(2,1),(2,3),(3,4),(5,4),(5,5),
 | 
						|
  (6,7),(7,4),(5,3);
 | 
						|
# test for the stack overflow bug
 | 
						|
select sum(a),a from t1 where a> (
 | 
						|
  select sum(a) from t1 where a> ( select sum(a) from t1 where a> (
 | 
						|
  select sum(a) from t1 where a> ( select sum(a) from t1 where a> (
 | 
						|
  select sum(a) from t1 where a> ( select sum(a) from t1 where a> (
 | 
						|
  select sum(a) from t1 where a> ( select sum(a) from t1 where a> (
 | 
						|
  select sum(a) from t1 where a> ( select sum(a) from t1 where a> (
 | 
						|
  select sum(a) from t1 where a> ( select sum(a) from t1
 | 
						|
  )group by b limit 1)group by b limit 1
 | 
						|
  )group by b limit 1)group by b limit 1)group by b limit 1
 | 
						|
  )group by b limit 1)group by b limit 1)group by b limit 1
 | 
						|
  )group by b limit 1)group by b limit 1)group by b limit 1) 
 | 
						|
group by a;
 | 
						|
--replace_regex /overrun.*$/overrun detected/
 | 
						|
--error 1436
 | 
						|
select sum(a),a from t1 where a> (
 | 
						|
  select sum(a) from t1 where a> ( select sum(a) from t1 where a> (
 | 
						|
  select sum(a) from t1 where a> ( select sum(a) from t1 where a> (
 | 
						|
  select sum(a) from t1 where a> ( select sum(a) from t1 where a> (
 | 
						|
  select sum(a) from t1 where a> ( select sum(a) from t1 where a> (
 | 
						|
  select sum(a) from t1 where a> ( select sum(a) from t1 where a> (
 | 
						|
  select sum(a) from t1 where a> ( select sum(a) from t1 where a> (
 | 
						|
  select sum(a) from t1 where a> ( select sum(a) from t1 where a> (
 | 
						|
  select sum(a) from t1 where a> ( select sum(a) from t1 where a> (
 | 
						|
  select sum(a) from t1 where a> ( select sum(a) from t1 where a> (
 | 
						|
  select sum(a) from t1 where a> ( select sum(a) from t1 where a> (
 | 
						|
  select sum(a) from t1 where a> ( select sum(a) from t1 where a> (
 | 
						|
  select sum(a) from t1 where a> ( select sum(a) from t1 where a> (
 | 
						|
  select sum(a) from t1 where a> ( select sum(a) from t1 where a> (
 | 
						|
  select sum(a) from t1 where a> ( select sum(a) from t1 where a> (
 | 
						|
  select sum(a) from t1 where a> ( select sum(a) from t1 where a> (
 | 
						|
  select sum(a) from t1 
 | 
						|
  )group by b limit 1)group by b limit 1)group by b limit 1
 | 
						|
  )group by b limit 1)group by b limit 1)group by b limit 1
 | 
						|
  )group by b limit 1)group by b limit 1)group by b limit 1
 | 
						|
  )group by b limit 1)group by b limit 1)group by b limit 1
 | 
						|
  )group by b limit 1)group by b limit 1)group by b limit 1
 | 
						|
  )group by b limit 1)group by b limit 1)group by b limit 1
 | 
						|
  )group by b limit 1)group by b limit 1)group by b limit 1
 | 
						|
  )group by b limit 1)group by b limit 1)group by b limit 1
 | 
						|
  )group by b limit 1)group by b limit 1)group by b limit 1
 | 
						|
  )group by b limit 1)group by b limit 1)group by b limit 1) 
 | 
						|
group by a;
 | 
						|
# test for the memory consumption & subquery slowness bug
 | 
						|
explain select sum(a),a from t1 where a> (
 | 
						|
  select sum(a) from t1 where a> ( select sum(a) from t1 where a> (
 | 
						|
  select sum(a) from t1 where a> ( select sum(a) from t1 where a> (
 | 
						|
  select sum(a) from t1 where a> ( select sum(a) from t1 where a> (
 | 
						|
  select sum(a) from t1 where a> ( select sum(a) from t1 where a> (
 | 
						|
  select sum(a) from t1 where a> ( select sum(a) from t1 where a> (
 | 
						|
  select sum(a) from t1 where a> ( select sum(a) from t1 
 | 
						|
  )group by b limit 1)group by b limit 1
 | 
						|
  )group by b limit 1)group by b limit 1)group by b limit 1
 | 
						|
  )group by b limit 1)group by b limit 1)group by b limit 1
 | 
						|
  )group by b limit 1)group by b limit 1)group by b limit 1) 
 | 
						|
group by a;
 | 
						|
--replace_regex /overrun.*$/overrun detected/
 | 
						|
--error 1436
 | 
						|
explain select sum(a),a from t1 where a> (
 | 
						|
  select sum(a) from t1 where a> ( select sum(a) from t1 where a> (
 | 
						|
  select sum(a) from t1 where a> ( select sum(a) from t1 where a> (
 | 
						|
  select sum(a) from t1 where a> ( select sum(a) from t1 where a> (
 | 
						|
  select sum(a) from t1 where a> ( select sum(a) from t1 where a> (
 | 
						|
  select sum(a) from t1 where a> ( select sum(a) from t1 where a> (
 | 
						|
  select sum(a) from t1 where a> ( select sum(a) from t1 where a> (
 | 
						|
  select sum(a) from t1 where a> ( select sum(a) from t1 where a> (
 | 
						|
  select sum(a) from t1 where a> ( select sum(a) from t1 where a> (
 | 
						|
  select sum(a) from t1 where a> ( select sum(a) from t1 where a> (
 | 
						|
  select sum(a) from t1 where a> ( select sum(a) from t1 where a> (
 | 
						|
  select sum(a) from t1 where a> ( select sum(a) from t1 where a> (
 | 
						|
  select sum(a) from t1 where a> ( select sum(a) from t1 where a> (
 | 
						|
  select sum(a) from t1 where a> ( select sum(a) from t1 where a> (
 | 
						|
  select sum(a) from t1 where a> ( select sum(a) from t1 where a> (
 | 
						|
  select sum(a) from t1 where a> ( select sum(a) from t1 where a> (
 | 
						|
  select sum(a) from t1 
 | 
						|
  )group by b limit 1)group by b limit 1)group by b limit 1
 | 
						|
  )group by b limit 1)group by b limit 1)group by b limit 1
 | 
						|
  )group by b limit 1)group by b limit 1)group by b limit 1
 | 
						|
  )group by b limit 1)group by b limit 1)group by b limit 1
 | 
						|
  )group by b limit 1)group by b limit 1)group by b limit 1
 | 
						|
  )group by b limit 1)group by b limit 1)group by b limit 1
 | 
						|
  )group by b limit 1)group by b limit 1)group by b limit 1
 | 
						|
  )group by b limit 1)group by b limit 1)group by b limit 1
 | 
						|
  )group by b limit 1)group by b limit 1)group by b limit 1
 | 
						|
  )group by b limit 1)group by b limit 1)group by b limit 1) 
 | 
						|
group by a;
 | 
						|
drop table t1;
 | 
						|
 | 
						|
 |