MySQL Lists are EOL. Please join:

List:Commits« Previous MessageNext Message »
From:Jon Olav Hauglid Date:September 25 2009 2:38pm
Subject:bzr commit into mysql-6.0-bugfixing branch (jon.hauglid:2840) Bug#47635
View as plain text  
#At file:///export/home/z/mysql-6.0-codebase-bugfixing-bug47635/ based on revid:jon.hauglid@stripped

 2840 Jon Olav Hauglid	2009-09-25
      Bug #47635 assert in start_waiting_global_read_lock during CREATE VIEW
      
      The problem was that CREATE VIEW would trigger an assert if
      a temporary table with the same name already existed.
      
      This bug was fixed by the patch for Bug#47335. CREATE/ALTER VIEW
      will now ignore temporary tables. See Bug#47335 for more information.
      
      Test case added to view.test.

    modified:
      mysql-test/r/view.result
      mysql-test/t/view.test
=== modified file 'mysql-test/r/view.result'
--- a/mysql-test/r/view.result	2009-09-24 07:46:37 +0000
+++ b/mysql-test/r/view.result	2009-09-25 14:38:12 +0000
@@ -4019,3 +4019,18 @@ SELECT * FROM v1;
 f1
 2
 DROP VIEW v1;
+#
+# Bug #47635 assert in start_waiting_global_read_lock 
+#            during CREATE VIEW
+#
+DROP TABLE IF EXISTS t1, t2;
+DROP VIEW IF EXISTS t2;
+CREATE TABLE t1 (f1 integer);
+CREATE TEMPORARY TABLE IF NOT EXISTS t1 (f1 integer);
+CREATE TEMPORARY TABLE t2 (f1 integer);
+DROP TABLE t1;
+FLUSH TABLES WITH READ LOCK;
+CREATE VIEW t2 AS SELECT * FROM t1;
+ERROR HY000: Can't execute the query because you have a conflicting read lock
+UNLOCK TABLES;
+DROP TABLE t1, t2;

=== modified file 'mysql-test/t/view.test'
--- a/mysql-test/t/view.test	2009-09-24 07:46:37 +0000
+++ b/mysql-test/t/view.test	2009-09-25 14:38:12 +0000
@@ -1,3 +1,4 @@
+
 --disable_warnings
 drop table if exists t1,t2,t3,t4,t9,`t1a``b`,v1,v2,v3,v4,v5,v6;
 drop view if exists t1,t2,`t1a``b`,v1,v2,v3,v4,v5,v6;
@@ -3988,3 +3989,25 @@ ALTER VIEW v1 AS SELECT 2 AS f1;
 DROP TABLE v1;
 SELECT * FROM v1;
 DROP VIEW v1;
+
+
+--echo #
+--echo # Bug #47635 assert in start_waiting_global_read_lock 
+--echo #            during CREATE VIEW
+--echo #
+
+--disable_warnings
+DROP TABLE IF EXISTS t1, t2;
+DROP VIEW IF EXISTS t2;
+--enable_warnings
+
+CREATE TABLE t1 (f1 integer);
+CREATE TEMPORARY TABLE IF NOT EXISTS t1 (f1 integer);
+CREATE TEMPORARY TABLE t2 (f1 integer);
+DROP TABLE t1;
+FLUSH TABLES WITH READ LOCK;
+--error ER_CANT_UPDATE_WITH_READLOCK
+CREATE VIEW t2 AS SELECT * FROM t1;
+
+UNLOCK TABLES;
+DROP TABLE t1, t2;


Attachment: [text/bzr-bundle] bzr/jon.hauglid@sun.com-20090925143812-el7gu2hj6286t74z.bundle
Thread
bzr commit into mysql-6.0-bugfixing branch (jon.hauglid:2840) Bug#47635Jon Olav Hauglid25 Sep
  • Re: bzr commit into mysql-6.0-bugfixing branch (jon.hauglid:2840)Bug#47635Konstantin Osipov25 Sep