[ http://issues.apache.org/jira/browse/DERBY-1542?page=comments#action_12422313 ] Yip Ng commented on DERBY-1542: -------------------------------
Ok, let's mark this as duplicate since DERBY-1543 subtask address this issue. > Implicit revoke via drop table does not clean up its associated row(s) in > SYS.SYSTABLEPERMS > ------------------------------------------------------------------------------------------- > > Key: DERBY-1542 > URL: http://issues.apache.org/jira/browse/DERBY-1542 > Project: Derby > Issue Type: Bug > Components: SQL > Affects Versions: 10.2.0.0 > Environment: Windows XP Pro, Sun JDK 1.4.2 > Reporter: Yip Ng > Fix For: 10.2.0.0 > > > When a DROP TABLE statement is performed on the table which has access > privilege granted to other user(s), its associated rows in the system table > SYS.SYSTABLEPERMS does not get removed implicitly. i.e.: > ij> connect 'jdbc:derby:authtest;create=true' user 'yip' as conn1; > ij> select count(*) from sys.systableperms; > 1 > ----------- > 0 > 1 row selected > ij> grant select on t1 to ally; > ERROR 42Y07: Schema 'YIP' does not exist > ij> create table t1 (c1 int); > 0 rows inserted/updated/deleted > ij> grant select on t1 to ally; > 0 rows inserted/updated/deleted > ij> select count(*) from sys.systableperms; > 1 > ----------- > 1 > 1 row selected > ij> revoke select on t1 from ally; > 0 rows inserted/updated/deleted > ij> select count(*) from sys.systableperms; > 1 > ----------- > 0 > 1 row selected > ij> grant select on t1 to ally; > 0 rows inserted/updated/deleted > ij> select count(*) from sys.systableperms; > 1 > ----------- > 1 > 1 row selected > ij> drop table t1; > 0 rows inserted/updated/deleted > ij> select count(*) from sys.systableperms; > 1 > ----------- > 1 > 1 row selected > ij> select grantor, grantee from sys.systableperms; > GRANTOR > |GRANTEE > -------------------------------------------------------------------------------- > -------------------------------------------------------------------------------- > -------------------------------------------------------------------------------- > ----------------- > YIP > |ALLY > 1 row selected > sysinfo: > ------------------ Java Information ------------------ > Java Version: 1.4.2_12 > Java Vendor: Sun Microsystems Inc. > Java home: C:\jdk142\jre > Java classpath: derby.jar;derbytools.jar;. > OS name: Windows XP > OS architecture: x86 > OS version: 5.1 > Java user name: yip > Java user home: C:\Documents and Settings\Administrator > Java user dir: C:\derby\trunk\jars\sane > java.specification.name: Java Platform API Specification > java.specification.version: 1.4 > --------- Derby Information -------- > JRE - JDBC: J2SE 1.4.2 - JDBC 3.0 > [C:\derby\trunk\jars\sane\derby.jar] 10.2.0.5 alpha - (423580) > [C:\derby\trunk\jars\sane\derbytools.jar] 10.2.0.5 alpha - (423580) > ------------------------------------------------------ > ----------------- Locale Information ----------------- > Current Locale : [English/United States [en_US]] > Found support for locale: [de_DE] > version: 10.2.0.5 alpha - (423580) > Found support for locale: [es] > version: 10.2.0.5 alpha - (423580) > Found support for locale: [fr] > version: 10.2.0.5 alpha - (423580) > Found support for locale: [it] > version: 10.2.0.5 alpha - (423580) > Found support for locale: [ja_JP] > version: 10.2.0.5 alpha - (423580) > Found support for locale: [ko_KR] > version: 10.2.0.5 alpha - (423580) > Found support for locale: [pt_BR] > version: 10.2.0.5 alpha - (423580) > Found support for locale: [zh_CN] > version: 10.2.0.5 alpha - (423580) > Found support for locale: [zh_TW] > version: 10.2.0.5 alpha - (423580) > ------------------------------------------------------ -- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira
