mirror of
				https://github.com/MariaDB/server.git
				synced 2025-11-03 14:33:32 +03:00 
			
		
		
		
	when we close the session's temp tables at session end, we automatically write to binlog *one* DROP TEMPORARY TABLE *per tmp table*. mysql-test/r/drop_temp_table.result: result update (note: one DROP TEMPORARY TABLE per tmp table) mysql-test/t/drop_temp_table.test: checking that we have one DROP TEMPORARY TABLE per tmp table now, not one multi-table DROP. Hiding columns Log_pos/End_log_pos per Monty's request. sql/sql_base.cc: When we close the session's temp tables at session end, we automatically write to binlog one DROP TEMPORARY TABLE per tmp table, not one single multi-table DROP TEMPORARY TABLE (because it causes problems if slave has --replicate*table rules).
		
			
				
	
	
		
			23 lines
		
	
	
		
			727 B
		
	
	
	
		
			Plaintext
		
	
	
	
	
	
			
		
		
	
	
			23 lines
		
	
	
		
			727 B
		
	
	
	
		
			Plaintext
		
	
	
	
	
	
connect (con1,localhost,root,,);
 | 
						|
connect (con2,localhost,root,,);
 | 
						|
connection con1;
 | 
						|
reset master;
 | 
						|
create database `drop-temp+table-test`;
 | 
						|
use `drop-temp+table-test`;
 | 
						|
create temporary table shortn1 (a int);
 | 
						|
create temporary table `table:name` (a int);
 | 
						|
create temporary table shortn2 (a int);
 | 
						|
select get_lock("a",10);
 | 
						|
disconnect con1;
 | 
						|
 | 
						|
connection con2;
 | 
						|
# We want to SHOW BINLOG EVENTS, to know what was logged. But there is no
 | 
						|
# guarantee that logging of the terminated con1 has been done yet.
 | 
						|
# To be sure that logging has been done, we use a user lock.
 | 
						|
select get_lock("a",10);
 | 
						|
let $VERSION=`select version()`;
 | 
						|
--replace_result $VERSION VERSION
 | 
						|
--replace_column 2 # 5 #
 | 
						|
show binlog events;
 | 
						|
drop database `drop-temp+table-test`;
 |