Commit 951c11c8 authored by Alexander Nozdrin's avatar Alexander Nozdrin

A backport of a patch for Bug#35297.

Original revision in mysql-6.0-codebase is:

revno: 2617.31.14
committer: Konstantin Osipov <kostja@sun.com>
branch nick: mysql-6.0-runtime
timestamp: Sat 2009-03-28 11:42:55 +0300
message:
  Bug#35297 SHOW CREATE EVENT does not show the DEFINER:
  update test result after a merge from now.
parent 62fa62af
This diff is collapsed.
...@@ -2226,7 +2226,7 @@ END| ...@@ -2226,7 +2226,7 @@ END|
SHOW CREATE EVENT ev1| SHOW CREATE EVENT ev1|
Event sql_mode time_zone Create Event character_set_client collation_connection Database Collation Event sql_mode time_zone Create Event character_set_client collation_connection Database Collation
ev1 SYSTEM CREATE EVENT `ev1` ON SCHEDULE AT '2030-01-01 00:00:00' ON COMPLETION NOT PRESERVE ENABLE DO BEGIN ev1 SYSTEM CREATE DEFINER=`root`@`localhost` EVENT `ev1` ON SCHEDULE AT '2030-01-01 00:00:00' ON COMPLETION NOT PRESERVE ENABLE DO BEGIN
DECLARE 1 CHAR(10); DECLARE 1 CHAR(10);
SELECT SELECT
COLLATION(1) AS c1, COLLATION(1) AS c1,
...@@ -2239,7 +2239,7 @@ END koi8r koi8r_general_ci utf8_unicode_ci ...@@ -2239,7 +2239,7 @@ END koi8r koi8r_general_ci utf8_unicode_ci
SHOW CREATE EVENT ev2| SHOW CREATE EVENT ev2|
Event sql_mode time_zone Create Event character_set_client collation_connection Database Collation Event sql_mode time_zone Create Event character_set_client collation_connection Database Collation
ev2 SYSTEM CREATE EVENT `ev2` ON SCHEDULE AT '2030-01-01 00:00:00' ON COMPLETION NOT PRESERVE ENABLE DO BEGIN ev2 SYSTEM CREATE DEFINER=`root`@`localhost` EVENT `ev2` ON SCHEDULE AT '2030-01-01 00:00:00' ON COMPLETION NOT PRESERVE ENABLE DO BEGIN
DECLARE 1 CHAR(10) CHARACTER SET utf8; DECLARE 1 CHAR(10) CHARACTER SET utf8;
SELECT SELECT
COLLATION(1) AS c1, COLLATION(1) AS c1,
...@@ -2252,7 +2252,7 @@ END koi8r koi8r_general_ci utf8_unicode_ci ...@@ -2252,7 +2252,7 @@ END koi8r koi8r_general_ci utf8_unicode_ci
SHOW CREATE EVENT mysqltest2.ev3| SHOW CREATE EVENT mysqltest2.ev3|
Event sql_mode time_zone Create Event character_set_client collation_connection Database Collation Event sql_mode time_zone Create Event character_set_client collation_connection Database Collation
ev3 SYSTEM CREATE EVENT `ev3` ON SCHEDULE AT '2030-01-01 00:00:00' ON COMPLETION NOT PRESERVE ENABLE DO BEGIN ev3 SYSTEM CREATE DEFINER=`root`@`localhost` EVENT `ev3` ON SCHEDULE AT '2030-01-01 00:00:00' ON COMPLETION NOT PRESERVE ENABLE DO BEGIN
DECLARE 1 CHAR(10) CHARACTER SET utf8; DECLARE 1 CHAR(10) CHARACTER SET utf8;
SELECT SELECT
COLLATION(1) AS c1, COLLATION(1) AS c1,
...@@ -2265,7 +2265,7 @@ END koi8r koi8r_general_ci utf8_unicode_ci ...@@ -2265,7 +2265,7 @@ END koi8r koi8r_general_ci utf8_unicode_ci
SHOW CREATE EVENT mysqltest2.ev3| SHOW CREATE EVENT mysqltest2.ev3|
Event sql_mode time_zone Create Event character_set_client collation_connection Database Collation Event sql_mode time_zone Create Event character_set_client collation_connection Database Collation
ev3 SYSTEM CREATE EVENT `ev3` ON SCHEDULE AT '2030-01-01 00:00:00' ON COMPLETION NOT PRESERVE ENABLE DO BEGIN ev3 SYSTEM CREATE DEFINER=`root`@`localhost` EVENT `ev3` ON SCHEDULE AT '2030-01-01 00:00:00' ON COMPLETION NOT PRESERVE ENABLE DO BEGIN
DECLARE 1 CHAR(10) CHARACTER SET utf8; DECLARE 1 CHAR(10) CHARACTER SET utf8;
SELECT SELECT
COLLATION(1) AS c1, COLLATION(1) AS c1,
...@@ -2361,7 +2361,7 @@ set names koi8r| ...@@ -2361,7 +2361,7 @@ set names koi8r|
SHOW CREATE EVENT ev1| SHOW CREATE EVENT ev1|
Event sql_mode time_zone Create Event character_set_client collation_connection Database Collation Event sql_mode time_zone Create Event character_set_client collation_connection Database Collation
ev1 SYSTEM CREATE EVENT `ev1` ON SCHEDULE AT '2030-01-01 00:00:00' ON COMPLETION NOT PRESERVE ENABLE DO BEGIN ev1 SYSTEM CREATE DEFINER=`root`@`localhost` EVENT `ev1` ON SCHEDULE AT '2030-01-01 00:00:00' ON COMPLETION NOT PRESERVE ENABLE DO BEGIN
DECLARE 1 CHAR(10); DECLARE 1 CHAR(10);
SELECT SELECT
COLLATION(1) AS c1, COLLATION(1) AS c1,
...@@ -2374,7 +2374,7 @@ END koi8r koi8r_general_ci utf8_unicode_ci ...@@ -2374,7 +2374,7 @@ END koi8r koi8r_general_ci utf8_unicode_ci
SHOW CREATE EVENT ev2| SHOW CREATE EVENT ev2|
Event sql_mode time_zone Create Event character_set_client collation_connection Database Collation Event sql_mode time_zone Create Event character_set_client collation_connection Database Collation
ev2 SYSTEM CREATE EVENT `ev2` ON SCHEDULE AT '2030-01-01 00:00:00' ON COMPLETION NOT PRESERVE ENABLE DO BEGIN ev2 SYSTEM CREATE DEFINER=`root`@`localhost` EVENT `ev2` ON SCHEDULE AT '2030-01-01 00:00:00' ON COMPLETION NOT PRESERVE ENABLE DO BEGIN
DECLARE 1 CHAR(10) CHARACTER SET utf8; DECLARE 1 CHAR(10) CHARACTER SET utf8;
SELECT SELECT
COLLATION(1) AS c1, COLLATION(1) AS c1,
...@@ -2387,7 +2387,7 @@ END koi8r koi8r_general_ci utf8_unicode_ci ...@@ -2387,7 +2387,7 @@ END koi8r koi8r_general_ci utf8_unicode_ci
SHOW CREATE EVENT mysqltest2.ev3| SHOW CREATE EVENT mysqltest2.ev3|
Event sql_mode time_zone Create Event character_set_client collation_connection Database Collation Event sql_mode time_zone Create Event character_set_client collation_connection Database Collation
ev3 SYSTEM CREATE EVENT `ev3` ON SCHEDULE AT '2030-01-01 00:00:00' ON COMPLETION NOT PRESERVE ENABLE DO BEGIN ev3 SYSTEM CREATE DEFINER=`root`@`localhost` EVENT `ev3` ON SCHEDULE AT '2030-01-01 00:00:00' ON COMPLETION NOT PRESERVE ENABLE DO BEGIN
DECLARE 1 CHAR(10) CHARACTER SET utf8; DECLARE 1 CHAR(10) CHARACTER SET utf8;
SELECT SELECT
COLLATION(1) AS c1, COLLATION(1) AS c1,
...@@ -2400,7 +2400,7 @@ END koi8r koi8r_general_ci utf8_unicode_ci ...@@ -2400,7 +2400,7 @@ END koi8r koi8r_general_ci utf8_unicode_ci
SHOW CREATE EVENT mysqltest2.ev3| SHOW CREATE EVENT mysqltest2.ev3|
Event sql_mode time_zone Create Event character_set_client collation_connection Database Collation Event sql_mode time_zone Create Event character_set_client collation_connection Database Collation
ev3 SYSTEM CREATE EVENT `ev3` ON SCHEDULE AT '2030-01-01 00:00:00' ON COMPLETION NOT PRESERVE ENABLE DO BEGIN ev3 SYSTEM CREATE DEFINER=`root`@`localhost` EVENT `ev3` ON SCHEDULE AT '2030-01-01 00:00:00' ON COMPLETION NOT PRESERVE ENABLE DO BEGIN
DECLARE 1 CHAR(10) CHARACTER SET utf8; DECLARE 1 CHAR(10) CHARACTER SET utf8;
SELECT SELECT
COLLATION(1) AS c1, COLLATION(1) AS c1,
...@@ -2497,7 +2497,7 @@ ALTER DATABASE mysqltest1 CHARACTER SET utf8 COLLATE utf8_unicode_ci ;; ...@@ -2497,7 +2497,7 @@ ALTER DATABASE mysqltest1 CHARACTER SET utf8 COLLATE utf8_unicode_ci ;;
/*!50003 SET sql_mode = '' */ ;; /*!50003 SET sql_mode = '' */ ;;
/*!50003 SET @saved_time_zone = @@time_zone */ ;; /*!50003 SET @saved_time_zone = @@time_zone */ ;;
/*!50003 SET time_zone = 'SYSTEM' */ ;; /*!50003 SET time_zone = 'SYSTEM' */ ;;
/*!50106 CREATE EVENT `ev1` ON SCHEDULE AT '2030-01-01 00:00:00' ON COMPLETION NOT PRESERVE ENABLE DO BEGIN /*!50106 CREATE*/ /*!50117 DEFINER=`root`@`localhost`*/ /*!50106 EVENT `ev1` ON SCHEDULE AT '2030-01-01 00:00:00' ON COMPLETION NOT PRESERVE ENABLE DO BEGIN
DECLARE 1 CHAR(10); DECLARE 1 CHAR(10);
SELECT SELECT
COLLATION(1) AS c1, COLLATION(1) AS c1,
...@@ -2525,7 +2525,7 @@ ALTER DATABASE mysqltest1 CHARACTER SET utf8 COLLATE utf8_unicode_ci ;; ...@@ -2525,7 +2525,7 @@ ALTER DATABASE mysqltest1 CHARACTER SET utf8 COLLATE utf8_unicode_ci ;;
/*!50003 SET sql_mode = '' */ ;; /*!50003 SET sql_mode = '' */ ;;
/*!50003 SET @saved_time_zone = @@time_zone */ ;; /*!50003 SET @saved_time_zone = @@time_zone */ ;;
/*!50003 SET time_zone = 'SYSTEM' */ ;; /*!50003 SET time_zone = 'SYSTEM' */ ;;
/*!50106 CREATE EVENT `ev2` ON SCHEDULE AT '2030-01-01 00:00:00' ON COMPLETION NOT PRESERVE ENABLE DO BEGIN /*!50106 CREATE*/ /*!50117 DEFINER=`root`@`localhost`*/ /*!50106 EVENT `ev2` ON SCHEDULE AT '2030-01-01 00:00:00' ON COMPLETION NOT PRESERVE ENABLE DO BEGIN
DECLARE 1 CHAR(10) CHARACTER SET utf8; DECLARE 1 CHAR(10) CHARACTER SET utf8;
SELECT SELECT
COLLATION(1) AS c1, COLLATION(1) AS c1,
...@@ -2564,7 +2564,7 @@ ALTER DATABASE mysqltest2 CHARACTER SET utf8 COLLATE utf8_unicode_ci ;; ...@@ -2564,7 +2564,7 @@ ALTER DATABASE mysqltest2 CHARACTER SET utf8 COLLATE utf8_unicode_ci ;;
/*!50003 SET sql_mode = '' */ ;; /*!50003 SET sql_mode = '' */ ;;
/*!50003 SET @saved_time_zone = @@time_zone */ ;; /*!50003 SET @saved_time_zone = @@time_zone */ ;;
/*!50003 SET time_zone = 'SYSTEM' */ ;; /*!50003 SET time_zone = 'SYSTEM' */ ;;
/*!50106 CREATE EVENT `ev3` ON SCHEDULE AT '2030-01-01 00:00:00' ON COMPLETION NOT PRESERVE ENABLE DO BEGIN /*!50106 CREATE*/ /*!50117 DEFINER=`root`@`localhost`*/ /*!50106 EVENT `ev3` ON SCHEDULE AT '2030-01-01 00:00:00' ON COMPLETION NOT PRESERVE ENABLE DO BEGIN
DECLARE 1 CHAR(10) CHARACTER SET utf8; DECLARE 1 CHAR(10) CHARACTER SET utf8;
SELECT SELECT
COLLATION(1) AS c1, COLLATION(1) AS c1,
...@@ -2592,7 +2592,7 @@ ALTER DATABASE mysqltest2 CHARACTER SET utf8 COLLATE utf8_unicode_ci ;; ...@@ -2592,7 +2592,7 @@ ALTER DATABASE mysqltest2 CHARACTER SET utf8 COLLATE utf8_unicode_ci ;;
/*!50003 SET sql_mode = '' */ ;; /*!50003 SET sql_mode = '' */ ;;
/*!50003 SET @saved_time_zone = @@time_zone */ ;; /*!50003 SET @saved_time_zone = @@time_zone */ ;;
/*!50003 SET time_zone = 'SYSTEM' */ ;; /*!50003 SET time_zone = 'SYSTEM' */ ;;
/*!50106 CREATE EVENT `ev4` ON SCHEDULE AT '2030-01-01 00:00:00' ON COMPLETION NOT PRESERVE ENABLE DO BEGIN /*!50106 CREATE*/ /*!50117 DEFINER=`root`@`localhost`*/ /*!50106 EVENT `ev4` ON SCHEDULE AT '2030-01-01 00:00:00' ON COMPLETION NOT PRESERVE ENABLE DO BEGIN
DECLARE 1 CHAR(10) CHARACTER SET utf8; DECLARE 1 CHAR(10) CHARACTER SET utf8;
SELECT SELECT
COLLATION(1) AS c1, COLLATION(1) AS c1,
...@@ -2634,7 +2634,7 @@ set names koi8r| ...@@ -2634,7 +2634,7 @@ set names koi8r|
SHOW CREATE EVENT ev1| SHOW CREATE EVENT ev1|
Event sql_mode time_zone Create Event character_set_client collation_connection Database Collation Event sql_mode time_zone Create Event character_set_client collation_connection Database Collation
ev1 SYSTEM CREATE EVENT `ev1` ON SCHEDULE AT '2030-01-01 00:00:00' ON COMPLETION NOT PRESERVE ENABLE DO BEGIN ev1 SYSTEM CREATE DEFINER=`root`@`localhost` EVENT `ev1` ON SCHEDULE AT '2030-01-01 00:00:00' ON COMPLETION NOT PRESERVE ENABLE DO BEGIN
DECLARE 1 CHAR(10); DECLARE 1 CHAR(10);
SELECT SELECT
COLLATION(1) AS c1, COLLATION(1) AS c1,
...@@ -2647,7 +2647,7 @@ END koi8r koi8r_general_ci utf8_unicode_ci ...@@ -2647,7 +2647,7 @@ END koi8r koi8r_general_ci utf8_unicode_ci
SHOW CREATE EVENT ev2| SHOW CREATE EVENT ev2|
Event sql_mode time_zone Create Event character_set_client collation_connection Database Collation Event sql_mode time_zone Create Event character_set_client collation_connection Database Collation
ev2 SYSTEM CREATE EVENT `ev2` ON SCHEDULE AT '2030-01-01 00:00:00' ON COMPLETION NOT PRESERVE ENABLE DO BEGIN ev2 SYSTEM CREATE DEFINER=`root`@`localhost` EVENT `ev2` ON SCHEDULE AT '2030-01-01 00:00:00' ON COMPLETION NOT PRESERVE ENABLE DO BEGIN
DECLARE 1 CHAR(10) CHARACTER SET utf8; DECLARE 1 CHAR(10) CHARACTER SET utf8;
SELECT SELECT
COLLATION(1) AS c1, COLLATION(1) AS c1,
...@@ -2660,7 +2660,7 @@ END koi8r koi8r_general_ci utf8_unicode_ci ...@@ -2660,7 +2660,7 @@ END koi8r koi8r_general_ci utf8_unicode_ci
SHOW CREATE EVENT mysqltest2.ev3| SHOW CREATE EVENT mysqltest2.ev3|
Event sql_mode time_zone Create Event character_set_client collation_connection Database Collation Event sql_mode time_zone Create Event character_set_client collation_connection Database Collation
ev3 SYSTEM CREATE EVENT `ev3` ON SCHEDULE AT '2030-01-01 00:00:00' ON COMPLETION NOT PRESERVE ENABLE DO BEGIN ev3 SYSTEM CREATE DEFINER=`root`@`localhost` EVENT `ev3` ON SCHEDULE AT '2030-01-01 00:00:00' ON COMPLETION NOT PRESERVE ENABLE DO BEGIN
DECLARE 1 CHAR(10) CHARACTER SET utf8; DECLARE 1 CHAR(10) CHARACTER SET utf8;
SELECT SELECT
COLLATION(1) AS c1, COLLATION(1) AS c1,
...@@ -2673,7 +2673,7 @@ END koi8r koi8r_general_ci utf8_unicode_ci ...@@ -2673,7 +2673,7 @@ END koi8r koi8r_general_ci utf8_unicode_ci
SHOW CREATE EVENT mysqltest2.ev3| SHOW CREATE EVENT mysqltest2.ev3|
Event sql_mode time_zone Create Event character_set_client collation_connection Database Collation Event sql_mode time_zone Create Event character_set_client collation_connection Database Collation
ev3 SYSTEM CREATE EVENT `ev3` ON SCHEDULE AT '2030-01-01 00:00:00' ON COMPLETION NOT PRESERVE ENABLE DO BEGIN ev3 SYSTEM CREATE DEFINER=`root`@`localhost` EVENT `ev3` ON SCHEDULE AT '2030-01-01 00:00:00' ON COMPLETION NOT PRESERVE ENABLE DO BEGIN
DECLARE 1 CHAR(10) CHARACTER SET utf8; DECLARE 1 CHAR(10) CHARACTER SET utf8;
SELECT SELECT
COLLATION(1) AS c1, COLLATION(1) AS c1,
......
...@@ -2226,7 +2226,7 @@ END| ...@@ -2226,7 +2226,7 @@ END|
SHOW CREATE EVENT ev1| SHOW CREATE EVENT ev1|
Event sql_mode time_zone Create Event character_set_client collation_connection Database Collation Event sql_mode time_zone Create Event character_set_client collation_connection Database Collation
ev1 SYSTEM CREATE EVENT `ev1` ON SCHEDULE AT '2030-01-01 00:00:00' ON COMPLETION NOT PRESERVE ENABLE DO BEGIN ev1 SYSTEM CREATE DEFINER=`root`@`localhost` EVENT `ev1` ON SCHEDULE AT '2030-01-01 00:00:00' ON COMPLETION NOT PRESERVE ENABLE DO BEGIN
DECLARE перем1 CHAR(10); DECLARE перем1 CHAR(10);
SELECT SELECT
COLLATION(перем1) AS c1, COLLATION(перем1) AS c1,
...@@ -2239,7 +2239,7 @@ END utf8 utf8_general_ci utf8_unicode_ci ...@@ -2239,7 +2239,7 @@ END utf8 utf8_general_ci utf8_unicode_ci
SHOW CREATE EVENT ev2| SHOW CREATE EVENT ev2|
Event sql_mode time_zone Create Event character_set_client collation_connection Database Collation Event sql_mode time_zone Create Event character_set_client collation_connection Database Collation
ev2 SYSTEM CREATE EVENT `ev2` ON SCHEDULE AT '2030-01-01 00:00:00' ON COMPLETION NOT PRESERVE ENABLE DO BEGIN ev2 SYSTEM CREATE DEFINER=`root`@`localhost` EVENT `ev2` ON SCHEDULE AT '2030-01-01 00:00:00' ON COMPLETION NOT PRESERVE ENABLE DO BEGIN
DECLARE перем1 CHAR(10) CHARACTER SET utf8; DECLARE перем1 CHAR(10) CHARACTER SET utf8;
SELECT SELECT
COLLATION(перем1) AS c1, COLLATION(перем1) AS c1,
...@@ -2252,7 +2252,7 @@ END utf8 utf8_general_ci utf8_unicode_ci ...@@ -2252,7 +2252,7 @@ END utf8 utf8_general_ci utf8_unicode_ci
SHOW CREATE EVENT mysqltest2.ev3| SHOW CREATE EVENT mysqltest2.ev3|
Event sql_mode time_zone Create Event character_set_client collation_connection Database Collation Event sql_mode time_zone Create Event character_set_client collation_connection Database Collation
ev3 SYSTEM CREATE EVENT `ev3` ON SCHEDULE AT '2030-01-01 00:00:00' ON COMPLETION NOT PRESERVE ENABLE DO BEGIN ev3 SYSTEM CREATE DEFINER=`root`@`localhost` EVENT `ev3` ON SCHEDULE AT '2030-01-01 00:00:00' ON COMPLETION NOT PRESERVE ENABLE DO BEGIN
DECLARE перем1 CHAR(10) CHARACTER SET utf8; DECLARE перем1 CHAR(10) CHARACTER SET utf8;
SELECT SELECT
COLLATION(перем1) AS c1, COLLATION(перем1) AS c1,
...@@ -2265,7 +2265,7 @@ END utf8 utf8_general_ci utf8_unicode_ci ...@@ -2265,7 +2265,7 @@ END utf8 utf8_general_ci utf8_unicode_ci
SHOW CREATE EVENT mysqltest2.ev3| SHOW CREATE EVENT mysqltest2.ev3|
Event sql_mode time_zone Create Event character_set_client collation_connection Database Collation Event sql_mode time_zone Create Event character_set_client collation_connection Database Collation
ev3 SYSTEM CREATE EVENT `ev3` ON SCHEDULE AT '2030-01-01 00:00:00' ON COMPLETION NOT PRESERVE ENABLE DO BEGIN ev3 SYSTEM CREATE DEFINER=`root`@`localhost` EVENT `ev3` ON SCHEDULE AT '2030-01-01 00:00:00' ON COMPLETION NOT PRESERVE ENABLE DO BEGIN
DECLARE перем1 CHAR(10) CHARACTER SET utf8; DECLARE перем1 CHAR(10) CHARACTER SET utf8;
SELECT SELECT
COLLATION(перем1) AS c1, COLLATION(перем1) AS c1,
...@@ -2361,7 +2361,7 @@ set names utf8| ...@@ -2361,7 +2361,7 @@ set names utf8|
SHOW CREATE EVENT ev1| SHOW CREATE EVENT ev1|
Event sql_mode time_zone Create Event character_set_client collation_connection Database Collation Event sql_mode time_zone Create Event character_set_client collation_connection Database Collation
ev1 SYSTEM CREATE EVENT `ev1` ON SCHEDULE AT '2030-01-01 00:00:00' ON COMPLETION NOT PRESERVE ENABLE DO BEGIN ev1 SYSTEM CREATE DEFINER=`root`@`localhost` EVENT `ev1` ON SCHEDULE AT '2030-01-01 00:00:00' ON COMPLETION NOT PRESERVE ENABLE DO BEGIN
DECLARE перем1 CHAR(10); DECLARE перем1 CHAR(10);
SELECT SELECT
COLLATION(перем1) AS c1, COLLATION(перем1) AS c1,
...@@ -2374,7 +2374,7 @@ END utf8 utf8_general_ci utf8_unicode_ci ...@@ -2374,7 +2374,7 @@ END utf8 utf8_general_ci utf8_unicode_ci
SHOW CREATE EVENT ev2| SHOW CREATE EVENT ev2|
Event sql_mode time_zone Create Event character_set_client collation_connection Database Collation Event sql_mode time_zone Create Event character_set_client collation_connection Database Collation
ev2 SYSTEM CREATE EVENT `ev2` ON SCHEDULE AT '2030-01-01 00:00:00' ON COMPLETION NOT PRESERVE ENABLE DO BEGIN ev2 SYSTEM CREATE DEFINER=`root`@`localhost` EVENT `ev2` ON SCHEDULE AT '2030-01-01 00:00:00' ON COMPLETION NOT PRESERVE ENABLE DO BEGIN
DECLARE перем1 CHAR(10) CHARACTER SET utf8; DECLARE перем1 CHAR(10) CHARACTER SET utf8;
SELECT SELECT
COLLATION(перем1) AS c1, COLLATION(перем1) AS c1,
...@@ -2387,7 +2387,7 @@ END utf8 utf8_general_ci utf8_unicode_ci ...@@ -2387,7 +2387,7 @@ END utf8 utf8_general_ci utf8_unicode_ci
SHOW CREATE EVENT mysqltest2.ev3| SHOW CREATE EVENT mysqltest2.ev3|
Event sql_mode time_zone Create Event character_set_client collation_connection Database Collation Event sql_mode time_zone Create Event character_set_client collation_connection Database Collation
ev3 SYSTEM CREATE EVENT `ev3` ON SCHEDULE AT '2030-01-01 00:00:00' ON COMPLETION NOT PRESERVE ENABLE DO BEGIN ev3 SYSTEM CREATE DEFINER=`root`@`localhost` EVENT `ev3` ON SCHEDULE AT '2030-01-01 00:00:00' ON COMPLETION NOT PRESERVE ENABLE DO BEGIN
DECLARE перем1 CHAR(10) CHARACTER SET utf8; DECLARE перем1 CHAR(10) CHARACTER SET utf8;
SELECT SELECT
COLLATION(перем1) AS c1, COLLATION(перем1) AS c1,
...@@ -2400,7 +2400,7 @@ END utf8 utf8_general_ci utf8_unicode_ci ...@@ -2400,7 +2400,7 @@ END utf8 utf8_general_ci utf8_unicode_ci
SHOW CREATE EVENT mysqltest2.ev3| SHOW CREATE EVENT mysqltest2.ev3|
Event sql_mode time_zone Create Event character_set_client collation_connection Database Collation Event sql_mode time_zone Create Event character_set_client collation_connection Database Collation
ev3 SYSTEM CREATE EVENT `ev3` ON SCHEDULE AT '2030-01-01 00:00:00' ON COMPLETION NOT PRESERVE ENABLE DO BEGIN ev3 SYSTEM CREATE DEFINER=`root`@`localhost` EVENT `ev3` ON SCHEDULE AT '2030-01-01 00:00:00' ON COMPLETION NOT PRESERVE ENABLE DO BEGIN
DECLARE перем1 CHAR(10) CHARACTER SET utf8; DECLARE перем1 CHAR(10) CHARACTER SET utf8;
SELECT SELECT
COLLATION(перем1) AS c1, COLLATION(перем1) AS c1,
...@@ -2497,7 +2497,7 @@ ALTER DATABASE mysqltest1 CHARACTER SET utf8 COLLATE utf8_unicode_ci ;; ...@@ -2497,7 +2497,7 @@ ALTER DATABASE mysqltest1 CHARACTER SET utf8 COLLATE utf8_unicode_ci ;;
/*!50003 SET sql_mode = '' */ ;; /*!50003 SET sql_mode = '' */ ;;
/*!50003 SET @saved_time_zone = @@time_zone */ ;; /*!50003 SET @saved_time_zone = @@time_zone */ ;;
/*!50003 SET time_zone = 'SYSTEM' */ ;; /*!50003 SET time_zone = 'SYSTEM' */ ;;
/*!50106 CREATE EVENT `ev1` ON SCHEDULE AT '2030-01-01 00:00:00' ON COMPLETION NOT PRESERVE ENABLE DO BEGIN /*!50106 CREATE*/ /*!50117 DEFINER=`root`@`localhost`*/ /*!50106 EVENT `ev1` ON SCHEDULE AT '2030-01-01 00:00:00' ON COMPLETION NOT PRESERVE ENABLE DO BEGIN
DECLARE перем1 CHAR(10); DECLARE перем1 CHAR(10);
SELECT SELECT
COLLATION(перем1) AS c1, COLLATION(перем1) AS c1,
...@@ -2525,7 +2525,7 @@ ALTER DATABASE mysqltest1 CHARACTER SET utf8 COLLATE utf8_unicode_ci ;; ...@@ -2525,7 +2525,7 @@ ALTER DATABASE mysqltest1 CHARACTER SET utf8 COLLATE utf8_unicode_ci ;;
/*!50003 SET sql_mode = '' */ ;; /*!50003 SET sql_mode = '' */ ;;
/*!50003 SET @saved_time_zone = @@time_zone */ ;; /*!50003 SET @saved_time_zone = @@time_zone */ ;;
/*!50003 SET time_zone = 'SYSTEM' */ ;; /*!50003 SET time_zone = 'SYSTEM' */ ;;
/*!50106 CREATE EVENT `ev2` ON SCHEDULE AT '2030-01-01 00:00:00' ON COMPLETION NOT PRESERVE ENABLE DO BEGIN /*!50106 CREATE*/ /*!50117 DEFINER=`root`@`localhost`*/ /*!50106 EVENT `ev2` ON SCHEDULE AT '2030-01-01 00:00:00' ON COMPLETION NOT PRESERVE ENABLE DO BEGIN
DECLARE перем1 CHAR(10) CHARACTER SET utf8; DECLARE перем1 CHAR(10) CHARACTER SET utf8;
SELECT SELECT
COLLATION(перем1) AS c1, COLLATION(перем1) AS c1,
...@@ -2564,7 +2564,7 @@ ALTER DATABASE mysqltest2 CHARACTER SET utf8 COLLATE utf8_unicode_ci ;; ...@@ -2564,7 +2564,7 @@ ALTER DATABASE mysqltest2 CHARACTER SET utf8 COLLATE utf8_unicode_ci ;;
/*!50003 SET sql_mode = '' */ ;; /*!50003 SET sql_mode = '' */ ;;
/*!50003 SET @saved_time_zone = @@time_zone */ ;; /*!50003 SET @saved_time_zone = @@time_zone */ ;;
/*!50003 SET time_zone = 'SYSTEM' */ ;; /*!50003 SET time_zone = 'SYSTEM' */ ;;
/*!50106 CREATE EVENT `ev3` ON SCHEDULE AT '2030-01-01 00:00:00' ON COMPLETION NOT PRESERVE ENABLE DO BEGIN /*!50106 CREATE*/ /*!50117 DEFINER=`root`@`localhost`*/ /*!50106 EVENT `ev3` ON SCHEDULE AT '2030-01-01 00:00:00' ON COMPLETION NOT PRESERVE ENABLE DO BEGIN
DECLARE перем1 CHAR(10) CHARACTER SET utf8; DECLARE перем1 CHAR(10) CHARACTER SET utf8;
SELECT SELECT
COLLATION(перем1) AS c1, COLLATION(перем1) AS c1,
...@@ -2592,7 +2592,7 @@ ALTER DATABASE mysqltest2 CHARACTER SET utf8 COLLATE utf8_unicode_ci ;; ...@@ -2592,7 +2592,7 @@ ALTER DATABASE mysqltest2 CHARACTER SET utf8 COLLATE utf8_unicode_ci ;;
/*!50003 SET sql_mode = '' */ ;; /*!50003 SET sql_mode = '' */ ;;
/*!50003 SET @saved_time_zone = @@time_zone */ ;; /*!50003 SET @saved_time_zone = @@time_zone */ ;;
/*!50003 SET time_zone = 'SYSTEM' */ ;; /*!50003 SET time_zone = 'SYSTEM' */ ;;
/*!50106 CREATE EVENT `ev4` ON SCHEDULE AT '2030-01-01 00:00:00' ON COMPLETION NOT PRESERVE ENABLE DO BEGIN /*!50106 CREATE*/ /*!50117 DEFINER=`root`@`localhost`*/ /*!50106 EVENT `ev4` ON SCHEDULE AT '2030-01-01 00:00:00' ON COMPLETION NOT PRESERVE ENABLE DO BEGIN
DECLARE перем1 CHAR(10) CHARACTER SET utf8; DECLARE перем1 CHAR(10) CHARACTER SET utf8;
SELECT SELECT
COLLATION(перем1) AS c1, COLLATION(перем1) AS c1,
...@@ -2634,7 +2634,7 @@ set names utf8| ...@@ -2634,7 +2634,7 @@ set names utf8|
SHOW CREATE EVENT ev1| SHOW CREATE EVENT ev1|
Event sql_mode time_zone Create Event character_set_client collation_connection Database Collation Event sql_mode time_zone Create Event character_set_client collation_connection Database Collation
ev1 SYSTEM CREATE EVENT `ev1` ON SCHEDULE AT '2030-01-01 00:00:00' ON COMPLETION NOT PRESERVE ENABLE DO BEGIN ev1 SYSTEM CREATE DEFINER=`root`@`localhost` EVENT `ev1` ON SCHEDULE AT '2030-01-01 00:00:00' ON COMPLETION NOT PRESERVE ENABLE DO BEGIN
DECLARE перем1 CHAR(10); DECLARE перем1 CHAR(10);
SELECT SELECT
COLLATION(перем1) AS c1, COLLATION(перем1) AS c1,
...@@ -2647,7 +2647,7 @@ END utf8 utf8_general_ci utf8_unicode_ci ...@@ -2647,7 +2647,7 @@ END utf8 utf8_general_ci utf8_unicode_ci
SHOW CREATE EVENT ev2| SHOW CREATE EVENT ev2|
Event sql_mode time_zone Create Event character_set_client collation_connection Database Collation Event sql_mode time_zone Create Event character_set_client collation_connection Database Collation
ev2 SYSTEM CREATE EVENT `ev2` ON SCHEDULE AT '2030-01-01 00:00:00' ON COMPLETION NOT PRESERVE ENABLE DO BEGIN ev2 SYSTEM CREATE DEFINER=`root`@`localhost` EVENT `ev2` ON SCHEDULE AT '2030-01-01 00:00:00' ON COMPLETION NOT PRESERVE ENABLE DO BEGIN
DECLARE перем1 CHAR(10) CHARACTER SET utf8; DECLARE перем1 CHAR(10) CHARACTER SET utf8;
SELECT SELECT
COLLATION(перем1) AS c1, COLLATION(перем1) AS c1,
...@@ -2660,7 +2660,7 @@ END utf8 utf8_general_ci utf8_unicode_ci ...@@ -2660,7 +2660,7 @@ END utf8 utf8_general_ci utf8_unicode_ci
SHOW CREATE EVENT mysqltest2.ev3| SHOW CREATE EVENT mysqltest2.ev3|
Event sql_mode time_zone Create Event character_set_client collation_connection Database Collation Event sql_mode time_zone Create Event character_set_client collation_connection Database Collation
ev3 SYSTEM CREATE EVENT `ev3` ON SCHEDULE AT '2030-01-01 00:00:00' ON COMPLETION NOT PRESERVE ENABLE DO BEGIN ev3 SYSTEM CREATE DEFINER=`root`@`localhost` EVENT `ev3` ON SCHEDULE AT '2030-01-01 00:00:00' ON COMPLETION NOT PRESERVE ENABLE DO BEGIN
DECLARE перем1 CHAR(10) CHARACTER SET utf8; DECLARE перем1 CHAR(10) CHARACTER SET utf8;
SELECT SELECT
COLLATION(перем1) AS c1, COLLATION(перем1) AS c1,
...@@ -2673,7 +2673,7 @@ END utf8 utf8_general_ci utf8_unicode_ci ...@@ -2673,7 +2673,7 @@ END utf8 utf8_general_ci utf8_unicode_ci
SHOW CREATE EVENT mysqltest2.ev3| SHOW CREATE EVENT mysqltest2.ev3|
Event sql_mode time_zone Create Event character_set_client collation_connection Database Collation Event sql_mode time_zone Create Event character_set_client collation_connection Database Collation
ev3 SYSTEM CREATE EVENT `ev3` ON SCHEDULE AT '2030-01-01 00:00:00' ON COMPLETION NOT PRESERVE ENABLE DO BEGIN ev3 SYSTEM CREATE DEFINER=`root`@`localhost` EVENT `ev3` ON SCHEDULE AT '2030-01-01 00:00:00' ON COMPLETION NOT PRESERVE ENABLE DO BEGIN
DECLARE перем1 CHAR(10) CHARACTER SET utf8; DECLARE перем1 CHAR(10) CHARACTER SET utf8;
SELECT SELECT
COLLATION(перем1) AS c1, COLLATION(перем1) AS c1,
......
This diff is collapsed.
...@@ -134,7 +134,7 @@ create event e1 on schedule every 10 hour do select 1; ...@@ -134,7 +134,7 @@ create event e1 on schedule every 10 hour do select 1;
lock table t1 read; lock table t1 read;
show create event e1; show create event e1;
Event sql_mode time_zone Create Event character_set_client collation_connection Database Collation Event sql_mode time_zone Create Event character_set_client collation_connection Database Collation
e1 SYSTEM CREATE EVENT `e1` ON SCHEDULE EVERY 10 HOUR STARTS '#' ON COMPLETION NOT PRESERVE ENABLE DO select 1 utf8 utf8_general_ci latin1_swedish_ci e1 SYSTEM CREATE DEFINER=`root`@`localhost` EVENT `e1` ON SCHEDULE EVERY 10 HOUR STARTS '#' ON COMPLETION NOT PRESERVE ENABLE DO select 1 utf8 utf8_general_ci latin1_swedish_ci
select event_name from information_schema.events; select event_name from information_schema.events;
event_name event_name
e1 e1
...@@ -152,7 +152,7 @@ unlock tables; ...@@ -152,7 +152,7 @@ unlock tables;
lock table t1 write; lock table t1 write;
show create event e1; show create event e1;
Event sql_mode time_zone Create Event character_set_client collation_connection Database Collation Event sql_mode time_zone Create Event character_set_client collation_connection Database Collation
e1 SYSTEM CREATE EVENT `e1` ON SCHEDULE EVERY 10 HOUR STARTS '#' ON COMPLETION NOT PRESERVE ENABLE DO select 1 utf8 utf8_general_ci latin1_swedish_ci e1 SYSTEM CREATE DEFINER=`root`@`localhost` EVENT `e1` ON SCHEDULE EVERY 10 HOUR STARTS '#' ON COMPLETION NOT PRESERVE ENABLE DO select 1 utf8 utf8_general_ci latin1_swedish_ci
select event_name from information_schema.events; select event_name from information_schema.events;
event_name event_name
e1 e1
...@@ -170,7 +170,7 @@ unlock tables; ...@@ -170,7 +170,7 @@ unlock tables;
lock table t1 read, mysql.event read; lock table t1 read, mysql.event read;
show create event e1; show create event e1;
Event sql_mode time_zone Create Event character_set_client collation_connection Database Collation Event sql_mode time_zone Create Event character_set_client collation_connection Database Collation
e1 SYSTEM CREATE EVENT `e1` ON SCHEDULE EVERY 10 HOUR STARTS '#' ON COMPLETION NOT PRESERVE ENABLE DO select 1 utf8 utf8_general_ci latin1_swedish_ci e1 SYSTEM CREATE DEFINER=`root`@`localhost` EVENT `e1` ON SCHEDULE EVERY 10 HOUR STARTS '#' ON COMPLETION NOT PRESERVE ENABLE DO select 1 utf8 utf8_general_ci latin1_swedish_ci
select event_name from information_schema.events; select event_name from information_schema.events;
event_name event_name
e1 e1
...@@ -188,7 +188,7 @@ unlock tables; ...@@ -188,7 +188,7 @@ unlock tables;
lock table t1 write, mysql.event read; lock table t1 write, mysql.event read;
show create event e1; show create event e1;
Event sql_mode time_zone Create Event character_set_client collation_connection Database Collation Event sql_mode time_zone Create Event character_set_client collation_connection Database Collation
e1 SYSTEM CREATE EVENT `e1` ON SCHEDULE EVERY 10 HOUR STARTS '#' ON COMPLETION NOT PRESERVE ENABLE DO select 1 utf8 utf8_general_ci latin1_swedish_ci e1 SYSTEM CREATE DEFINER=`root`@`localhost` EVENT `e1` ON SCHEDULE EVERY 10 HOUR STARTS '#' ON COMPLETION NOT PRESERVE ENABLE DO select 1 utf8 utf8_general_ci latin1_swedish_ci
select event_name from information_schema.events; select event_name from information_schema.events;
event_name event_name
e1 e1
...@@ -210,7 +210,7 @@ ERROR HY000: You can't combine write-locking of system tables with other tables ...@@ -210,7 +210,7 @@ ERROR HY000: You can't combine write-locking of system tables with other tables
lock table mysql.event write; lock table mysql.event write;
show create event e1; show create event e1;
Event sql_mode time_zone Create Event character_set_client collation_connection Database Collation Event sql_mode time_zone Create Event character_set_client collation_connection Database Collation
e1 SYSTEM CREATE EVENT `e1` ON SCHEDULE EVERY 10 HOUR STARTS '#' ON COMPLETION NOT PRESERVE ENABLE DO select 1 utf8 utf8_general_ci latin1_swedish_ci e1 SYSTEM CREATE DEFINER=`root`@`localhost` EVENT `e1` ON SCHEDULE EVERY 10 HOUR STARTS '#' ON COMPLETION NOT PRESERVE ENABLE DO select 1 utf8 utf8_general_ci latin1_swedish_ci
select event_name from information_schema.events; select event_name from information_schema.events;
event_name event_name
e1 e1
......
...@@ -4223,7 +4223,7 @@ Db Name Definer Time zone Type Execute at Interval value Interval field Starts E ...@@ -4223,7 +4223,7 @@ Db Name Definer Time zone Type Execute at Interval value Interval field Starts E
first ee1 root@localhost UTC ONE TIME 2035-12-31 20:01:23 NULL NULL NULL NULL ENABLED 1 latin1 latin1_swedish_ci latin1_swedish_ci first ee1 root@localhost UTC ONE TIME 2035-12-31 20:01:23 NULL NULL NULL NULL ENABLED 1 latin1 latin1_swedish_ci latin1_swedish_ci
show create event ee1; show create event ee1;
Event sql_mode time_zone Create Event character_set_client collation_connection Database Collation Event sql_mode time_zone Create Event character_set_client collation_connection Database Collation
ee1 UTC CREATE EVENT `ee1` ON SCHEDULE AT '2035-12-31 20:01:23' ON COMPLETION NOT PRESERVE ENABLE DO set @a=5 latin1 latin1_swedish_ci latin1_swedish_ci ee1 UTC CREATE DEFINER=`root`@`localhost` EVENT `ee1` ON SCHEDULE AT '2035-12-31 20:01:23' ON COMPLETION NOT PRESERVE ENABLE DO set @a=5 latin1 latin1_swedish_ci latin1_swedish_ci
drop database first; drop database first;
create database second; create database second;
use second; use second;
...@@ -4232,7 +4232,7 @@ Db Name Definer Time zone Type Execute at Interval value Interval field Starts E ...@@ -4232,7 +4232,7 @@ Db Name Definer Time zone Type Execute at Interval value Interval field Starts E
second ee1 root@localhost UTC ONE TIME 2035-12-31 20:01:23 NULL NULL NULL NULL ENABLED 1 latin1 latin1_swedish_ci latin1_swedish_ci second ee1 root@localhost UTC ONE TIME 2035-12-31 20:01:23 NULL NULL NULL NULL ENABLED 1 latin1 latin1_swedish_ci latin1_swedish_ci
show create event ee1; show create event ee1;
Event sql_mode time_zone Create Event character_set_client collation_connection Database Collation Event sql_mode time_zone Create Event character_set_client collation_connection Database Collation
ee1 UTC CREATE EVENT `ee1` ON SCHEDULE AT '2035-12-31 20:01:23' ON COMPLETION NOT PRESERVE ENABLE DO set @a=5 latin1 latin1_swedish_ci latin1_swedish_ci ee1 UTC CREATE DEFINER=`root`@`localhost` EVENT `ee1` ON SCHEDULE AT '2035-12-31 20:01:23' ON COMPLETION NOT PRESERVE ENABLE DO set @a=5 latin1 latin1_swedish_ci latin1_swedish_ci
create event ee2 on schedule at '2018-12-31 21:01:23' do set @a=5; create event ee2 on schedule at '2018-12-31 21:01:23' do set @a=5;
create event ee3 on schedule at '2030-12-31 22:01:23' do set @a=5; create event ee3 on schedule at '2030-12-31 22:01:23' do set @a=5;
show events; show events;
......
...@@ -1442,7 +1442,7 @@ FOR EACH ROW ...@@ -1442,7 +1442,7 @@ FOR EACH ROW
SET NEW.c1 = 'тест' koi8r koi8r_general_ci latin1_swedish_ci SET NEW.c1 = 'тест' koi8r koi8r_general_ci latin1_swedish_ci
SHOW CREATE EVENT ev1; SHOW CREATE EVENT ev1;
Event sql_mode time_zone Create Event character_set_client collation_connection Database Collation Event sql_mode time_zone Create Event character_set_client collation_connection Database Collation
ev1 SYSTEM CREATE EVENT `ev1` ON SCHEDULE AT '2030-01-01 00:00:00' ON COMPLETION NOT PRESERVE ENABLE DO SELECT 'тест' AS test koi8r koi8r_general_ci latin1_swedish_ci ev1 SYSTEM CREATE DEFINER=`root`@`localhost` EVENT `ev1` ON SCHEDULE AT '2030-01-01 00:00:00' ON COMPLETION NOT PRESERVE ENABLE DO SELECT 'тест' AS test koi8r koi8r_general_ci latin1_swedish_ci
DROP VIEW v1; DROP VIEW v1;
DROP PROCEDURE p1; DROP PROCEDURE p1;
DROP FUNCTION f1; DROP FUNCTION f1;
......
...@@ -1225,7 +1225,9 @@ Event_timed::get_create_event(THD *thd, String *buf) ...@@ -1225,7 +1225,9 @@ Event_timed::get_create_event(THD *thd, String *buf)
expression)) expression))
DBUG_RETURN(EVEX_MICROSECOND_UNSUP); DBUG_RETURN(EVEX_MICROSECOND_UNSUP);
buf->append(STRING_WITH_LEN("CREATE EVENT ")); buf->append(STRING_WITH_LEN("CREATE "));
append_definer(thd, buf, &definer_user, &definer_host);
buf->append(STRING_WITH_LEN("EVENT "));
append_identifier(thd, buf, name.str, name.length); append_identifier(thd, buf, name.str, name.length);
if (expression) if (expression)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment