oracle建立使用者和表空間
裝好oracle後,我們往往需要新建使用者和指定表空間。
1,找到dbca,建立資料庫:
2,以sys使用者登入剛才建立的資料庫(假設資料庫名稱是:hyman_dev);
3,建立表空間到剛才建立的目錄(可以是其他目錄):
create tablespace hyman_tablespace datafile 'G:\app\hyman\oradata\hyman_dev\hyman_dev.dbf' size 1000M autoextend on next 100M;
其中:
tablespace後面的名稱隨便取;
hyman_dev.dbf名稱隨便取,字尾必須是.dbf,目錄必須已經存在,如果不存在,在執行語句之前需要手動建立;
size 1000M:代表初始分配大小;
autoextend on next 100M :代表當空間不夠時,一次分配多大的空間。
4,建立使用者,並且指定預設表空間:
create user hyman identified by 111111 default tablespace hyman_tablespace ;
identified by 前面是使用者名稱,後面是密碼;
5,為使用者賦予一些許可權:
grant connect,resource to hyman;
grant create any sequence to hyman;
grant create any table to hyman;
grant delete any table to hyman;
grant insert any table to hyman;
grant select any table to hyman;
grant unlimited tablespace to hyman;
grant execute any procedure to hyman;
grant update any table to hyman;
grant create any view to hyman;
grant dba to hyman; --表示把 dba許可權授予給news使用者
--上面是一些基本許可權,下面配置可以檢視執行計劃的許可權:
grant select on v_$sesstat to hyman;
grant select on v_$statname to hyman;
grant select on v_$session to hyman;
grant select on v_$sql_plan to hyman;
grant select on v_$sql_plan_statistics_all to hyman;
grant select on v_$sql to hyman;
6,然後就可以用hyman賬號登入資料庫
相關推薦
oracle資料庫和表空間的最大資料容量限制
from http://www.enkj.com/help/newscontent/113209 資料庫顧名思義是資料的集合也是虛擬主機搭建網站儲存資料的工具,而Oracle則是管理這些資料集合的軟體系統,它是一個物件關係型的資料庫管理系統。 表空間是Oracle對物理
Oracle 使用者和表空間的建立與刪除
對於單個user和tablespace 來說, 可以使用如下命令來完成。 步驟一: 刪除user drop userdrp cascade 說明: 刪除了user,只是刪除了該user下的schema objects,是不會刪除相應的tablespace的。 步驟二: 刪除tablespace
(一)Oracle學習筆記—— 表和表空間
最大 更改 默認 oracle spa mil 步驟 font lte 1. 表空間 一個數據庫可以有多個表空間,一個表空間裏可以有多個表。表空間就是存多個表的物理空間;可以指定表空間的大小位置等。 1.1 創建表空間語句 create tablespace t
Oracle 創建wims用戶和表空間
ims logging 創建用戶 指定表 grant gin temporary tab xxxxx /*用sys SYSDBA *//*分為四步 *//*第1步:創建臨時表空間 */create temporary tablespace xxxxxxx_temp te
Oracle中查詢表的大小、表的佔用情況和表空間的大小
有兩種含義的表大小。一種是分配給一個表的物理空間數量,而不管空間是否被使用。可以這樣查詢獲得位元組數: select segment_name, bytes from user_segments where segment_type = 'TABLE'; 或者 &
用sqlplus為oracle建立使用者和表空間
用Oracle自帶的企業管理器或PL/SQL圖形化的方法建立表空間和使用者以及分配許可權是相對比較簡單的, 本文要介紹的是另一種方法就是使用Oracle所帶的命令列工具SQLPLUS來建立表空間。 開啟SQL Plus 登入: 輸入 SCOTT
oracle建立臨時表空間和資料表空間以及刪除
-----建立臨時表空間----- create temporary tablespace zhangmingchaotemp tempfile 'd:\oracle\zhangmingchaotemp.dbf' -----初始化大小----- size 50m
oracle建立使用者和表空間
裝好oracle後,我們往往需要新建使用者和指定表空間。 1,找到dbca,建立資料庫: 2,以sys使用者登入剛才建立的資料庫(假設資料庫名稱是:hyman_dev); 3,建立表空間到剛才建立的目錄(可以是其他目錄): create tables
Oracle 建立使用者和表空間,以及賦予許可權
1.建立表空間CREATE TABLESPACE a8v6space2 DATAFILE 'c:\oadata\oa_data.dbf' SIZE 500M AUTOEXTEND ON NEXT 100M EXTENT MANAGEMENT LOCAL UNIFORM SIZ
Oracle的臨時表空間和UNDO表空間對應的檔案丟失後的處理
資料庫的臨時檔案和undo檔案不需要做備份,丟失後可以恢復,資料不會有丟失. 一,臨時表空間的檔案丟失後,在資料庫啟動後自動建立,不需要做干預. 模擬:在資料庫shutdown後將臨時檔案刪除,啟動的時候發現自動建立. 二,undo表空間對應的檔案丟失. 模擬:在資料庫sh
在Oracle中查詢表的大小和表空間的大小 .
1、檢視Oracle資料庫中表空間資訊的工具方法: 使用oracle enterprise manager console工具,這是oracle的客戶端工具,當安裝oracle伺服器或客戶端時會自動安裝此工具,在windows作業系統上完成oracle安裝後,通過下面的方法登入該工具:開始選單——程
linux中 oracle 建立使用者和表空間以及授權
1、建立臨時表空間 select name from v$tempfile; 查出當前資料庫臨時表空間,主要是使用裡面的存放路徑; 建立臨時表空間:create temporary tablespace teest_temp tempfile '
oracle建立資料庫表空間和使用者
本文是記錄如何在oracle資料庫建立表空間,以下是執行過程。 1.1開啟cmd命令視窗: Microsoft Windows [版本 6.1.7601] 版權所有 (c) 2009 Microsoft Corporation。保留所有權利。 1.2使用sys賬號登入
oracle資料庫使用者和表空間刪除,建立
刪除表空間: 可以先將其offline alter tablespace xx offline; 將磁碟上的資料檔案一同刪除 drop tablespace xxx including contents and datafiles; 刪除使用者: drop user x
Oracle,查詢 表空間對應的資料檔案,使用者和表空間對應關係
--查詢表空間對應的資料檔案 select tablespace_name,file_id,bytes/1024/1024,file_name from dba_data_files order by file_id; --使用者和表空間對應關係 select use
oracle創建表空間、創建用戶、授權角色和導入導出用戶數據
con user esp pac miss font ora sql mission 使用數據庫管理員身份登錄 -- log as sysdba sqlplus / as sysdba; 創建臨時表空間 -- create temporary table
Oracle創建表空間和表
block 命令行 rename out enabled str fonts reference column oracle建表、建主鍵、外鍵基本語法 -創建表格語法: create table 表名( 字段名1 字段類型(長度)
Oracle中暫時表空間的清理
問題 清理 空間名 tex tab fcm including 原因 正在 作者:iamlaosong Oracle暫時表空間主要用來做查詢和存放一些緩沖區數據。暫時表空間消耗的主要原因是須要對查詢的中間結果進行排序。暫時表空間的主要作用: 索引create
Oracle查看表空間,創建表空間
con 查看表 刪除 app 創建 auto toe light globe 查看表空間: SELECT tablespace_name, file_id, file_name, round(bytes / (1024 * 1024), 0) total_
[Oracle]理解undo表空間
oracl 可能 用戶訪問 特性 active nts 一個用戶 新的 off 一、回退段介紹 在Oracle數據庫中,當某個事物對數據進行修改時,Oracle首先將數據的原始值保存到一個回退段中。一個事物只能將它的回退信息保存到一個回退段中,而多個並行事物可以使用同一個回