mariadb/tests/grant.res
unknown a821703912 Merge with 4.0
BitKeeper/etc/ignore:
  auto-union
BitKeeper/etc/logging_ok:
  auto-union
BitKeeper/deleted/.del-compile-netware-standard:
  Delete: netware/BUILD/compile-netware-standard
BitKeeper/deleted/.del-mwenv:
  Delete: netware/BUILD/mwenv
BitKeeper/deleted/.del-nwbootstrap:
  Delete: netware/BUILD/nwbootstrap
BitKeeper/deleted/.del-compile-AUTOTOOLS:
  Delete: netware/BUILD/compile-AUTOTOOLS
BitKeeper/deleted/.del-compile-linux-tools:
  Delete: netware/BUILD/compile-linux-tools
BitKeeper/deleted/.del-compile-netware-END:
  Delete: netware/BUILD/compile-netware-END
BitKeeper/deleted/.del-compile-netware-START:
  Delete: netware/BUILD/compile-netware-START
BitKeeper/deleted/.del-compile-netware-all:
  Delete: netware/BUILD/compile-netware-all
BitKeeper/deleted/.del-compile-netware-debug:
  Delete: netware/BUILD/compile-netware-debug
BitKeeper/deleted/.del-mwasmnlm~bc5746809d67feb5:
  Auto merged
BitKeeper/deleted/.del-mwenv~35c8b56062f4b6aa:
  Auto merged
BitKeeper/deleted/.del-mwccnlm~be63afd25a14c3f:
  Auto merged
BitKeeper/deleted/.del-mwldnlm~efb26c57cba3c980:
  Auto merged
BitKeeper/deleted/.del-netware.patch~f70a3a965f54d9ee:
  Auto merged
Docs/internals.texi:
  Auto merged
VC++Files/bdb/bdb.dsp:
  Auto merged
VC++Files/bdb/build_win32/Berkeley_DB.dsw:
  Auto merged
VC++Files/bdb/build_win32/db_archive.dsp:
  Auto merged
VC++Files/bdb/build_win32/db_buildall.dsp:
  Auto merged
VC++Files/bdb/build_win32/db_checkpoint.dsp:
  Auto merged
VC++Files/bdb/build_win32/db_deadlock.dsp:
  Auto merged
VC++Files/bdb/build_win32/db_dll.dsp:
  Auto merged
VC++Files/bdb/build_win32/db_dump.dsp:
  Auto merged
VC++Files/bdb/build_win32/db_java.dsp:
  Auto merged
VC++Files/bdb/build_win32/db_load.dsp:
  Auto merged
VC++Files/bdb/build_win32/db_printlog.dsp:
  Auto merged
VC++Files/bdb/build_win32/db_recover.dsp:
  Auto merged
VC++Files/bdb/build_win32/db_stat.dsp:
  Auto merged
VC++Files/bdb/build_win32/db_static.dsp:
  Auto merged
VC++Files/bdb/build_win32/db_static1.dsp:
  Auto merged
VC++Files/bdb/build_win32/db_tcl.dsp:
  Auto merged
VC++Files/bdb/build_win32/db_test.dsp:
  Auto merged
VC++Files/bdb/build_win32/db_upgrade.dsp:
  Auto merged
VC++Files/bdb/build_win32/db_verify.dsp:
  Auto merged
VC++Files/bdb/build_win32/ex_access.dsp:
  Auto merged
VC++Files/bdb/build_win32/ex_btrec.dsp:
  Auto merged
VC++Files/bdb/build_win32/ex_env.dsp:
  Auto merged
VC++Files/bdb/build_win32/ex_lock.dsp:
  Auto merged
VC++Files/bdb/build_win32/ex_mpool.dsp:
  Auto merged
VC++Files/bdb/build_win32/ex_tpcb.dsp:
  Auto merged
VC++Files/bdb/build_win32/excxx_access.dsp:
  Auto merged
VC++Files/bdb/build_win32/excxx_btrec.dsp:
  Auto merged
VC++Files/bdb/build_win32/excxx_env.dsp:
  Auto merged
VC++Files/bdb/build_win32/excxx_lock.dsp:
  Auto merged
VC++Files/bdb/build_win32/excxx_mpool.dsp:
  Auto merged
VC++Files/bdb/build_win32/excxx_tpcb.dsp:
  Auto merged
VC++Files/client/mysql.dsp:
  Auto merged
VC++Files/client/mysqladmin.dsp:
  Auto merged
VC++Files/client/mysqlcheck.dsp:
  Auto merged
VC++Files/client/mysqlclient.dsp:
  Auto merged
VC++Files/client/mysqlclient.dsw:
  Auto merged
VC++Files/client/mysqldump.dsp:
  Auto merged
VC++Files/client/mysqlimport.dsp:
  Auto merged
