Solved

Remove an entire schema

Posted on 2007-04-05
5
1,210 Views
Last Modified: 2013-12-19
How to remove an entire schema from the command line in SQLPLUS? Oracle 9i
what rights should DBA have?
Service = Bugs
Schema = Lefteye


Drop schema didn’t work. Or I just typed it wrong. 
0
Comment
Question by:Martin_01
  • 2
  • 2
5 Comments
 
LVL 8

Expert Comment

by:gvsbnarayana
ID: 18856855
Hi,
   You can connect to the database using a DBA privileged user name and drop the user like this:
Drop user lefteye cascade;
This is an irreversable action and all objects belonging to this user and the username is also dropped.
HTH
Regards,
Badri.
0
 
LVL 27

Expert Comment

by:sujith80
ID: 18856905
To be on the safe side, keep an export dump of the schema before drop.
0
 

Author Comment

by:Martin_01
ID: 18856911
so after I log in I would type "Drop user lefteye cascade;"
0
 
LVL 8

Accepted Solution

by:
gvsbnarayana earned 500 total points
ID: 18857002
Yes, but make sure that there is no session open with the username lefteye ... if any session is open with a username, then you can't drop that user.
HTH
Regards,
Badri.
0
 

Author Comment

by:Martin_01
ID: 18857830
Thanks :)
0

Featured Post

How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

Join & Write a Comment

This post first appeared at Oracleinaction  (http://oracleinaction.com/undo-and-redo-in-oracle/)by Anju Garg (Myself). I  will demonstrate that undo for DML’s is stored both in undo tablespace and online redo logs. Then, we will analyze the reaso…
Entity Framework is a powerful tool to help you interact with the DataBase but still doesn't help much when we have a Stored Procedure that returns more than one resultset. The solution takes some of out-of-the-box thinking; read on!
This video explains at a high level with the mandatory Oracle Memory processes are as well as touching on some of the more common optional ones.
This video shows how to set up a shell script to accept a positional parameter when called, pass that to a SQL script, accept the output from the statement back and then manipulate it in the Shell.

762 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

18 Experts available now in Live!

Get 1:1 Help Now