mySQL 5.0.11 sources for tomato
[tomato.git] / release / src / router / mysql / mysql-test / t / lowercase_fs_off.test
blob86d1e084c29f7d72cace20b6d598fe14b8e7bdcb
2 # Specific tests for case sensitive file systems
3 # i.e. lower_case_filesystem=OFF
5 -- source include/have_case_sensitive_file_system.inc
6 -- source include/not_embedded.inc
8 connect (master,localhost,root,,);
9 connection master;
10 create database d1;
11 grant all on d1.* to 'sample'@'localhost' identified by 'password';
12 flush privileges;
14 connect (sample,localhost,sample,password,d1);
15 connection sample;
16 select database();
17 --error ER_DBACCESS_DENIED_ERROR
18 create database d2;
19 --error ER_DBACCESS_DENIED_ERROR
20 create database D1;
21 disconnect sample;
22 --source include/wait_until_disconnected.inc
24 connection master;
25 drop user 'sample'@'localhost';
26 drop database if exists d1;
27 disconnect master;
28 --source include/wait_until_disconnected.inc
29 connection default;
31 # End of 4.1 tests
34 # Bug#41049 does syntax "grant" case insensitive?
36 CREATE DATABASE d1;
37 USE d1;
38 CREATE TABLE T1(f1 INT);
39 CREATE TABLE t1(f1 INT);
40 GRANT SELECT ON T1 to user_1@localhost;
42 connect (con1,localhost,user_1,,d1);
43 --error ER_TABLEACCESS_DENIED_ERROR
44 select * from t1;
45 select * from T1;
46 connection default;
47 GRANT SELECT ON t1 to user_1@localhost;
48 connection con1;
49 select * from information_schema.table_privileges;
50 connection default;
51 disconnect con1;
53 REVOKE ALL PRIVILEGES, GRANT OPTION FROM user_1@localhost;
54 DROP USER user_1@localhost;
55 DROP DATABASE d1;
56 USE test;
58 CREATE DATABASE db1;
59 USE db1;
60 CREATE PROCEDURE p1() BEGIN END;
61 CREATE FUNCTION f1(i INT) RETURNS INT RETURN i+1;
63 GRANT USAGE ON db1.* to user_1@localhost;
64 GRANT EXECUTE ON PROCEDURE db1.P1 to user_1@localhost;
65 GRANT EXECUTE ON FUNCTION db1.f1 to user_1@localhost;
66 GRANT UPDATE ON db1.* to USER_1@localhost;
68 connect (con1,localhost,user_1,,db1);
69 call p1();
70 call P1();
71 select f1(1);
72 connect (con2,localhost,USER_1,,db1);
73 --error ER_PROCACCESS_DENIED_ERROR
74 call p1();
75 --error ER_PROCACCESS_DENIED_ERROR
76 call P1();
77 --error ER_PROCACCESS_DENIED_ERROR
78 select f1(1);
80 connection default;
81 disconnect con1;
82 disconnect con2;
84 REVOKE ALL PRIVILEGES, GRANT OPTION FROM user_1@localhost;
85 REVOKE ALL PRIVILEGES, GRANT OPTION FROM USER_1@localhost;
86 DROP FUNCTION f1;
87 DROP PROCEDURE p1;
88 DROP USER user_1@localhost;
89 DROP USER USER_1@localhost;
90 DROP DATABASE db1;
91 use test;
93 # End of 5.0 tests