469,315 Members | 1,628 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 469,315 developers. It's quick & easy.

Create Schema statement failed.

On my DB2 UDB 8.2.7 database user User1 has been granted
IMPLICIT_SCHEMA privilege, but when he issues "create schema test",
the error message "SQL0552N, USER1 does not have the previliege to
execute the operation create schema" was thrown. But if he issues
"create table test.test(a int)", the operation can execute
successfully. So how can I let users issue the create schema statement.

Feb 8 '07 #1
2 9934
Can u list us the authorizations that the user has?
On Feb 8, 8:11 am, "Amber" <guxiaobo1...@gmail.comwrote:
On my DB2 UDB 8.2.7 database user User1 has been granted
IMPLICIT_SCHEMA privilege, but when he issues "create schema test",
the error message "SQL0552N, USER1 does not have the previliege to
execute the operation create schema" was thrown. But if he issues
"create table test.test(a int)", the operation can execute
successfully. So how can I let users issue the create schema statement.

Feb 8 '07 #2
Ian
Amber wrote:
On my DB2 UDB 8.2.7 database user User1 has been granted
IMPLICIT_SCHEMA privilege, but when he issues "create schema test",
the error message "SQL0552N, USER1 does not have the previliege to
execute the operation create schema" was thrown. But if he issues
"create table test.test(a int)", the operation can execute
successfully. So how can I let users issue the create schema statement.

Unless a user has DBADM or SYSADM, they can only create a schema
explicitly if the schema name is the same as their auth ID.

i.e.

$ db2 connect to mydb

Database Connection Information

Database server = DB2/6000 8.2.2
SQL authorization ID = IANBJOR
Local database alias = MYDB
$ db2 create schema x
DB21034E The command was processed as an SQL statement because it was
not a valid Command Line Processor command. During SQL processing it
returned:
SQL0552N "IANBJOR" does not have the privilege to perform operation
"CREATE SCHEMA". SQLSTATE=42502

$ db2 create schema ianbjor
DB20000I The SQL command completed successfully.

See the documentation for CREATE SCHEMA:

http://publib.boulder.ibm.com/infoce...n/r0000925.htm

Ian
Feb 9 '07 #3

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

10 posts views Thread by Zack Sessions | last post: by
3 posts views Thread by Seamus Thomas Carroll | last post: by
2 posts views Thread by masri999 | last post: by
reply views Thread by zhoujie | last post: by
reply views Thread by suresh191 | last post: by
reply views Thread by harlem98 | last post: by
1 post views Thread by Geralt96 | last post: by
reply views Thread by harlem98 | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.