oracle 建立表空間

測試用戶鏈接
C:\Users\ZP>sqlplus /nolog
conn hbcxuser/hbcxpasssql

建立表空間數據庫

C:\Users\ZP>sqlplus /nologide

SQL*Plus: Release 11.2.0.1.0 Production on 星期三 7月 10 11:33:19 2019測試

Copyright (c) 1982, 2010, Oracle. All rights reserved.spa

SQL> conn sys/Oracle11g as sysdba
已鏈接。
SQL> create tablespace ORCL_HBCX datafile 'E:\ProgramFiles\OracleDatabase\ORCL_HBCX_DATA.DBF' size 300m autoextend on;it

表空間已建立。io

SQL> create temporary tablespace ORCL_HBCX_TEMP tempfile 'E:\ProgramFiles\OracleDatabase\ORCL_HBCX_TEMP.DBF' size 100m autoextend on next 50m maxsize 2048m extent management local;table

表空間已建立。file

SQL> create user hbcxuser identified by hbcxpass default tablespace ORCL_HBCX temporary tablespace ORCL_HBCX_TEMP profile default account unlock;select

用戶已建立。

SQL> grant connect to hbcxuser;

受權成功。

SQL> grant dba to hbcxuser;

受權成功。

SQL> grant resource to hbcxuser;

受權成功。

SQL> alter user hbcxuser default role all;

用戶已更改。

SQL> grant unlimited tablespace to hbcxuser;

受權成功。

SQL> exit;

導入數據庫文件
imp hbcxuser/hbcxpass@orcl file=E:\ProgramFiles\OracleDatabase\hbsjwj.dmp FULL=y

exp gfuser01/gfuser01@10.30.47.212:1521/ZODTZ file=c:\EAM_20150929_PRE-PRODUCTION_GF.dmp

---------------------- select d.file_name,d.tablespace_name,d.autoextensible from dba_temp_files d;   select tablespace_name, bytes, user_bytes, user_bytes/bytes,file_name from dba_temp_files; ALTER DATABASE tempfile 'E:\ProgramFiles\OracleDatabase\ORCL_HBCX_TEMP.DBF' AUTOEXTEND ON maxsize 8g;

相關文章
相關標籤/搜索