0% found this document useful (0 votes)
136 views

SQL

The document contains SQL statements for creating database schemas, tablespaces, tables and views. It creates the ORACLEBI schema and tablespace with tables and views. It then creates additional tablespaces like ts_something, ORACLEBI_DATA, ORACLEBI_TEMP, ORACLEBI_UNDO. Quotas are set for users and tablespace groups are defined.

Uploaded by

vracle
Copyright
© Attribution Non-Commercial (BY-NC)
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
136 views

SQL

The document contains SQL statements for creating database schemas, tablespaces, tables and views. It creates the ORACLEBI schema and tablespace with tables and views. It then creates additional tablespaces like ts_something, ORACLEBI_DATA, ORACLEBI_TEMP, ORACLEBI_UNDO. Quotas are set for users and tablespace groups are defined.

Uploaded by

vracle
Copyright
© Attribution Non-Commercial (BY-NC)
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd
You are on page 1/ 4

CREATE SCHEMA AUTHORIZATION ORACLEBI

CREATE TABLE ORACLEBI


(OBI_id NUMBER PRIMARY KEY,
OBI_size NUMBER,
colour VARCHAR2(10) );
CREATE VIEW ORACLEBI AS
SELECT OBI_id,colour FROM ORACLEBI WHERE OBI_size=100
GRANT select ON ORACLEBI TO ORACLEBI;
localhost:1521:oracle

ALTER USER venky QUOTA UNLIMITED ON tools;

====================
CREATE SCHEMA AUTHORIZATION OBI
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;

create tablespace ts_something


ORACLEBI
datafile '/oracle/ts_sth.dbf'
size 32m
autoextend on
next 32m maxsize 2048m
extent management local;

create tablespace ORACLEBI_DATA datafile '/oracle/ORACLEBI_11.dbf'


size 10M
autoextend on maxsize 200M
extent management local uniform size 64K;
create temporary tablespace ORACLEBI_TEMP
tempfile '/oracle/product/data.dbf'
size 32m
autoextend on
next 32m maxsize 2048m
extent management local;

create undo tablespace ORACLEBI_undo


datafile '/oracle/product/10.2.0/data.dbf'
size 100M;
create tablespace ORACLEBI_STH
datafile 'c:\xx\sth_01.dbf' size 4M autoextend off,
'c:\xx\sth_02.dbf' size 4M autoextend off,
'c:\xx\sth_03.dbf' size 4M autoextend off
logging
extent management local;
alter user ORACLEBI default tablespace &&ts_something;
alter user ORACLEBI temporary tablespace &&temp_tablespace;
alter user ORACLEBI quota unlimited on &&siebel_tablespace;

create tablespace
ORACLEBI
datafile'/oracle/OBI_11.dbf'
size
50m
autoextend on
next 10m
maxsize 100m;

DROP TABLESPACE ORACLEBI


INCLUDING CONTENTS
CASCADE CONSTRAINTS;

create tablespace ORACLEBI


logging
datafile '/oracle/ORACLEBI.dbf'
size 32m
autoextend on
next 32m maxsize 2048m
extent management local;
create tablespace data datafile '/oracle/data.dbf'
size 10M
autoextend on maxsize 200M
extent management local uniform size 64K;
================
create tablespace BIPLATFORM
logging
datafile '/oracle/product/10.2.0/db_1/ORACLEBI.dbf'
size 32m
autoextend on
next 32m maxsize 2048m
extent management local;
create tablespace BIPLATFORM_data datafile '/oracle/product/10.2.0/db_1/Data_ORA
CLEBI.dbf'
size 10M
autoextend on maxsize 200M
extent management local uniform size 64K;
create temporary tablespace TEMP_BIPLATFORM
tempfile '/oracle/product/10.2.0/db_1/TEMP_ORACLEBI.dbf'
size 32m
autoextend on
next 32m maxsize 2048m
extent management local;

create undo tablespace BIPLATFORM_undo


datafile '/oracle/product/10.2.0/db_1/UNDO_ORACLEBI.dbf'
size 10M;
BIPLATFORM
alter tablespace BIPLATFORM tablespace group BIPLATFORM;

ALTER USER BIPLATFORM QUOTA UNLIMITED ON tools;

Alter tablespace BIPLATFORM


logging
datafile '/oracle/product/10.2.0/db_1/ORACLEBI.dbf'
size 15G
autoextend on
next 32m maxsize 15g
extent management local;

I send to you warm wishes,that your happiness will be as wonderful as the happin
ess, you have always given me. wish you happy birthday
When god made u he was having a good day! coz ur so special , so kindhearted , t
hat its difficult 2 tell in words ... happy b irthday

You might also like