Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Create Schema in oracle 10g express edition

I have installed oracle 10g express edition and I did not find the option to create schema..

Is there a option to create schema in oracle 10g express edition or else I have to install other oracle 10g..?

To create schema which oracle 10g I have to install... what?

like image 963
ramesh Avatar asked Aug 09 '10 10:08

ramesh


People also ask

How do I create a new schema?

To create a schema In Object Explorer, expand the Databases folder. Expand the database in which to create the new database schema. Right-click the Security folder, point to New, and select Schema. In the Schema - New dialog box, on the General page, enter a name for the new schema in the Schema name box.


2 Answers

You don't need to explicitly create schema, Oracle automatically creates a schema when you create a user (see CREATE USER documentation).

If you really want, you can use CREATE SCHEMA statement and issue it through Oracle Express web interface or from SQL prompt.

like image 195
zendar Avatar answered Sep 20 '22 15:09

zendar


The CREATE SCHEMA statement can include CREATE TABLE, CREATE VIEW, and GRANT statements. To issue a CREATE SCHEMA statement, you must have the privileges necessary to issue the included statements.

CREATE SCHEMA AUTHORIZATION oe
   CREATE TABLE new_product 
      (color VARCHAR2(10)  PRIMARY KEY, quantity NUMBER) 
   CREATE VIEW new_product_view 
      AS SELECT color, quantity FROM new_product WHERE color = 'RED' 
   GRANT select ON new_product_view TO hr; 
like image 40
onkar Avatar answered Sep 18 '22 15:09

onkar