Wednesday, May 20, 2009
Create Schema stmt
Example: CREATE SCHEMA AUTHORIZATION scottCREATE TABLE dept (deptno NUMBER(3,0) PRIMARY KEY,dname VARCHAR2(15),loc VARCHAR2(25))CREATE TABLE emp (empno NUMBER(5,0) PRIMARY KEY,ename VARCHAR2(15) NOT NULL,job VARCHAR2(10),13-2 Oracle Database Administrator’s Guidemgr NUMBER(5,0),hiredate DATE DEFAULT (sysdate),sal NUMBER(7,2),comm NUMBER(7,2),deptno NUMBER(3,0) NOT NULLCONSTRAINT dept_fkey REFERENCES dept)CREATE VIEW sales_staff ASSELECT empno, ename, sal, commFROM empWHERE deptno = 30WITH CHECK OPTION CONSTRAINT sales_staff_cnstGRANT SELECT ON sales_staff TO human_resources;Specifically, the CREATE SCHEMA statement can include only CREATE TABLE,CREATE VIEW, and GRANT statements
Subscribe to:
Post Comments (Atom)
Blog Archive
-
▼
2009
(30)
-
▼
May
(13)
- To find total size of the database
- The simplest query for checking what’s happening i...
- Starting Up with a Non-Default Server Parameter File
- How to backup the archivelogs which are not backed...
- Migrating to Automatic Undo Management
- Create Schema stmt
- Disabling the Recyclebin at session level and syst...
- how to know whether 32-bit or 64-bit oracle s/w in...
- max_enabled_roles error in all the versions includ...
- How to find TOP SQL in a particular period.
- How to do database characterset migration
- Using metadata
- Finding 64-bit or 32-bit at OS level
-
▼
May
(13)
About Me
- Palani Vijay
- Working as Oracle DBA for Wipro Technologies, Chennai, India
No comments:
Post a Comment