為了方便大家學習,下面yjbys小編為大家準備了關於Oracle表空間啟動數據庫命令的方法,歡迎閲讀。
啟動數據庫命令分為三個階段:
startup nomount
alter database mount
alter database open
本用户讀取其他用户對象的權限:
select * from user_tab_PRivs;
本用户所擁有的系統權限:
select * from user_sys_privs;
———————————————————
Oracle中數據字典視圖分為3大類, 用前綴區別,分別為:USER,ALL 和 DBA,許多數據字典視圖包含相似的信息。
USER_*:有關用户所擁有的對象信息,即用户自己創建的對象信息
ALL_*:有關用户可以訪問的對象的信息,即用户自己創建的對象的信息加上其他用户創建的對象但該用户有權訪問的`信息
DBA_*:有關整個數據庫中對象的信息
———————————————
Oracle 10i
ALTER DATABASE DEFAULT TABLESPACE 修改數據庫的默認表空間
———————————–
set echo off;
spool 產生腳本文件的路徑
select ‘grant select,insert,delete,update on ’|| table_name||‘ to 用户名;’ from user_tables;
spool off;
select ‘revoke select,insert,update,delete on ’||table_name||‘ from 用户名;’ from user_tables;
revoke select,insert,delete,update any table from 用户名 with grant option;
————–
grant select,insert,delete,insert,update any table to 用户名 with grant option ;
修改表 所屬的表空間
alter table 表名 move tablespace 表空間名
注意:在此操作之後,一定要把表上的索引重建, alter index index-name rebuild
——————-
創建表空間語句:
create tablespace tableName datafile ‘e:oracle/’ size 1024M autoextend on next 100M maxsize unlimited;