VC++Files/client/mysqlshow.dsp:
  Auto merged
VC++Files/comp_err/comp_err.dsp:
  Auto merged
VC++Files/contrib/asm386/zlibvc.dsp:
  Auto merged
VC++Files/contrib/asm386/zlibvc.dsw:
  Auto merged
VC++Files/contrib/minizip/zlibvc.dsp:
  Auto merged
VC++Files/contrib/minizip/zlibvc.dsw:
  Auto merged
VC++Files/dbug/dbug.dsp:
  Auto merged
VC++Files/dbug/dbug.dsw:
  Auto merged
VC++Files/heap/heap.dsp:
  Auto merged
VC++Files/innobase/innobase.dsp:
  Auto merged
VC++Files/isam/isam.dsp:
  Auto merged
VC++Files/isam/isam.dsw:
  Auto merged
VC++Files/isamchk/isamchk.dsp:
  Auto merged
VC++Files/libmysql/libmysql.dsp:
  Auto merged
VC++Files/libmysql/libmysql.dsw:
  Auto merged
VC++Files/libmysqld/examples/test_libmysqld.dsp:
  Auto merged
VC++Files/libmysqld/libmysqld.dsp:
  Auto merged
VC++Files/libmysqltest/myTest.dsp:
  Auto merged
VC++Files/libmysqltest/mytest.dsw:
  Auto merged
VC++Files/merge/merge.dsp:
  Auto merged
VC++Files/merge/merge.dsw:
  Auto merged
VC++Files/my_print_defaults/my_print_defaults.dsp:
  Auto merged
VC++Files/myisam/myisam.dsp:
  Auto merged
VC++Files/myisamchk/myisamchk.dsp:
  Auto merged
VC++Files/myisamlog/myisamlog.dsp:
  Auto merged
VC++Files/myisammrg/myisammrg.dsp:
  Auto merged
VC++Files/mysql.dsp:
  Auto merged
VC++Files/mysql.dsw:
  Auto merged
VC++Files/myisampack/myisampack.dsp:
  Auto merged
VC++Files/mysqlbinlog/mysqlbinlog.dsp:
  Auto merged
VC++Files/mysqlcheck/mysqlcheck.dsp:
  Auto merged
VC++Files/mysqldemb/mysqldemb.dsp:
  Auto merged
VC++Files/mysqlmanager/MySqlManager.dsp:
  Auto merged
VC++Files/mysqlmanager/mysqlmanager.dsw:
  Auto merged
VC++Files/mysqlserver/mysqlserver.dsp:
  Auto merged
VC++Files/mysqlshutdown/myshutdown.dsp:
  Auto merged
VC++Files/mysqlshutdown/mysqlshutdown.dsp:
  Auto merged
VC++Files/mysqlwatch/mysqlwatch.dsp:
  Auto merged
VC++Files/mysys/mysys.dsp:
  Auto merged
VC++Files/mysys/mysys.dsw:
  Auto merged
VC++Files/pack_isam/pack_isam.dsp:
  Auto merged
VC++Files/perror/perror.dsp:
  Auto merged
VC++Files/regex/regex.dsp:
  Auto merged
VC++Files/regex/regex.dsw:
  Auto merged
VC++Files/replace/replace.dsp:
  Auto merged
VC++Files/sql/mysqld.dsw:
  Auto merged
VC++Files/sql/mysqldmax.dsp:
  Auto merged
VC++Files/sql/old/mysqld.dsw:
  Auto merged
VC++Files/strings/MASM6x/strings.dsp:
  Auto merged
VC++Files/strings/MASM6x/strings.dsw:
  Auto merged
VC++Files/strings/backup/strings.dsp:
  Auto merged
VC++Files/strings/backup/strings.dsw:
  Auto merged
VC++Files/strings/noMASM/strings.dsp:
  Auto merged
VC++Files/strings/noMASM/strings.dsw:
  Auto merged
VC++Files/strings/strings.dsw:
  Auto merged
VC++Files/test1/test1.dsp:
  Auto merged
VC++Files/thr_insert_test/thr_insert_test.dsp:
  Auto merged
VC++Files/thr_test/thr_test.dsp:
  Auto merged
VC++Files/vio/vio.dsp:
  Auto merged
VC++Files/zlib/zlib.dsp:
  Auto merged
client/mysqlbinlog.cc:
  Auto merged
client/mysqlshow.c:
  Auto merged
include/my_global.h:
  Auto merged
include/my_sys.h:
  Auto merged
include/myisam.h:
  Auto merged
include/thr_lock.h:
  Auto merged
include/violite.h:
  Auto merged
innobase/buf/buf0buf.c:
  Auto merged
innobase/os/os0file.c:
  Auto merged
innobase/row/row0sel.c:
  Auto merged
innobase/srv/srv0start.c:
  Auto merged
innobase/trx/trx0sys.c:
  Auto merged
libmysqld/lib_vio.c:
  Auto merged
myisam/mi_create.c:
  Auto merged
mysql-test/Makefile.am:
  Auto merged
mysql-test/r/create.result:
  Auto merged
mysql-test/r/group_by.result:
  Auto merged
mysql-test/r/innodb.result:
  Auto merged
mysql-test/r/join.result:
  Auto merged
mysql-test/r/rpl000001.result:
  Auto merged
mysql-test/r/select.result:
  Auto merged
mysql-test/t/auto_increment.test:
  Auto merged
mysql-test/t/create.test:
  Auto merged
mysql-test/t/func_like.test:
  Auto merged
mysql-test/t/group_by.test:
  Auto merged
mysql-test/t/innodb.test:
  Auto merged
mysql-test/t/join.test:
  Auto merged
mysql-test/t/type_datetime.test:
  Auto merged
mysql-test/t/type_timestamp.test:
  Auto merged
mysys/default.c:
  Auto merged
mysys/thr_lock.c:
  Auto merged
scripts/make_binary_distribution.sh:
  Auto merged
scripts/mysqld_safe.sh:
  Auto merged
sql/filesort.cc:
  Auto merged
sql/ha_innodb.h:
  Auto merged
sql/ha_myisam.cc:
  Auto merged
sql/handler.cc:
  Auto merged
sql/handler.h:
  Auto merged
sql/item.cc:
  Auto merged
sql/item_cmpfunc.cc:
  Auto merged
sql/item_func.cc:
  Auto merged
sql/lock.cc:
  Auto merged
sql/log.cc:
  Auto merged
sql/log_event.h:
  Auto merged
sql/mf_iocache.cc:
  Auto merged
sql/mysql_priv.h:
  Auto merged
sql/net_serv.cc:
  Auto merged
sql/opt_range.cc:
  Auto merged
sql/repl_failsafe.cc:
  Auto merged
sql/repl_failsafe.h:
  Auto merged
sql/slave.cc:
  Auto merged
sql/slave.h:
  Auto merged
sql/sql_analyse.cc:
  Auto merged
sql/sql_base.cc:
  Auto merged
sql-bench/crash-me.sh:
  Auto merged
sql/share/polish/errmsg.txt:
  Auto merged
sql/sql_class.h:
  Auto merged
sql/sql_rename.cc:
  Auto merged
sql/sql_repl.cc:
  Auto merged
sql/sql_repl.h:
  Auto merged
sql/sql_update.cc:
  Auto merged
sql/stacktrace.c:
  Auto merged
sql/table.cc:
  Auto merged
sql/unireg.h:
  Auto merged
strings/ctype-tis620.c:
  Auto merged
strings/t_ctype.h:
  Auto merged
support-files/mysql.spec.sh:
  Auto merged
tests/grant.res:
  Auto merged
vio/viosocket.c:
  Auto merged
2003-03-16 19:17:54 +02:00

510 lines
25 KiB
XML

