创建表空间:
create tablespace HY datafile '/usr/oracle/oradata/YSDB/HY01.dbf' size 300M autoextend on next 50M maxsize unlimited;
创建临时表空间:
create TEMPORARY tablespace TMP tempfile '/usr/oracle/oradata/YSDB/TMP01.dbf' size 1000M autoextend on next 50M maxsize unlimited;
创建数据库用户:
create user hy identified by hy
default tablespace HY
temporary tablespace TMP;
赋权限:
GRANT CREATE ANY SYNONYM to hy;
GRANT CREATE CLUSTER to hy;
GRANT CREATE INDEXTYPE to hy;
GRANT CREATE PROCEDURE to hy;
GRANT CREATE SEQUENCE to hy;
GRANT CREATE SESSION to hy;
GRANT CREATE TABLE to hy;
GRANT CREATE TRIGGER to hy;
GRANT CREATE TYPE to hy;
GRANT CREATE VIEW to hy;
GRANT DROP ANY SYNONYM to hy;
GRANT UNLIMITED TABLESPACE to hy;
查看用户权限:
select * from dba_sys_privs where grantee = 'HY';
来自 “ ITPUB博客 ” ,链接:https://blog.itpub.net/22996654/viewspace-2150509/
,如需转载,请注明出处,否则将追究法律责任。