oracle 創(chuàng)建表空間詳細介紹
更新時間:2012年11月09日 16:21:44 作者:
分為四步:詳細介紹如何創(chuàng)建表空間
注意點:
1.如果在PL/SQL 等工具里打開的話,直接修改下面的代碼中[斜體加粗部分]執(zhí)行
2.確保路徑存在,比如【D:\oracle\oradata\Oracle9i\】也就是你要保存文件的路徑存在
/*分為四步 */
/*第1步:創(chuàng)建臨時表空間 */
create temporary tablespace user_temp
tempfile 'D:\oracle\oradata\Oracle9i\user_temp.dbf'
size 50m
autoextend on
next 50m maxsize 20480m
extent management local;
/*第2步:創(chuàng)建數(shù)據(jù)表空間 */
create tablespace user_data
logging
datafile 'D:\oracle\oradata\Oracle9i\user_data.dbf'
size 50m
autoextend on
next 50m maxsize 20480m
extent management local;
/*第3步:創(chuàng)建用戶并指定表空間 */
create user username identified by password
default tablespace user_data
temporary tablespace user_temp;
/*第4步:給用戶授予權(quán)限 */
grant connect,resource,dba to username;
1.如果在PL/SQL 等工具里打開的話,直接修改下面的代碼中[斜體加粗部分]執(zhí)行
2.確保路徑存在,比如【D:\oracle\oradata\Oracle9i\】也就是你要保存文件的路徑存在
/*分為四步 */
/*第1步:創(chuàng)建臨時表空間 */
復制代碼 代碼如下:
create temporary tablespace user_temp
tempfile 'D:\oracle\oradata\Oracle9i\user_temp.dbf'
size 50m
autoextend on
next 50m maxsize 20480m
extent management local;
/*第2步:創(chuàng)建數(shù)據(jù)表空間 */
復制代碼 代碼如下:
create tablespace user_data
logging
datafile 'D:\oracle\oradata\Oracle9i\user_data.dbf'
size 50m
autoextend on
next 50m maxsize 20480m
extent management local;
/*第3步:創(chuàng)建用戶并指定表空間 */
復制代碼 代碼如下:
create user username identified by password
default tablespace user_data
temporary tablespace user_temp;
/*第4步:給用戶授予權(quán)限 */
復制代碼 代碼如下:
grant connect,resource,dba to username;
相關(guān)文章
Windows server 2008 R2(win7)登陸sqlplus錯誤ORA-12560和ORA-12557的解
這篇文章主要為大家詳細介紹了Windows server 2008 R2(win7)登陸sqlplus錯誤ORA-12560和ORA-12557的解決方法,具有一定的參考價值,感興趣的小伙伴們可以參考一下2017-05-05Linux系統(tǒng)(X64)安裝Oracle11g完整安裝圖文教程另附基本操作
因項目需求,需要在64位linux系統(tǒng)中安裝Oracle 11g,在網(wǎng)上查了很多內(nèi)容,結(jié)合自己的實際經(jīng)驗,終于安裝成功,記錄下來,分享給有需要的同志們,不謝哈!^_^2014-08-08在oracle數(shù)據(jù)庫里創(chuàng)建自增ID字段的步驟
本節(jié)主要介紹了在oracle數(shù)據(jù)庫里創(chuàng)建自增ID字段的步驟,需要的朋友可以參考下2014-07-07Oracle to_char 日期轉(zhuǎn)換字符串語句分享
這篇文章主要介紹了Oracle to_char 日期轉(zhuǎn)換字符串語句,別處挖過來的,真是太長了,學習oracle的朋友可以收藏下2014-08-08Oracle Scott創(chuàng)建視圖權(quán)限不足解決辦法
大家安裝了oracle數(shù)據(jù)庫,按照oracle教程所說,使用scott用戶登錄,創(chuàng)建一個視圖,有沒有遇到錯誤提示:權(quán)限不足!,今天就告訴大家如何解決!2015-10-10詳解Oracle如何將txt文件中的數(shù)據(jù)導入數(shù)據(jù)庫
這篇文章主要介紹了Oracle如何將txt文件中的數(shù)據(jù)導入數(shù)據(jù)庫,文中通過代碼示例和圖文結(jié)合的方式給大家講解的非常詳細,對大家的學習或工作有一定的幫助,需要的朋友可以參考下2024-03-03Oracle數(shù)據(jù)庫服務器修改操作系統(tǒng)時間的注意事項詳解
在本篇文章里小編給大家整理的是一篇關(guān)于Oracle數(shù)據(jù)庫服務器修改操作系統(tǒng)時間的注意事項詳解,需要的朋友們可以參考下。2020-03-03