delete from user where user='grant_user' or user='grant_user2'
delete from db where user='grant_user'
delete from tables_priv
delete from columns_priv
lock tables mysql.user write
flush privileges
unlock tables
drop database grant_test
Error in execute: Can't drop database 'grant_test'. Database doesn't exist
create database grant_test
Connecting grant_user
Error on connect: Access denied for user: '@localhost' to database 'grant_test'
grant select on *.* to grant_user@localhost
set password FOR grant_user2@localhost = password('test')
Error in execute: Can't find any matching row in the user table
set password FOR grant_user=password('test')
Connecting grant_user
Error on connect: Access denied for user: 'grant_user@localhost' (Using password: NO)
set password FOR grant_user=''
Connecting grant_user
select * from mysql.user where user = 'grant_user'
localhost grant_user Y N N N N N N N N N N N N N N N N N N N N 0 0 0
select * from mysql.db where user = 'grant_user'
grant select on *.* to grant_user@localhost,grant_user@localhost
show grants for grant_user@localhost
GRANT SELECT ON *.* TO 'grant_user'@'localhost'
insert into mysql.user (host,user) values ('error','grant_user')
Error in execute: Access denied for user: 'grant_user@localhost' to database 'mysql'
update mysql.user set host='error' WHERE user='grant_user'
Error in execute: Access denied for user: 'grant_user@localhost' to database 'mysql'
create table grant_test.test (a int,b int)
Error in execute: Access denied for user: 'grant_user@localhost' to database 'grant_test'
grant select on *.* to grant_user2@localhost
Error in execute: Access denied for user: 'grant_user@localhost' (Using password: NO)
revoke select on grant_test.test from grant_user@opt_host
Error in execute: There is no such grant defined for user 'grant_user' on host 'opt_host'
revoke select on grant_test.* from grant_user@opt_host
Error in execute: There is no such grant defined for user 'grant_user' on host 'opt_host'
revoke select on *.* from grant_user
Error in execute: There is no such grant defined for user 'grant_user' on host '%'
grant select on grant_test.not_exists to grant_user
Error in execute: Table 'grant_test.not_exists' doesn't exist
grant FILE on grant_test.test to grant_user
Error in execute: Illegal GRANT/REVOKE command. Please consult the manual which privileges can be used.
grant select on *.* to wrong___________user_name
Error in execute: The host or user argument to GRANT is too long
grant select on grant_test.* to wrong___________user_name
Error in execute: The host or user argument to GRANT is too long
grant select on grant_test.test to grant_user with grant option
Error in execute: grant command denied to user: 'grant_user@localhost' for table 'test'
set password FOR ''@''=''
Error in execute: Can't find any matching row in the user table
set password FOR root@localhost = password('test')
Error in execute: Access denied for user: 'grant_user@localhost' to database 'mysql'
revoke select on *.* from grant_user@localhost
grant create on *.* to grant_user@localhost
Connecting grant_user
create table grant_test.test (a int,b int)
grant select(c) on grant_test.test to grant_user@localhost
Error in execute: Unknown column 'c' in 'test'
revoke select(c) on grant_test.test from grant_user@localhost
Error in execute: There is no such grant defined for user 'grant_user' on host 'localhost' on table 'test'
grant select on grant_test.test to wrong___________user_name
Error in execute: The host or user argument to GRANT is too long
INSERT INTO grant_test.test values (2,0)
Error in execute: insert command denied to user: 'grant_user@localhost' for table 'test'
grant ALL PRIVILEGES on *.* to grant_user@localhost
REVOKE INSERT on *.* from grant_user@localhost
Connecting grant_user
INSERT INTO grant_test.test values (1,0)
Error in execute: insert command denied to user: 'grant_user@localhost' for table 'test'
grant INSERT on *.* to grant_user@localhost
Connecting grant_user
INSERT INTO grant_test.test values (2,0)
select count(*) from grant_test.test
1
revoke SELECT on *.* from grant_user@localhost
Connecting grant_user
select count(*) from grant_test.test
Error in execute: select command denied to user: 'grant_user@localhost' for table 'test'
INSERT INTO grant_test.test values (3,0)
grant SELECT on *.* to grant_user@localhost
Connecting grant_user
select count(*) from grant_test.test
2
revoke ALL PRIVILEGES on *.* from grant_user@localhost
Connecting grant_user
Error on connect: Access denied for user: 'grant_user@localhost' to database 'grant_test'
delete from user where user='grant_user'
flush privileges
delete from user where user='grant_user'
flush privileges
grant select on grant_test.* to grant_user@localhost
select * from mysql.user where user = 'grant_user'
localhost grant_user N N N N N N N N N N N N N N N N N N N N N 0 0 0
select * from mysql.db where user = 'grant_user'
localhost grant_test grant_user Y N N N N N N N N N N N
Connecting grant_user
select count(*) from grant_test.test
2
select * from mysql.user where user = 'grant_user'
Error in execute: Access denied for user: 'grant_user@localhost' to database 'mysql'
insert into grant_test.test values (4,0)
Error in execute: Access denied for user: 'grant_user@localhost' to database 'grant_test'
update grant_test.test set a=1
Error in execute: Access denied for user: 'grant_user@localhost' to database 'grant_test'
delete from grant_test.test
Error in execute: Access denied for user: 'grant_user@localhost' to database 'grant_test'
create table grant_test.test2 (a int)
Error in execute: Access denied for user: 'grant_user@localhost' to database 'grant_test'
ALTER TABLE grant_test.test add c int
Error in execute: Access denied for user: 'grant_user@localhost' to database 'grant_test'
CREATE INDEX dummy ON grant_test.test (a)
Error in execute: Access denied for user: 'grant_user@localhost' to database 'grant_test'
drop table grant_test.test
Error in execute: Access denied for user: 'grant_user@localhost' to database 'grant_test'
grant ALL PRIVILEGES on grant_test.* to grant_user2@localhost
Error in execute: Access denied for user: 'grant_user@localhost' to database 'grant_test'
grant ALL PRIVILEGES on grant_test.* to grant_user@localhost WITH GRANT OPTION
Connecting grant_user
insert into grant_test.test values (5,0)
REVOKE ALL PRIVILEGES on * from grant_user@localhost
Error in execute: There is no such grant defined for user 'grant_user' on host 'localhost'
REVOKE ALL PRIVILEGES on *.* from grant_user@localhost
REVOKE ALL PRIVILEGES on grant_test.* from grant_user@localhost
REVOKE ALL PRIVILEGES on grant_test.* from grant_user@localhost
Connecting grant_user
insert into grant_test.test values (6,0)
Error in execute: Access denied for user: 'grant_user@localhost' to database 'grant_test'
REVOKE GRANT OPTION on grant_test.* from grant_user@localhost
Connecting grant_user
Error on connect: Access denied for user: 'grant_user@localhost' to database 'grant_test'
grant ALL PRIVILEGES on grant_test.* to grant_user@localhost
Connecting grant_user
select * from mysql.user where user = 'grant_user'
Error in execute: Access denied for user: 'grant_user@localhost' to database 'mysql'
insert into grant_test.test values (7,0)
update grant_test.test set a=3 where a=2
delete from grant_test.test where a=3
create table grant_test.test2 (a int not null)
alter table grant_test.test2 add b int
create index dummy on grant_test.test2 (a)
drop table grant_test.test2
show tables from grant_test
test
insert into mysql.user (host,user) values ('error','grant_user',0)
Error in execute: Access denied for user: 'grant_user@localhost' to database 'mysql'
revoke ALL PRIVILEGES on grant_test.* from grant_user@localhost
select * from mysql.user where user = 'grant_user'
localhost grant_user N N N N N N N N N N N N N N N N N N N N N 0 0 0
select * from mysql.db where user = 'grant_user'
Connecting grant_user
Error on connect: Access denied for user: 'grant_user@localhost' to database 'grant_test'
grant create on grant_test.test2 to grant_user@localhost
Connecting grant_user
create table grant_test.test2 (a int not null)
show tables
test2
show columns from test
Error in execute: select command denied to user: 'grant_user@localhost' for table 'test'
show keys from test
Error in execute: select command denied to user: 'grant_user@localhost' for table 'test'
show columns from test2
a int(11) binary 0
show keys from test2
select * from test
Error in execute: select command denied to user: 'grant_user@localhost' for table 'test'
grant insert on grant_test.test to grant_user@localhost
show tables
test
test2
insert into grant_test.test values (8,0)
update grant_test.test set b=1
Error in execute: update command denied to user: 'grant_user@localhost' for table 'test'
grant update on grant_test.test to grant_user@localhost
update grant_test.test set b=2
delete from grant_test.test
Error in execute: delete command denied to user: 'grant_user@localhost' for table 'test'
grant delete on grant_test.test to grant_user@localhost
delete from grant_test.test where a=1
Error in execute: SELECT command denied to user: 'grant_user@localhost' for column 'a' in table 'test'
update grant_test.test set b=3 where b=1
Error in execute: SELECT command denied to user: 'grant_user@localhost' for column 'b' in table 'test'
update grant_test.test set b=b+1
Error in execute: SELECT command denied to user: 'grant_user@localhost' for column 'b' in table 'test'
grant SELECT on *.* to grant_user@localhost
Connecting grant_user
update grant_test.test set b=b+1
revoke SELECT on *.* from grant_user@localhost
Connecting grant_user
lect * from test
Error in execute: select command denied to user: 'grant_user@localhost' for table 'test'
grant select on grant_test.test to grant_user@localhost
delete from grant_test.test where a=1
update grant_test.test set b=2 where b=1
update grant_test.test set b=b+1
select count(*) from test
3
create table grant_test.test3 (a int)
Error in execute: create command denied to user: 'grant_user@localhost' for table 'test3'
alter table grant_test.test2 add c int
Error in execute: alter command denied to user: 'grant_user@localhost' for table 'test2'
grant alter on grant_test.test2 to grant_user@localhost
alter table grant_test.test2 add c int
create index dummy ON grant_test.test (a)
Error in execute: index command denied to user: 'grant_user@localhost' for table 'test'
grant index on grant_test.test2 to grant_user@localhost
create index dummy ON grant_test.test2 (a)
insert into test2 SELECT a,a from test
Error in execute: insert command denied to user: 'grant_user@localhost' for table 'test2'
grant insert on test2 to grant_user@localhost
Error in execute: Table 'mysql.test2' doesn't exist
grant insert(a) on grant_test.test2 to grant_user@localhost
insert into test2 SELECT a,a from test
Error in execute: insert command denied to user: 'grant_user@localhost' for column 'c' in table 'test2'
grant insert(c) on grant_test.test2 to grant_user@localhost
insert into test2 SELECT a,a from test
select count(*) from test2,test
Error in execute: select command denied to user: 'grant_user@localhost' for table 'test2'
select count(*) from test,test2
Error in execute: select command denied to user: 'grant_user@localhost' for table 'test2'
replace into test2 SELECT a from test
Error in execute: delete command denied to user: 'grant_user@localhost' for table 'test2'
grant update on grant_test.test2 to grant_user@localhost
replace into test2 SELECT a,a from test
Error in execute: delete command denied to user: 'grant_user@localhost' for table 'test2'
grant DELETE on grant_test.test2 to grant_user@localhost
replace into test2 SELECT a,a from test
insert into test (a) SELECT a from test2
Error in execute: select command denied to user: 'grant_user@localhost' for table 'test2'
drop table grant_test.test2
Error in execute: drop command denied to user: 'grant_user@localhost' for table 'test2'
grant select on grant_test.test2 to grant_user@localhost with grant option
Error in execute: select command denied to user: 'grant_user@localhost' for table 'test2'
grant drop on grant_test.test2 to grant_user@localhost with grant option
grant drop on grant_test.test2 to grant_user@localhost with grant option
grant select on grant_test.test2 to grant_user@localhost with grant option
Error in execute: select command denied to user: 'grant_user@localhost' for table 'test2'
rename table grant_test.test2 to grant_test.test3
Error in execute: insert command denied to user: 'grant_user@localhost' for table 'test3'
grant CREATE,DROP on grant_test.test3 to grant_user@localhost
rename table grant_test.test2 to grant_test.test3
Error in execute: insert command denied to user: 'grant_user@localhost' for table 'test3'
create table grant_test.test3 (a int)
grant INSERT on grant_test.test3 to grant_user@localhost
drop table grant_test.test3
rename table grant_test.test2 to grant_test.test3
rename table grant_test.test3 to grant_test.test2
Error in execute: alter command denied to user: 'grant_user@localhost' for table 'test3'
grant ALTER on grant_test.test3 to grant_user@localhost
rename table grant_test.test3 to grant_test.test2
revoke DROP on grant_test.test2 from grant_user@localhost
rename table grant_test.test2 to grant_test.test3
drop table if exists grant_test.test2,grant_test.test3
Error in execute: drop command denied to user: 'grant_user@localhost' for table 'test2'
drop table if exists grant_test.test2,grant_test.test3
create database grant_test
Error in execute: Access denied for user: 'grant_user@localhost' to database 'grant_test'
drop database grant_test
Error in execute: Access denied for user: 'grant_user@localhost' to database 'grant_test'
flush tables
Error in execute: Access denied. You need the RELOAD privilege for this operation
flush privileges
select Host, Db, User, Table_name, Grantor, Table_priv, Column_priv from mysql.tables_priv
localhost grant_test grant_user test2 root@localhost Update,Delete,Create,Grant,Index,Alter Insert
localhost grant_test grant_user test root@localhost Select,Insert,Update,Delete
localhost grant_test grant_user test3 root@localhost Insert,Create,Drop,Alter
revoke ALL PRIVILEGES on grant_test.test from grant_user@localhost
revoke ALL PRIVILEGES on grant_test.test2 from grant_user@localhost
revoke ALL PRIVILEGES on grant_test.test3 from grant_user@localhost
revoke GRANT OPTION on grant_test.test2 from grant_user@localhost
select Host, Db, User, Table_name, Grantor, Table_priv, Column_priv from mysql.tables_priv
select count(a) from test
Error in execute: select command denied to user: 'grant_user@localhost' for table 'test'
delete from grant_test.test where a=2
Error in execute: delete command denied to user: 'grant_user@localhost' for table 'test'
delete from grant_test.test where A=2
Error in execute: delete command denied to user: 'grant_user@localhost' for table 'test'
update test set b=5 where b>0
Error in execute: update command denied to user: 'grant_user@localhost' for table 'test'
grant update(b),delete on grant_test.test to grant_user@localhost
revoke update(a) on grant_test.test from grant_user@localhost
Error in execute: There is no such grant defined for user 'grant_user' on host 'localhost' on table 'test'
delete from grant_test.test where a=2
Error in execute: SELECT command denied to user: 'grant_user@localhost' for column 'a' in table 'test'
update test set b=5 where b>0
Error in execute: SELECT command denied to user: 'grant_user@localhost' for column 'b' in table 'test'
grant select(a),select(b) on grant_test.test to grant_user@localhost
delete from grant_test.test where a=2
delete from grant_test.test where A=2
update test set b=5 where b>0
update test set a=11 where b>5
Error in execute: UPDATE command denied to user: 'grant_user@localhost' for column 'a' in table 'test'
select a,A from test
8 8
5 5
7 7
select Host, Db, User, Table_name, Grantor, Table_priv, Column_priv from mysql.tables_priv
localhost grant_test grant_user test root@localhost Delete Select,Update
revoke ALL PRIVILEGES on grant_test.test from grant_user@localhost
select Host, Db, User, Table_name, Grantor, Table_priv, Column_priv from mysql.tables_priv
revoke GRANT OPTION on grant_test.test from grant_user@localhost
Error in execute: There is no such grant defined for user 'grant_user' on host 'localhost' on table 'test'
grant select(a) on grant_test.test to grant_user@localhost
show full columns from test
a int(11) binary YES NULL select
b int(11) binary YES NULL
grant insert (b), update (b) on grant_test.test to grant_user@localhost
select count(a) from test
3
select count(skr.a) from test as skr
3
select count(a) from test where a > 5
2
insert into test (b) values (5)
insert into test (b) values (a)
update test set b=3 where a > 0
select * from test
Error in execute: select command denied to user: 'grant_user@localhost' for column 'b' in table 'test'
select b from test
Error in execute: SELECT command denied to user: 'grant_user@localhost' for column 'b' in table 'test'
select a from test where b > 0
Error in execute: SELECT command denied to user: 'grant_user@localhost' for column 'b' in table 'test'
insert into test (a) values (10)
Error in execute: INSERT command denied to user: 'grant_user@localhost' for column 'a' in table 'test'
insert into test (b) values (b)
Error in execute: SELECT command denied to user: 'grant_user@localhost' for column 'b' in table 'test'
insert into test (a,b) values (1,5)
Error in execute: INSERT command denied to user: 'grant_user@localhost' for column 'a' in table 'test'
insert into test (b) values (1),(b)
Error in execute: SELECT command denied to user: 'grant_user@localhost' for column 'b' in table 'test'
update test set b=3 where b > 0
Error in execute: SELECT command denied to user: 'grant_user@localhost' for column 'b' in table 'test'
select Host, Db, User, Table_name, Grantor, Table_priv, Column_priv from mysql.tables_priv
localhost grant_test grant_user test root@localhost Select,Insert,Update
select Host, Db, User, Table_name, Column_name, Column_priv from mysql.columns_priv
localhost grant_test grant_user test b Insert,Update
localhost grant_test grant_user test a Select
revoke select(a), update (b) on grant_test.test from grant_user@localhost
select Host, Db, User, Table_name, Grantor, Table_priv, Column_priv from mysql.tables_priv
localhost grant_test grant_user test root@localhost Insert
select Host, Db, User, Table_name, Column_name, Column_priv from mysql.columns_priv
localhost grant_test grant_user test b Insert
select count(a) from test
Error in execute: select command denied to user: 'grant_user@localhost' for table 'test'
update test set b=4
Error in execute: update command denied to user: 'grant_user@localhost' for table 'test'
grant select(a,b), update (a,b) on grant_test.test to grant_user@localhost
select count(a),count(b) from test where a+b > 0
3 3
insert into test (b) values (9)
update test set b=6 where b > 0
flush privileges
select Host, Db, User, Table_name, Grantor, Table_priv, Column_priv from mysql.tables_priv
localhost grant_test grant_user test root@localhost Select,Insert,Update
select Host, Db, User, Table_name, Column_name, Column_priv from mysql.columns_priv
localhost grant_test grant_user test b Select,Insert,Update
localhost grant_test grant_user test a Select,Update
insert into test (a,b) values (12,12)
Error in execute: INSERT command denied to user: 'grant_user@localhost' for column 'a' in table 'test'
grant insert on grant_test.* to grant_user@localhost
Connecting grant_user
insert into test (a,b) values (13,13)
revoke select(b) on grant_test.test from grant_user@localhost
select count(a) from test where a+b > 0
Error in execute: SELECT command denied to user: 'grant_user@localhost' for column 'b' in table 'test'
update test set b=5 where a=2
grant select on grant_test.test to grant_user@localhost
Connecting grant_user
select count(a) from test where a+b > 0
4
revoke select(b) on grant_test.test from grant_user@localhost
select count(a) from test where a+b > 0
4
revoke select on grant_test.test from grant_user@localhost
Connecting grant_user
select count(a) from test where a+b > 0
Error in execute: select command denied to user: 'grant_user@localhost' for table 'test'
grant select(a) on grant_test.test to grant_user@localhost
select count(a) from test where a+b > 0
Error in execute: SELECT command denied to user: 'grant_user@localhost' for column 'b' in table 'test'
grant select on *.* to grant_user@localhost
Connecting grant_user
select count(a) from test where a+b > 0
4
revoke select on *.* from grant_user@localhost
grant select(b) on grant_test.test to grant_user@localhost
Connecting grant_user
select count(a) from test where a+b > 0
4
select * from mysql.db where user = 'grant_user'
localhost grant_test grant_user N Y N N N N N N N N N N
select Host, Db, User, Table_name, Grantor, Table_priv, Column_priv from mysql.tables_priv where user = 'grant_user'
localhost grant_test grant_user test root@localhost Select,Insert,Update
select Host, Db, User, Table_name, Column_name, Column_priv from mysql.columns_priv where user = 'grant_user'
localhost grant_test grant_user test b Select,Insert,Update
localhost grant_test grant_user test a Select,Update
revoke ALL PRIVILEGES on grant_test.test from grant_user@localhost
select count(a) from test
Error in execute: select command denied to user: 'grant_user@localhost' for table 'test'
select * from mysql.user
Error in execute: select command denied to user: 'grant_user@localhost' for table 'user'
select * from mysql.db where user = 'grant_user'
localhost grant_test grant_user N Y N N N N N N N N N N
select Host, Db, User, Table_name, Grantor, Table_priv, Column_priv from mysql.tables_priv where user = 'grant_user'
select Host, Db, User, Table_name, Column_name, Column_priv from mysql.columns_priv where user = 'grant_user'
delete from user where user='grant_user'
delete from db where user='grant_user'
flush privileges
show grants for grant_user@localhost
Error in execute: There is no such grant defined for user 'grant_user' on host 'localhost'
grant ALL PRIVILEGES on grant_test.test to grant_user@localhost identified by 'dummy', grant_user@127.0.0.1 identified by 'dummy2'
Connecting grant_user
grant SELECT on grant_test.* to grant_user@localhost identified by ''
Connecting grant_user
revoke ALL PRIVILEGES on grant_test.test from grant_user@localhost identified by ''
revoke ALL PRIVILEGES on grant_test.* from grant_user@localhost identified by ''
show grants for grant_user@localhost
create table grant_test.test3 (a int)
grant SELECT on grant_test.test3 to grant_user@localhost
grant FILE on *.* to grant_user@localhost
insert into grant_test.test3 values (1)
Connecting grant_user
select * into outfile '/tmp/mysql-grant.test' from grant_test.test3
revoke SELECT on grant_test.test3 from grant_user@localhost
revoke FILE on *.* from grant_user@localhost
drop table grant_test.test3
create table grant_test.test3 (a int)
Connecting grant_user
Access denied for user: 'grant_user@localhost' to database 'grant_test'
grant INSERT on grant_test.test3 to grant_user@localhost
Connecting grant_user
select * into outfile '/tmp/mysql-grant.test' from grant_test.test3
Error in execute: Access denied for user: 'grant_user@localhost' (Using password: NO)
grant SELECT on grant_test.test3 to grant_user@localhost
Connecting grant_user
LOCK TABLES grant_test.test3 READ
Error in execute: Access denied for user: 'grant_user@localhost' to database 'grant_test'
grant LOCK TABLES on *.* to grant_user@localhost
show grants for grant_user@localhost
GRANT LOCK TABLES ON *.* TO 'grant_user'@'localhost'
GRANT SELECT, INSERT ON grant_test.test3 TO 'grant_user'@'localhost'
select * from mysql.user where user='grant_user'
127.0.0.1 grant_user *042a99b3d247ae587783f647f2d69496d390aa71eab3 N N N N N N N N N N N N N N N N N N N N N 0 0 0
localhost grant_user N N N N N N N N N N N N N N N N N Y N N N 0 0 0
Connecting grant_user
LOCK TABLES grant_test.test3 READ
UNLOCK TABLES
revoke SELECT,INSERT,UPDATE,DELETE on grant_test.test3 from grant_user@localhost
Connecting grant_user
revoke LOCK TABLES on *.* from grant_user@localhost
Connecting grant_user
Access denied for user: 'grant_user@localhost' to database 'grant_test'
drop table grant_test.test3
show grants for grant_user@localhost
grant all on *.* to grant_user@localhost WITH MAX_QUERIES_PER_HOUR 1 MAX_UPDATES_PER_HOUR 2 MAX_CONNECTIONS_PER_HOUR 3
show grants for grant_user@localhost
GRANT ALL PRIVILEGES ON *.* TO 'grant_user'@'localhost' WITH MAX_QUERIES_PER_HOUR 1 MAX_UPDATES_PER_HOUR 2 MAX_CONNECTIONS_PER_HOUR 3
revoke LOCK TABLES on *.* from grant_user@localhost
flush privileges
show grants for grant_user@localhost
GRANT SELECT, INSERT, UPDATE, DELETE, CREATE, DROP, RELOAD, SHUTDOWN, PROCESS, FILE, REFERENCES, INDEX, ALTER, SHOW DATABASES, SUPER, CREATE TEMPORARY TABLES, EXECUTE, REPLICATION SLAVE, REPLICATION CLIENT ON *.* TO 'grant_user'@'localhost' WITH MAX_QUERIES_PER_HOUR 1 MAX_UPDATES_PER_HOUR 2 MAX_CONNECTIONS_PER_HOUR 3
revoke ALL PRIVILEGES on *.* from grant_user@localhost
show grants for grant_user@localhost
drop database grant_test
delete from user where user='grant_user'
delete from db where user='grant_user'
delete from tables_priv
delete from columns_priv
flush privileges
end of test