01-创建表空间+创建用户

创建表空间

create tablespace itheima
--指定数据文件所在的位置
datafile 'c:\itheima.dbf'
--初始大小
size 100m
--自动扩展大小
autoextend on
--每一次扩展的大小是10m
next 10m;

删除表空间的语句

drop tablespace 表空间的名字

创建用户

--创建用户的语句
create user itheima
--指定用户的密码
identified by itheima
--指定用户是哪个表空间的
default tablespace itheima;

给用户授权,负责无法登陆

--给用户授权
--oracle数据库中常用角色
connect--连接角色,基本角色
resource--开发者角色
dba--超级管理员角色

给itheima用户授予dba角色

grant dba to itheima

猜你喜欢

转载自blog.csdn.net/m0_47298981/article/details/107891004