Skip to main content


Showing posts from March, 2017

Oralce Pluggable Database

Pluggable database administration:- Open all pluggable databases: Connect to container database using oraenv $. oraenv=DB_Name $sqlplus "/as sysdba" SQL> alter pluggable database all open; Get pluggable database status: SQL> select con_id, dbid, name, open_mode from v$pdbs; Switch to Puggable database from container : SQL> alter session set container = <Puggable_DB>; Get status of Pluggable database SELECT, v.open_mode, NVL(v.restricted, 'n/a') "RESTRICTED", d.status FROM v$pdbs v, dba_pdbs d WHERE v.guid = d.guid ORDER BY v.create_scn; Get file location for pluggable database: SQL>select file_name from dba_data_files; Create table space for pluggable datatbase: SQL> alter session set container=<Pluggable_DB>; Session altered. SQL> CREATE TABLESPACE TB_Name LOGGING DATAFILE '/<Path>/<File_Name>.dbf' SIZE 1024M REUSE AUTOEXTEND ON NEXT 8192K MAXSIZE UNLIMITED EXTENT MANAGEMENT LOCAL UNIFORM SIZE 1M;