mirror of
https://github.com/MariaDB/server.git
synced 2025-07-29 05:21:33 +03:00
Auto-merge
This commit is contained in:
@ -258,3 +258,15 @@ dec $it;
|
|||||||
}
|
}
|
||||||
show master status /* must show new binlog index after rotating */;
|
show master status /* must show new binlog index after rotating */;
|
||||||
drop table t3;
|
drop table t3;
|
||||||
|
|
||||||
|
--echo #
|
||||||
|
--echo # Bug #45998: database crashes when running "create as select"
|
||||||
|
--echo #
|
||||||
|
CREATE DATABASE test1;
|
||||||
|
USE test1;
|
||||||
|
DROP DATABASE test1;
|
||||||
|
CREATE TABLE test.t1(a int);
|
||||||
|
INSERT INTO test.t1 VALUES (1), (2);
|
||||||
|
CREATE TABLE test.t2 SELECT * FROM test.t1;
|
||||||
|
USE test;
|
||||||
|
DROP TABLES t1, t2;
|
||||||
|
@ -1298,3 +1298,14 @@ show master status /* must show new binlog index after rotating */;
|
|||||||
File Position Binlog_Do_DB Binlog_Ignore_DB
|
File Position Binlog_Do_DB Binlog_Ignore_DB
|
||||||
master-bin.000002 106
|
master-bin.000002 106
|
||||||
drop table t3;
|
drop table t3;
|
||||||
|
#
|
||||||
|
# Bug #45998: database crashes when running "create as select"
|
||||||
|
#
|
||||||
|
CREATE DATABASE test1;
|
||||||
|
USE test1;
|
||||||
|
DROP DATABASE test1;
|
||||||
|
CREATE TABLE test.t1(a int);
|
||||||
|
INSERT INTO test.t1 VALUES (1), (2);
|
||||||
|
CREATE TABLE test.t2 SELECT * FROM test.t1;
|
||||||
|
USE test;
|
||||||
|
DROP TABLES t1, t2;
|
||||||
|
@ -1151,7 +1151,7 @@ int store_create_info(THD *thd, TABLE_LIST *table_list, String *packet,
|
|||||||
{
|
{
|
||||||
const LEX_STRING *const db=
|
const LEX_STRING *const db=
|
||||||
table_list->schema_table ? &INFORMATION_SCHEMA_NAME : &table->s->db;
|
table_list->schema_table ? &INFORMATION_SCHEMA_NAME : &table->s->db;
|
||||||
if (strcmp(db->str, thd->db) != 0)
|
if (!thd->db || strcmp(db->str, thd->db))
|
||||||
{
|
{
|
||||||
append_identifier(thd, packet, db->str, db->length);
|
append_identifier(thd, packet, db->str, db->length);
|
||||||
packet->append(STRING_WITH_LEN("."));
|
packet->append(STRING_WITH_LEN("."));
|
||||||
|
Reference in New Issue
Block a user