diff options
Diffstat (limited to 'mysql-test/r')
-rw-r--r-- | mysql-test/r/ps_1general.result | 82 | ||||
-rw-r--r-- | mysql-test/r/ps_grant.result | 82 | ||||
-rw-r--r-- | mysql-test/r/rpl_variables.result | 8 | ||||
-rw-r--r-- | mysql-test/r/timezone2.result | 52 | ||||
-rw-r--r-- | mysql-test/r/timezone_grant.result | 52 | ||||
-rw-r--r-- | mysql-test/r/user_var-binlog.result | 25 | ||||
-rw-r--r-- | mysql-test/r/user_var.result | 25 | ||||
-rw-r--r-- | mysql-test/r/variables.result | 2 |
8 files changed, 167 insertions, 161 deletions
diff --git a/mysql-test/r/ps_1general.result b/mysql-test/r/ps_1general.result index 2356989eaf6..c17890d3e32 100644 --- a/mysql-test/r/ps_1general.result +++ b/mysql-test/r/ps_1general.result @@ -288,10 +288,6 @@ Variable_name Value sql_mode prepare stmt4 from ' show engine bdb logs '; execute stmt4; -prepare stmt4 from ' show full processlist '; -execute stmt4; -Id User Host db Command Time State Info -number root localhost test Query time NULL show full processlist prepare stmt4 from ' show grants for user '; prepare stmt4 from ' show create table t2 '; ERROR HY000: This command is not supported in the prepared statement protocol yet @@ -806,81 +802,3 @@ execute stmt1 ; prepare stmt1 from ' select * from t5 ' ; execute stmt1 ; drop table t5 ; -test_sequence ------- grant/revoke/drop affects a parallel session test ------ -show grants for second_user@localhost ; -ERROR 42000: There is no such grant defined for user 'second_user' on host 'localhost' -create database mysqltest; -use mysqltest; -use test; -grant usage on mysqltest.* to second_user@localhost -identified by 'looser' ; -grant select on mysqltest.t9 to second_user@localhost -identified by 'looser' ; -show grants for second_user@localhost ; -Grants for second_user@localhost -GRANT USAGE ON *.* TO 'second_user'@'localhost' IDENTIFIED BY PASSWORD '*13843FE600B19A81E32AF50D4A6FED25875FF1F3' -GRANT SELECT ON `mysqltest`.`t9` TO 'second_user'@'localhost' -select current_user(); -current_user() -second_user@localhost -show grants for current_user(); -Grants for second_user@localhost -GRANT USAGE ON *.* TO 'second_user'@'localhost' IDENTIFIED BY PASSWORD '*13843FE600B19A81E32AF50D4A6FED25875FF1F3' -GRANT SELECT ON `mysqltest`.`t9` TO 'second_user'@'localhost' -prepare s_t9 from 'select c1 as my_col - from t9 where c1= 1' ; -execute s_t9 ; -my_col -1 -select a as my_col from t1; -ERROR 42000: SELECT command denied to user 'second_user'@'localhost' for table 't1' -grant select on mysqltest.t1 to second_user@localhost -identified by 'looser' ; -show grants for second_user@localhost ; -Grants for second_user@localhost -GRANT USAGE ON *.* TO 'second_user'@'localhost' IDENTIFIED BY PASSWORD '*13843FE600B19A81E32AF50D4A6FED25875FF1F3' -GRANT SELECT ON `mysqltest`.`t9` TO 'second_user'@'localhost' -GRANT SELECT ON `mysqltest`.`t1` TO 'second_user'@'localhost' -drop table mysqltest.t9 ; -show grants for second_user@localhost ; -Grants for second_user@localhost -GRANT USAGE ON *.* TO 'second_user'@'localhost' IDENTIFIED BY PASSWORD '*13843FE600B19A81E32AF50D4A6FED25875FF1F3' -GRANT SELECT ON `mysqltest`.`t9` TO 'second_user'@'localhost' -GRANT SELECT ON `mysqltest`.`t1` TO 'second_user'@'localhost' -show grants for second_user@localhost ; -Grants for second_user@localhost -GRANT USAGE ON *.* TO 'second_user'@'localhost' IDENTIFIED BY PASSWORD '*13843FE600B19A81E32AF50D4A6FED25875FF1F3' -GRANT SELECT ON `mysqltest`.`t9` TO 'second_user'@'localhost' -GRANT SELECT ON `mysqltest`.`t1` TO 'second_user'@'localhost' -prepare s_t1 from 'select a as my_col from t1' ; -execute s_t1 ; -my_col -1 -2 -3 -4 -execute s_t9 ; -ERROR 42S02: Table 'mysqltest.t9' doesn't exist -revoke all privileges on mysqltest.t1 from second_user@localhost -identified by 'looser' ; -show grants for second_user@localhost ; -Grants for second_user@localhost -GRANT USAGE ON *.* TO 'second_user'@'localhost' IDENTIFIED BY PASSWORD '*13843FE600B19A81E32AF50D4A6FED25875FF1F3' -GRANT SELECT ON `mysqltest`.`t9` TO 'second_user'@'localhost' -show grants for second_user@localhost ; -Grants for second_user@localhost -GRANT USAGE ON *.* TO 'second_user'@'localhost' IDENTIFIED BY PASSWORD '*13843FE600B19A81E32AF50D4A6FED25875FF1F3' -GRANT SELECT ON `mysqltest`.`t9` TO 'second_user'@'localhost' -execute s_t1 ; -ERROR 42000: SELECT command denied to user 'second_user'@'localhost' for table 't1' -revoke all privileges, grant option from second_user@localhost ; -show grants for second_user@localhost ; -Grants for second_user@localhost -GRANT USAGE ON *.* TO 'second_user'@'localhost' IDENTIFIED BY PASSWORD '*13843FE600B19A81E32AF50D4A6FED25875FF1F3' -drop user second_user@localhost ; -commit ; -show grants for second_user@localhost ; -ERROR 42000: There is no such grant defined for user 'second_user' on host 'localhost' -drop table t1,t9 ; -drop database mysqltest; diff --git a/mysql-test/r/ps_grant.result b/mysql-test/r/ps_grant.result new file mode 100644 index 00000000000..81de74f245c --- /dev/null +++ b/mysql-test/r/ps_grant.result @@ -0,0 +1,82 @@ +prepare stmt4 from ' show full processlist '; +execute stmt4; +Id User Host db Command Time State Info +number root localhost test Query time NULL show full processlist +test_sequence +------ grant/revoke/drop affects a parallel session test ------ +show grants for second_user@localhost ; +ERROR 42000: There is no such grant defined for user 'second_user' on host 'localhost' +create database mysqltest; +use mysqltest; +use test; +grant usage on mysqltest.* to second_user@localhost +identified by 'looser' ; +grant select on mysqltest.t9 to second_user@localhost +identified by 'looser' ; +show grants for second_user@localhost ; +Grants for second_user@localhost +GRANT USAGE ON *.* TO 'second_user'@'localhost' IDENTIFIED BY PASSWORD '*13843FE600B19A81E32AF50D4A6FED25875FF1F3' +GRANT SELECT ON `mysqltest`.`t9` TO 'second_user'@'localhost' +select current_user(); +current_user() +second_user@localhost +show grants for current_user(); +Grants for second_user@localhost +GRANT USAGE ON *.* TO 'second_user'@'localhost' IDENTIFIED BY PASSWORD '*13843FE600B19A81E32AF50D4A6FED25875FF1F3' +GRANT SELECT ON `mysqltest`.`t9` TO 'second_user'@'localhost' +prepare s_t9 from 'select c1 as my_col + from t9 where c1= 1' ; +execute s_t9 ; +my_col +1 +select a as my_col from t1; +ERROR 42000: SELECT command denied to user 'second_user'@'localhost' for table 't1' +grant select on mysqltest.t1 to second_user@localhost +identified by 'looser' ; +show grants for second_user@localhost ; +Grants for second_user@localhost +GRANT USAGE ON *.* TO 'second_user'@'localhost' IDENTIFIED BY PASSWORD '*13843FE600B19A81E32AF50D4A6FED25875FF1F3' +GRANT SELECT ON `mysqltest`.`t9` TO 'second_user'@'localhost' +GRANT SELECT ON `mysqltest`.`t1` TO 'second_user'@'localhost' +drop table mysqltest.t9 ; +show grants for second_user@localhost ; +Grants for second_user@localhost +GRANT USAGE ON *.* TO 'second_user'@'localhost' IDENTIFIED BY PASSWORD '*13843FE600B19A81E32AF50D4A6FED25875FF1F3' +GRANT SELECT ON `mysqltest`.`t9` TO 'second_user'@'localhost' +GRANT SELECT ON `mysqltest`.`t1` TO 'second_user'@'localhost' +show grants for second_user@localhost ; +Grants for second_user@localhost +GRANT USAGE ON *.* TO 'second_user'@'localhost' IDENTIFIED BY PASSWORD '*13843FE600B19A81E32AF50D4A6FED25875FF1F3' +GRANT SELECT ON `mysqltest`.`t9` TO 'second_user'@'localhost' +GRANT SELECT ON `mysqltest`.`t1` TO 'second_user'@'localhost' +prepare s_t1 from 'select a as my_col from t1' ; +execute s_t1 ; +my_col +1 +2 +3 +4 +execute s_t9 ; +ERROR 42S02: Table 'mysqltest.t9' doesn't exist +revoke all privileges on mysqltest.t1 from second_user@localhost +identified by 'looser' ; +show grants for second_user@localhost ; +Grants for second_user@localhost +GRANT USAGE ON *.* TO 'second_user'@'localhost' IDENTIFIED BY PASSWORD '*13843FE600B19A81E32AF50D4A6FED25875FF1F3' +GRANT SELECT ON `mysqltest`.`t9` TO 'second_user'@'localhost' +show grants for second_user@localhost ; +Grants for second_user@localhost +GRANT USAGE ON *.* TO 'second_user'@'localhost' IDENTIFIED BY PASSWORD '*13843FE600B19A81E32AF50D4A6FED25875FF1F3' +GRANT SELECT ON `mysqltest`.`t9` TO 'second_user'@'localhost' +execute s_t1 ; +ERROR 42000: SELECT command denied to user 'second_user'@'localhost' for table 't1' +revoke all privileges, grant option from second_user@localhost ; +show grants for second_user@localhost ; +Grants for second_user@localhost +GRANT USAGE ON *.* TO 'second_user'@'localhost' IDENTIFIED BY PASSWORD '*13843FE600B19A81E32AF50D4A6FED25875FF1F3' +drop user second_user@localhost ; +commit ; +show grants for second_user@localhost ; +ERROR 42000: There is no such grant defined for user 'second_user' on host 'localhost' +drop table t1,t9 ; +drop database mysqltest; diff --git a/mysql-test/r/rpl_variables.result b/mysql-test/r/rpl_variables.result new file mode 100644 index 00000000000..227d8ecfad9 --- /dev/null +++ b/mysql-test/r/rpl_variables.result @@ -0,0 +1,8 @@ +stop slave; +drop table if exists t1,t2,t3,t4,t5,t6,t7,t8,t9; +reset master; +reset slave; +drop table if exists t1,t2,t3,t4,t5,t6,t7,t8,t9; +start slave; +set global slave_net_timeout=100; +set global sql_slave_skip_counter=100; diff --git a/mysql-test/r/timezone2.result b/mysql-test/r/timezone2.result index 206ff79e7ba..199b48ef1aa 100644 --- a/mysql-test/r/timezone2.result +++ b/mysql-test/r/timezone2.result @@ -251,58 +251,6 @@ select convert_tz(ts, @@time_zone, 'Japan') from t1; convert_tz(ts, @@time_zone, 'Japan') 2001-09-09 10:46:40 drop table t1; -delete from mysql.user where user like 'mysqltest\_%'; -delete from mysql.db where user like 'mysqltest\_%'; -delete from mysql.tables_priv where user like 'mysqltest\_%'; -delete from mysql.columns_priv where user like 'mysqltest\_%'; -flush privileges; -create table t1 (a int, b datetime); -create table t2 (c int, d datetime); -grant all privileges on test.* to mysqltest_1@localhost; -show grants for current_user(); -Grants for mysqltest_1@localhost -GRANT USAGE ON *.* TO 'mysqltest_1'@'localhost' -GRANT ALL PRIVILEGES ON `test`.* TO 'mysqltest_1'@'localhost' -set time_zone= '+00:00'; -set time_zone= 'Europe/Moscow'; -select convert_tz('2004-10-21 19:00:00', 'Europe/Moscow', 'UTC'); -convert_tz('2004-10-21 19:00:00', 'Europe/Moscow', 'UTC') -2004-10-21 15:00:00 -select convert_tz(b, 'Europe/Moscow', 'UTC') from t1; -convert_tz(b, 'Europe/Moscow', 'UTC') -update t1, t2 set t1.b = convert_tz('2004-10-21 19:00:00', 'Europe/Moscow', 'UTC') -where t1.a = t2.c and t2.d = (select max(d) from t2); -select * from mysql.time_zone_name; -ERROR 42000: Access denied for user 'mysqltest_1'@'localhost' to database 'mysql' -select Name, convert_tz('2004-10-21 19:00:00', Name, 'UTC') from mysql.time_zone_name; -ERROR 42000: Access denied for user 'mysqltest_1'@'localhost' to database 'mysql' -delete from mysql.db where user like 'mysqltest\_%'; -flush privileges; -grant all privileges on test.t1 to mysqltest_1@localhost; -grant all privileges on test.t2 to mysqltest_1@localhost; -show grants for current_user(); -Grants for mysqltest_1@localhost -GRANT USAGE ON *.* TO 'mysqltest_1'@'localhost' -GRANT ALL PRIVILEGES ON `test`.`t2` TO 'mysqltest_1'@'localhost' -GRANT ALL PRIVILEGES ON `test`.`t1` TO 'mysqltest_1'@'localhost' -set time_zone= '+00:00'; -set time_zone= 'Europe/Moscow'; -select convert_tz('2004-11-31 12:00:00', 'Europe/Moscow', 'UTC'); -convert_tz('2004-11-31 12:00:00', 'Europe/Moscow', 'UTC') -2004-12-01 09:00:00 -select convert_tz(b, 'Europe/Moscow', 'UTC') from t1; -convert_tz(b, 'Europe/Moscow', 'UTC') -update t1, t2 set t1.b = convert_tz('2004-11-30 12:00:00', 'Europe/Moscow', 'UTC') -where t1.a = t2.c and t2.d = (select max(d) from t2); -select * from mysql.time_zone_name; -ERROR 42000: SELECT command denied to user 'mysqltest_1'@'localhost' for table 'time_zone_name' -select Name, convert_tz('2004-11-30 12:00:00', Name, 'UTC') from mysql.time_zone_name; -ERROR 42000: SELECT command denied to user 'mysqltest_1'@'localhost' for table 'time_zone_name' -delete from mysql.user where user like 'mysqltest\_%'; -delete from mysql.db where user like 'mysqltest\_%'; -delete from mysql.tables_priv where user like 'mysqltest\_%'; -flush privileges; -drop table t1, t2; select convert_tz('2005-01-14 17:00:00', 'UTC', custTimeZone) from (select 'UTC' as custTimeZone) as tmp; convert_tz('2005-01-14 17:00:00', 'UTC', custTimeZone) 2005-01-14 17:00:00 diff --git a/mysql-test/r/timezone_grant.result b/mysql-test/r/timezone_grant.result new file mode 100644 index 00000000000..685f8007ac7 --- /dev/null +++ b/mysql-test/r/timezone_grant.result @@ -0,0 +1,52 @@ +delete from mysql.user where user like 'mysqltest\_%'; +delete from mysql.db where user like 'mysqltest\_%'; +delete from mysql.tables_priv where user like 'mysqltest\_%'; +delete from mysql.columns_priv where user like 'mysqltest\_%'; +flush privileges; +create table t1 (a int, b datetime); +create table t2 (c int, d datetime); +grant all privileges on test.* to mysqltest_1@localhost; +show grants for current_user(); +Grants for mysqltest_1@localhost +GRANT USAGE ON *.* TO 'mysqltest_1'@'localhost' +GRANT ALL PRIVILEGES ON `test`.* TO 'mysqltest_1'@'localhost' +set time_zone= '+00:00'; +set time_zone= 'Europe/Moscow'; +select convert_tz('2004-10-21 19:00:00', 'Europe/Moscow', 'UTC'); +convert_tz('2004-10-21 19:00:00', 'Europe/Moscow', 'UTC') +2004-10-21 15:00:00 +select convert_tz(b, 'Europe/Moscow', 'UTC') from t1; +convert_tz(b, 'Europe/Moscow', 'UTC') +update t1, t2 set t1.b = convert_tz('2004-10-21 19:00:00', 'Europe/Moscow', 'UTC') +where t1.a = t2.c and t2.d = (select max(d) from t2); +select * from mysql.time_zone_name; +ERROR 42000: Access denied for user 'mysqltest_1'@'localhost' to database 'mysql' +select Name, convert_tz('2004-10-21 19:00:00', Name, 'UTC') from mysql.time_zone_name; +ERROR 42000: Access denied for user 'mysqltest_1'@'localhost' to database 'mysql' +delete from mysql.db where user like 'mysqltest\_%'; +flush privileges; +grant all privileges on test.t1 to mysqltest_1@localhost; +grant all privileges on test.t2 to mysqltest_1@localhost; +show grants for current_user(); +Grants for mysqltest_1@localhost +GRANT USAGE ON *.* TO 'mysqltest_1'@'localhost' +GRANT ALL PRIVILEGES ON `test`.`t2` TO 'mysqltest_1'@'localhost' +GRANT ALL PRIVILEGES ON `test`.`t1` TO 'mysqltest_1'@'localhost' +set time_zone= '+00:00'; +set time_zone= 'Europe/Moscow'; +select convert_tz('2004-11-31 12:00:00', 'Europe/Moscow', 'UTC'); +convert_tz('2004-11-31 12:00:00', 'Europe/Moscow', 'UTC') +2004-12-01 09:00:00 +select convert_tz(b, 'Europe/Moscow', 'UTC') from t1; +convert_tz(b, 'Europe/Moscow', 'UTC') +update t1, t2 set t1.b = convert_tz('2004-11-30 12:00:00', 'Europe/Moscow', 'UTC') +where t1.a = t2.c and t2.d = (select max(d) from t2); +select * from mysql.time_zone_name; +ERROR 42000: SELECT command denied to user 'mysqltest_1'@'localhost' for table 'time_zone_name' +select Name, convert_tz('2004-11-30 12:00:00', Name, 'UTC') from mysql.time_zone_name; +ERROR 42000: SELECT command denied to user 'mysqltest_1'@'localhost' for table 'time_zone_name' +delete from mysql.user where user like 'mysqltest\_%'; +delete from mysql.db where user like 'mysqltest\_%'; +delete from mysql.tables_priv where user like 'mysqltest\_%'; +flush privileges; +drop table t1, t2; diff --git a/mysql-test/r/user_var-binlog.result b/mysql-test/r/user_var-binlog.result new file mode 100644 index 00000000000..06a2a846a0e --- /dev/null +++ b/mysql-test/r/user_var-binlog.result @@ -0,0 +1,25 @@ +create table t1 (a varchar(50)); +reset master; +SET TIMESTAMP=10000; +SET @`a b`='hello'; +INSERT INTO t1 VALUES(@`a b`); +set @var1= "';aaa"; +SET @var2=char(ascii('a')); +insert into t1 values (@var1),(@var2); +show binlog events from 79; +Log_name Pos Event_type Server_id Orig_log_pos Info +master-bin.000001 79 User var 1 79 @`a b`=_latin1 0x68656C6C6F COLLATE latin1_swedish_ci +master-bin.000001 120 Query 1 120 use `test`; INSERT INTO t1 VALUES(@`a b`) +master-bin.000001 184 User var 1 184 @`var1`=_latin1 0x273B616161 COLLATE latin1_swedish_ci +master-bin.000001 226 User var 1 226 @`var2`=_latin1 0x61 COLLATE latin1_swedish_ci +master-bin.000001 264 Query 1 264 use `test`; insert into t1 values (@var1),(@var2) +/*!40019 SET @@session.max_insert_delayed_threads=0*/; +SET @`a b`:=_latin1 0x68656C6C6F COLLATE `latin1_swedish_ci`; +use test; +SET TIMESTAMP=10000; +INSERT INTO t1 VALUES(@`a b`); +SET @`var1`:=_latin1 0x273B616161 COLLATE `latin1_swedish_ci`; +SET @`var2`:=_latin1 0x61 COLLATE `latin1_swedish_ci`; +SET TIMESTAMP=10000; +insert into t1 values (@var1),(@var2); +drop table t1; diff --git a/mysql-test/r/user_var.result b/mysql-test/r/user_var.result index 81846391795..18f7047f357 100644 --- a/mysql-test/r/user_var.result +++ b/mysql-test/r/user_var.result @@ -162,31 +162,6 @@ charset(@a) collation(@a) coercibility(@a) latin2 latin2_bin 0 select (@a:=_latin2'test' collate latin2_bin) = _latin2'TEST' collate latin2_general_ci; ERROR HY000: Illegal mix of collations (latin2_bin,EXPLICIT) and (latin2_general_ci,EXPLICIT) for operation '=' -create table t1 (a varchar(50)); -reset master; -SET TIMESTAMP=10000; -SET @`a b`='hello'; -INSERT INTO t1 VALUES(@`a b`); -set @var1= "';aaa"; -SET @var2=char(ascii('a')); -insert into t1 values (@var1),(@var2); -show binlog events from 79; -Log_name Pos Event_type Server_id Orig_log_pos Info -master-bin.000001 79 User var 1 79 @`a b`=_latin1 0x68656C6C6F COLLATE latin1_swedish_ci -master-bin.000001 120 Query 1 120 use `test`; INSERT INTO t1 VALUES(@`a b`) -master-bin.000001 184 User var 1 184 @`var1`=_latin1 0x273B616161 COLLATE latin1_swedish_ci -master-bin.000001 226 User var 1 226 @`var2`=_latin1 0x61 COLLATE latin1_swedish_ci -master-bin.000001 264 Query 1 264 use `test`; insert into t1 values (@var1),(@var2) -/*!40019 SET @@session.max_insert_delayed_threads=0*/; -SET @`a b`:=_latin1 0x68656C6C6F COLLATE `latin1_swedish_ci`; -use test; -SET TIMESTAMP=10000; -INSERT INTO t1 VALUES(@`a b`); -SET @`var1`:=_latin1 0x273B616161 COLLATE `latin1_swedish_ci`; -SET @`var2`:=_latin1 0x61 COLLATE `latin1_swedish_ci`; -SET TIMESTAMP=10000; -insert into t1 values (@var1),(@var2); -drop table t1; set @var= NULL ; select FIELD( @var,'1it','Hit') as my_column; my_column diff --git a/mysql-test/r/variables.result b/mysql-test/r/variables.result index 6b700f7f6a2..5e3bda75a80 100644 --- a/mysql-test/r/variables.result +++ b/mysql-test/r/variables.result @@ -324,7 +324,6 @@ set read_buffer_size=100; set read_rnd_buffer_size=100; set global rpl_recovery_rank=100; set global server_id=100; -set global slave_net_timeout=100; set global slow_launch_time=100; set sort_buffer_size=100; set sql_auto_is_null=1; @@ -349,7 +348,6 @@ select @@sql_max_join_size,@@max_join_size; set sql_quote_show_create=1; set sql_safe_updates=1; set sql_select_limit=1; -set global sql_slave_skip_counter=100; set sql_warnings=1; set global table_cache=100; set storage_engine=myisam; |