Q

Command to add and remove users in Oracle

What command is used to add and remove users to the database? How do you archive a user?

What command is used to add and remove users to the database? How do you archive a user?

To add a user, use the CREATE USER command.

To remove a user, use the DROP USER command.

There is no ARCHIVE USER command. Instead, you'll want to use Oracle's export utility to generate a dump of all objects the user owns. This is done on the database server with the following command:

exp userid=system/manager file=my_user.dmp owner=my_user
The above signs on to the database with the SYSTEM user. The dump file will contain all objects owned by MY_USER.
This was first published in May 2007

Dig deeper on Oracle DBA jobs, training and certification

Pro+

Features

Enjoy the benefits of Pro+ membership, learn more and join.

Have a question for an expert?

Please add a title for your question

Get answers from a TechTarget expert on whatever's puzzling you.

You will be able to add details on the next page.

0 comments

Oldest 

Forgot Password?

No problem! Submit your e-mail address below. We'll send you an email containing your password.

Your password has been sent to:

-ADS BY GOOGLE

SearchDataManagement

SearchBusinessAnalytics

SearchSAP

SearchSQLServer

TheServerSide

SearchDataCenter

SearchContentManagement

SearchFinancialApplications

Close