Click here to view and discuss this page in DocCommentXchange. In the future, you will be sent there automatically.

SAP Sybase SQL Anywhere 16.0 » SQL Anywhere Server - Database Administration » SQL Anywhere database connections » Database file types » Additional dbspaces considerations


Privileges on dbspaces

Only the CREATE privilege is supported on dbspaces. The CREATE privilege allows a user to create database objects in the specified dbspace. You can grant CREATE privilege for a dbspace by executing a GRANT CREATE ON statement.

The CREATE privilege on dbspaces behaves as follows:

  • A user trying to create a new object with underlying data must have CREATE privilege on the dbspace where the data is being placed.

  • Even if a GRANT CREATE ON statement was issued, the user (grantee) must have the CREATE ANY OBJECT system privilege to create new database objects.

  • The current list of objects that can be placed in specific dbspaces, and that require the CREATE privilege, includes tables, indexes, text indexes, and materialized views. Objects such as normal views and procedures do not have any underlying data and do not require the CREATE privilege.

  • A user can be granted the CREATE privilege directly, or they can inherit the privilege through membership in a role that has been granted the privilege.

  • It is possible to grant PUBLIC the CREATE privilege on a specific dbspace, in which case any user who also has the CREATE ANY OBJECT system privilege can create objects on the dbspace.

  • A newly-created dbspace automatically grants CREATE privilege on itself to PUBLIC.

  • It is possible to revoke privileges, for example when trying to secure a dbspace. Privileges on the internal dbspaces system and temporary can also be managed to control access.

  • Creating local temporary tables does not require any privileges; dbspace privileges do not affect the creation of local temporary tables. However, the creation of global temporary tables requires the CREATE ANY OBJECT system privilege and CREATE privilege on the temporary dbspace.

 See also