授予Create Table等权限是否隐含配额?无配额用户建表咨询
Great question—this is a super common point of confusion with Oracle (I’m assuming you’re working with Oracle given the CONNECT role and tablespace terminology!). Let’s break this down clearly:
First, the critical fact: CREATE TABLE/CREATE ANY TABLE does NOT imply tablespace quota
These privileges only grant the ability to create table objects—they have no direct link to allocating storage quota in a tablespace. Quota is a separate permission layer that controls how much disk space a user can consume in a specific tablespace.
So why did your user1 succeed?
There are two most likely explanations for this unexpected behavior:
1. The table was created in the SYSTEM or SYSAUX tablespace
Oracle has a historical quirk where users can create objects in the SYSTEM or SYSAUX tablespaces even without an explicit quota assigned. This isn’t a recommended practice (SYSTEM is meant for Oracle’s own metadata, not user objects), but it’s a default behavior in many versions.
If you didn’t specify a default tablespace when creating user1, their default will be SYSTEM. Any tables they create will automatically land there—and thus bypass the quota requirement.
2. The user was indirectly granted the UNLIMITED TABLESPACE privilege
Even if you only explicitly granted the CONNECT role and CREATE TABLE, double-check if user1 inherited UNLIMITED TABLESPACE from another role. For example, older versions of the RESOURCE role included this privilege (though Oracle 11g and later removed it from RESOURCE).
How to verify the root cause?
Run these quick queries to get clarity:
- Check the user’s default tablespace:
SELECT default_tablespace FROM dba_users WHERE username = 'USER1'; - Check the user’s assigned quotas:
SELECT tablespace_name, max_bytes FROM dba_ts_quotas WHERE username = 'USER1'; - Check all roles and system privileges granted to the user:
-- Roles assigned SELECT granted_role, admin_option FROM dba_role_privs WHERE grantee = 'USER1'; -- Direct system privileges SELECT privilege, admin_option FROM dba_sys_privs WHERE grantee = 'USER1';
Summary
To wrap up: CREATE TABLE/CREATE ANY TABLE does not implicitly assign tablespace quota. Your user was able to create a table either because it landed in SYSTEM/SYSAUX (the default behavior without explicit quota), or because they inherited the UNLIMITED TABLESPACE privilege from another role.
内容的提问来源于stack exchange,提问作者Joseph

