Thursday 26 January 2012

Oracle Schema Creation

A schema is a collection of database objects. A schema is owned by a database user and has the same name as that user. Schema objects are logical structures created by users to contain, or reference, their data. Schema objects include structures like tables, views, and indexes.
  
$ sqlplus /nolog

SQL> connect / as sysdba
Connected

Creating a New Schema
SQL> create user ctechz identified by ctehz11;
User created

Grant Permissions to user
SQL> grant create session, create table, create trigger, create sequence, create procedure, create view to ctechz;
Grant succeeded

Connecting to Schema

SQL> connect ctechz/ctechz11;
Connected 

Granting table space to the schema
SQL> grant unlimited tablespace to ctechz;
Grant succeeded



No comments:

Post a Comment